Connections limits

Other platforms, generic questions.
lokito50

Connections limits

Post by lokito50 »

Hi all,
I'm new here and would like some guidance as to how to configure my connection limits in options. I have a 60MBps DL/10 MBps UL cable connection and have about 175 torrents seeding to a private tracker. I'd like to maximize the use of my line so any tips would be appreciated.
Cheers
Last edited by lokito50 on Tue Jan 09, 2018 5:12 am, edited 1 time in total.
Switeck

Re: Connections limits

Post by Switeck »

While ONLY seeding, set connections per torrent really low, like 5-10. Most won't have more than 2 peers anyway on private trackers. And even if they do, not for long!

60 MEGABYTES/SECOND DL or 60 megabits/second download? (These are almost a magnitude apart in value.)
(same for the 10 MBps UL)
lokito50

Re: Connections limits

Post by lokito50 »

Megabits haha
Switeck

Re: Connections limits

Post by Switeck »

Then the 10 megabits/second upload bandwidth is the big limiting factor.
Raw speed, that's 1.25 MEGABYTES/SECOND. TCP/IP networking and BitTorrent protocol overheads can reduce that to closer to 1 MEGABYTE/SECOND...or about 1000 KiloBYTES/second upload max in qBitTorrent.
Depending on how stable the connection is and how much over-provisioning your ISP does as well as contention ratio (and they're extremely unlikely to tell you how much they do of either) can change how closely you can get to the speed limits before everything downloading or uploading bursts close to max and then falls almost to 0.

The upload speed has to be split between all active torrents and every active upload slot on those torrents, but if it's too slow from each downloading peer's point of view they will auto-snub or ban your ip address.
Beyond that, best performance seems to be with average upload speed PER upload slot is at least 5 KB/sec or as high as 100 KB/sec on private trackers.
1000 KB/sec split into 100 KB/sec upload slots would give only 10 global max upload slots...so that's almost certainly too few.

Try 50-100 global max upload slots. Average speed each could get if all active would be 10-20 KB/sec. Your connection will look a little faster than a 56k dial-up modem to them that way.
Each active torrent needs at least 2 upload slots to run correctly, so that also puts an upper limit on max torrents that can be uploading at once.
That means 25-50 max active torrents at once. (That doesn't have to count seeding torrents that are started but have no connected peers!)

You won't want a torrent or 2 "hogging" all the upload slots or connections, especially while seeding...so limits on them might work best if set to:
10-50 max connections per torrent (10 while only seeding, 50 while downloading...still enough to flood out your connection considering how many private tracker seeds are fast fiber lines)
3-10 max upload slots per torrent

If torrent queueing even works (there's been bugs reported with it), set max active torrents to slightly more than all the torrents you expect to be running at one time or enable don't count slow torrents.
For downloading torrents, you might want to limit qBT to downloading only 2-10 torrents at a time.
Or just disable torrent queueing altogether.

In advanced settings, I recommend setting max half open connections no higher than 20 at once. On private trackers, most peers+seeds aren't firewalled so at 20 half open qBT could try to connect outgoing to 100's or even 1000+ ips per minute. New incoming connections and already established peer/seed connections do not count against the half open limit, so higher is NOT better!

Depending on what drive/s your torrents are on, you may need to give qBT a large ram cache. A slow HDD cannot keep up with the speed of your connection, because it has to read from possibly 100+ different files at once. I strongly recommend using preallocate files to vastly reduce fragmented downloads and defragging HDDs can help the DL/UL speeds a little bit. SSDs see massive write amplification from downloading torrents using qBT, but seeding copied torrents from SSDs works great.
qBT 32bit versions WILL CRASH if the cache is set larger than ~1000 MB!
Both qBT 32bit and 64bit versions can and probably will use about 30% more ram than the max cache size you set.
Cache duration might as well be 600 seconds, (max allowed) otherwise the value of loading stuff into the cache isn't as useful.
lokito50

Re: Connections limits

Post by lokito50 »

[quote="Switeck"]
Then the 10 megabits/second upload bandwidth is the big limiting factor.
Raw speed, that's 1.25 MEGABYTES/SECOND. TCP/IP networking and BitTorrent protocol overheads can ....
[/quote]
Oh wow that was lengthy. Thank you so much. Here are my settings so far.
Under advanced I have Max # of half-open connections set to 20. Disk cache set to 1024MiB and the expiry interval set to 600s. I also check marked the pre-allocate disk space for all files. Anything else you can think of? What do you think about these settings?
Attachments
settings1.PNG
Switeck

Re: Connections limits

Post by Switeck »

While seeding, those settings should work great.
You may want to bump max connections per torrent up to 50 for whenever you want to download a torrent in a real hurry.
lokito50

Re: Connections limits

Post by lokito50 »

Hi all, just to revisit. I had to reformat my pc and lost my settings. If I want to seed to my max upload how should I set everything up?
My ISP connection is now 150Mbps down and 15Mbps up. I was seeding up to 1200 B/s combined between a few torrents prior to re-formatting.
Cheers,
Switeck

Re: Connections limits

Post by Switeck »

A linear increase in settings from 10 mbits/sec UL to 15 mbits/sec UL would be a 50% increase, but many BitTorrent settings don't scale or only scale minimally.

Upload is still the limiting factor, although fortunately you probably meant 1200 KB/s not 1200 B/s.
So 1200 KiloBYTES/second upload max in qBitTorrent.

1200 KB/sec split into 10-20 KB/sec average speed upload slots would be 60-120 global max upload slots.
Even with each torrent using a bare minimum of 2 upload slots each and 120 global max upload slots, you'd still be limited to 60 max active torrents at once.
A much more reasonable number of active torrents at once would be closer to 10-30.

I don't really recommend using torrent queuing in qBT because it was pretty messed up and doesn't work correctly last I tried it. (but that's been awhile, like v3.1.0 or something ancient.)
But you can still limit your torrents by not starting too many at once unless you're certain that very few will have active peers and/or seeds on them.

You won't want a torrent or 2 "hogging" all the upload slots or connections, so set the max connections per torrent to maybe 1/10th global max connections and set max upload slots per torrent to no more than 50-80% max connections per torrent OR 1/10th global max upload slots (whichever is lower).
May want more connections per torrent while downloading, but probably not more than double the 1/10th global max connections.

In advanced settings, I recommend setting max half open connections to 10 or no higher than 20 at once.

A slow HDD is even less likely to keep up with the faster speed of your connection. I strongly recommend using preallocate files to vastly reduce fragmented downloads and defragging HDDs can help the DL/UL speeds a little bit. SSDs see massive write amplification from downloading torrents using qBT, but seeding copied torrents from SSDs works great.

Disk cache set to 1024MiB and the expiry interval set to 600s...because of qBT limits.
lokito50

Re: Connections limits

Post by lokito50 »

[quote="Switeck"]
A linear increase in settings from 10 mbits/sec UL to 15 mbits/sec UL would be a 50% increase, but many BitTorrent settings don't scale or only scale minimally.

Upload is still the limiting factor, although fortunately you probably meant 1200 KB/s not 1200 B/s.
So 1200 KiloBYTES/second upload max in qBitTorrent.

1200 KB/sec split into 10-20 KB/sec average speed upload slots would be 60-120 global max upload slots.
Even with each torrent using a bare minimum of 2 upload slots each and 120 global max upload slots, you'd still be limited to 60 max active torrents at once.
A much more reasonable number of active torrents at once would be closer to 10-30.

I don't really recommend using torrent queuing in qBT because it was pretty messed up and doesn't work correctly last I tried it. (but that's been awhile, like v3.1.0 or something ancient.)
But you can still limit your torrents by not starting too many at once unless you're certain that very few will have active peers and/or seeds on them.

You won't want a torrent or 2 "hogging" all the upload slots or connections, so set the max connections per torrent to maybe 1/10th global max connections and set max upload slots per torrent to no more than 50-80% max connections per torrent OR 1/10th global max upload slots (whichever is lower).
May want more connections per torrent while downloading, but probably not more than double the 1/10th global max connections.

In advanced settings, I recommend setting max half open connections to 10 or no higher than 20 at once.

A slow HDD is even less likely to keep up with the faster speed of your connection. I strongly recommend using preallocate files to vastly reduce fragmented downloads and defragging HDDs can help the DL/UL speeds a little bit. SSDs see massive write amplification from downloading torrents using qBT, but seeding copied torrents from SSDs works great.

Disk cache set to 1024MiB and the expiry interval set to 600s...because of qBT limits.
[/quote]
Thank you for reaching out again. I meant 1000-1200 KiB/s sorry. Here are my settings as I still get a little confused understanding each one. What do you think?

Global max number of connections        500
Max number of connections per torrent  50
Global max number of upload slots        120
Max number of upload slots per torrent  10



Before I reinstalled, I always had a few active torrents seeding up using my shitty upload speed. But I forgot my settings and now it seems hard to get a few going for my ratio.
Let me know if I should change anything else. I made the other changes under advanced so that's done.
Cheers,
Robertomcat

Re: Connections limits

Post by Robertomcat »

[quote="Switeck"]
I strongly recommend using preallocate files to vastly reduce fragmented downloads and defragging HDDs can help the DL/UL speeds a little bit. SSDs see massive write amplification from downloading torrents using qBT, but seeding copied torrents from SSDs works great.
[/quote]

Hello good day!

I understand that pre-assignment is not the solution for defragmenting files. It is best to use a temporary folder (if possible on another disk), and fragmentation is eliminated when Qbt moves the file from the temporary folder to the final destination folder.
Switeck

Re: Connections limits

Post by Switeck »

[quote="lokito50"]Before I reinstalled, I always had a few active torrents seeding up using my shitty upload speed. But I forgot my settings and now it seems hard to get a few going for my ratio.
Let me know if I should change anything else. I made the other changes under advanced so that's done.[/quote]The problem may well be simply a lack of connected peers on torrents. Settings changes in qBT likely cannot fix that.

Other stuff I recommend disabling...
UPnP/NAT-PMP under Connection (it's above your global max connection settings).
Local Peer Discovery under BitTorrent (it tries to find Peers/Seeds on the same LAN as you using broadcast/multicast packets that can really hose networking)
Torrent Queueing also under BitTorrent (so buggy it's sad...you'll need to manually start/stop torrents)

In qBT's advanced settings:
Resolve peer host names (DNS lookups can be brutal, especially on qBT startup)
Resolve peer countries (GeoIP)  (same reason, and also does a flag lookup)
Download tracker favicon (there was even a remote exploit in the wild for this one!)
uTP-TCP mixed mode algo. best set to Prefer TCP.[quote="Robertomcat"][quote="Switeck"] I strongly recommend using preallocate files to vastly reduce fragmented downloads and defragging HDDs can help the DL/UL speeds a little bit. SSDs see massive write amplification from downloading torrents using qBT, but seeding copied torrents from SSDs works great.[/quote]I understand that pre-assignment is not the solution for defragmenting files. It is best to use a temporary folder (if possible on another disk), and fragmentation is eliminated when Qbt moves the file from the temporary folder to the final destination folder.[/quote]Pre-assignment on HDDs works decently well with the latest versions of libtorrent. qBitTorrent v4.1.5 isn't using the latest -- it was released almost 5 months ago.
qBT's main problem with pre-allocating/pre-assignment on HDDs wasn't fragmentation -- the problem was it ZERO-filled every byte instead of fast allocating. Start a multi-GB torrent with pre-allocate enabled and other reads/writes of torrents nearly ground to a halt while qBT writes out a few billion bytes of 0's in a row.
Robertomcat

Re: Connections limits

Post by Robertomcat »

[quote="Switeck"]
[quote="lokito50"]Before I reinstalled, I always had a few active torrents seeding up using my shitty upload speed. But I forgot my settings and now it seems hard to get a few going for my ratio.
Let me know if I should change anything else. I made the other changes under advanced so that's done.[/quote]The problem may well be simply a lack of connected peers on torrents. Settings changes in qBT likely cannot fix that.

Other stuff I recommend disabling...
UPnP/NAT-PMP under Connection (it's above your global max connection settings).
Local Peer Discovery under BitTorrent (it tries to find Peers/Seeds on the same LAN as you using broadcast/multicast packets that can really hose networking)
Torrent Queueing also under BitTorrent (so buggy it's sad...you'll need to manually start/stop torrents)

In qBT's advanced settings:
Resolve peer host names (DNS lookups can be brutal, especially on qBT startup)
Resolve peer countries (GeoIP)  (same reason, and also does a flag lookup)
Download tracker favicon (there was even a remote exploit in the wild for this one!)
uTP-TCP mixed mode algo. best set to Prefer TCP.[quote="Robertomcat"][quote="Switeck"] I strongly recommend using preallocate files to vastly reduce fragmented downloads and defragging HDDs can help the DL/UL speeds a little bit. SSDs see massive write amplification from downloading torrents using qBT, but seeding copied torrents from SSDs works great.[/quote]I understand that pre-assignment is not the solution for defragmenting files. It is best to use a temporary folder (if possible on another disk), and fragmentation is eliminated when Qbt moves the file from the temporary folder to the final destination folder.[/quote]Pre-assignment on HDDs works decently well with the latest versions of libtorrent. qBitTorrent v4.1.5 isn't using the latest -- it was released almost 5 months ago.
qBT's main problem with pre-allocating/pre-assignment on HDDs wasn't fragmentation -- the problem was it ZERO-filled every byte instead of fast allocating. Start a multi-GB torrent with pre-allocate enabled and other reads/writes of torrents nearly ground to a halt while qBT writes out a few billion bytes of 0's in a row.
[/quote]

Thanks, I've also taken note of the geo-ip resolution and the favicon, it was the only thing I did not have disabled. I only use private trackers, and I think it does not matter much.

As for the pre-assignment, I only see utility in the case that you have a disk almost full, and serve to warn you that there is no space, it is not a way to defragment
Switeck

Re: Connections limits

Post by Switeck »

If you only use private trackers definitely disable DHT.
PEX you can leave enabled because it won't do any harm if private tracker torrents are properly marked as private torrents.
Robertomcat

Re: Connections limits

Post by Robertomcat »

Yes, everything is disabled. Thanks
lokito50

Re: Connections limits

Post by lokito50 »

Cool thank you. Speeds are picking up again and yes they're private trackers
Post Reply