mirror of
https://github.com/qbittorrent/qBittorrent.git
synced 2026-03-02 22:57:32 -05:00
Can't automatically set upload speed #13900
Labels
No labels
Accessibility
AppImage
Bounty
Build system
CI
Can't reproduce
Code cleanup
Confirmed bug
Confirmed bug
Core
Crash
Data loss
Discussion
Docker
Documentation
Duplicate
Feature
Feature request
Feature request
Feature request
Filters
Flatpak
GUI
Has workaround
I2P
Invalid
Libtorrent
Look and feel
Meta
NSIS
Network
Not an issue
OS: *BSD
OS: Linux
OS: Windows
OS: macOS
PPA
Performance
Project management
Proxy/VPN
Qt bugs
Qt6 compat
RSS
Search engine
Security
Temp folder
Themes
Translations
Triggers
Waiting diagnosis
Waiting info
Waiting upstream
Waiting web implementation
Watched folders
WebAPI
WebUI
autoCloseOldIssue
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
starred/qBittorrent#13900
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @ballo on GitHub (Oct 11, 2022).
Suggestion
This is a feature that's over 10 years old, so I'm not sure why it isn't more prevalent (tempted to file it as a bug). I'm always on the road and have to manually set this daily, or use a different client.
Use case
Everyone would find this useful
Extra info/examples/attachments
No response
@glassez commented on GitHub (Oct 12, 2022):
It is completely unclear what exactly the requested feature should do.
@ballo commented on GitHub (Oct 13, 2022):
Set the upload cap automatically like uTorrent or Vuze
@glassez commented on GitHub (Oct 13, 2022):
Description, examples, screenshots?
Or do you expect everyones know how uTorrent/Vuze do it?
@ballo commented on GitHub (Oct 15, 2022):
Instead of setting the upload speed manually, it's automatically set to whatever limit doesn't negatively affect downloading. It's a really, really old feature that works great.
@thalieht commented on GitHub (Oct 16, 2022):
Ok. Looks like you won't explain. Is it an automatic per torrent upload speed you want?? Because a global upload speed limit already exists.
@ballo commented on GitHub (Nov 8, 2022):
All you have to do is use Vuze/BiglyBT or uTorrent and the answer is self-evident as they automatically set the upload speed LIVE. This means even if your connection conditions change the app automatically limits the amount of packets sent upstream so it doesn't clog the downstream.
This is a very, very old feature and works well.
@glassez commented on GitHub (Dec 26, 2022):
@arvidn, what do you think?
@ballo commented on GitHub (Feb 8, 2023):
This is how uTorrent does it:
https://forum.utorrent.com/topic/279-automatic-bandwidth-restriction/
VUZE looks similar:
https://wiki.vuze.com/w/Auto_Speed_Beta#Algorithm_details
@glassez commented on GitHub (Feb 10, 2023):
@arvidn
So what do you think about it anyway? Are you interested in implementing an automatic upload limit in libtorrent?
@arvidn commented on GitHub (Feb 12, 2023):
Tha foundation of this feature is uTP, which ensures its upload speed is continuously adjusted to not interfere with real-time traffic (to the best of its ability). If anyone is unfamiliar with uTP, it's documented here and in more detail here.
As far as I know, the major remaining challenge is how to handle swarms where some peers use TCP and some use uTP. The TCP connections will inherently cause the uTP connections to throttle, causing an imbalance in allotted upload capacity between the two kinds.
I didn't quite follow the uTorrent thread, it looked more like a feature request than an explanation of what uTorrent implements. Fortunately, it was also sufficiently old that it predated uTP. The way uTorrent handles this situation is that it throttles TCP upload rates for all TCP connections (as a group) based on the upload rate experienced by all uTP connections (as a group). It takes int account how many connections each group has to approximately ascribe similar upload bandwidth to each peer connection. However, as we all know, not all peers have the same capacity, so this balance is regularly adjusted with a kind of low-pass filter. Let's say it's about every 10 seconds, if throttling the TCP connections did not cause the uTP connections to increase their upload rate, the TCP group is given more bandwidth, and vice versa. If it did cause the uTP group to increase its upload rate, then the balancing is moved one step closer to balancing out the capacity.
As you can tell, this makes movements slow (it kind of has to be, to let give the transports enough time to adjust). It also means that if there are sudden large changes in the mixture and capacities of peers, it may take a while to adjust the TCP/uTP balance. I was never really happy about this algorithm, but it was at least conservative in ensuring the upload capacity was well utilized.
In libtorrent, I went for a much simpler (and most likely worse) solution, implemented here. Every second the rate limits of TCP peers are adjusted to exactly be proportional to the actual rates achieved by uTP peers. i.e. this assumes that all peers have equal capacity, and the only limiting factor is the uTP throttling. i.e. there's no low-pass filter in adjusting the rates.
The behavior is controlled by the
mixed_mode_algorithmsetting.@ballo commented on GitHub (Feb 21, 2023):
Forgive my ignorance but why do you have to adjust individual peers instead of just throttling the overall upload bandwith use?
@arvidn commented on GitHub (Feb 21, 2023):
@ballo
In my mind, "throttling the overall upload bandwidth" means: throttle individual peers such that the aggregate upload rate is at-or-below some specified limit.
I don't see how you can limit the aggregate without it boiling down to limiting individual peers.
@ballo commented on GitHub (Feb 22, 2023):
Well, you could break that down to individual tcp pipes, too. Whether you aggregate them into 'peers' (each of which can have multiple pipes) or the connection as a whole is up to you.
@arvidn commented on GitHub (Feb 22, 2023):
one peer has one connection which is one TCP pipe (or a uTP pipe)
@ballo commented on GitHub (Feb 24, 2023):
OK
@luzpaz commented on GitHub (May 14, 2023):
@ballo can you refine both the title and the OP so that it reflects succinctly what is being requested. Then the 'invalid' tab can be removed from this ticket.
@ballo commented on GitHub (May 19, 2023):
I don't understand what you're requesting. The title reflects the ultra old feature other bittorrent clients have. You can always create another ticket and claim this one is a duplicate.
@xavier2k6 commented on GitHub (May 24, 2025):
ANNOUNCEMENT!
For anybody coming across this "Feature Request" & would like/love to see a potential implementation in the future!
Here are some options available to you:
Please select/click the 👍 &/or ❤
reactionsin the original/opening post of this ticket.Please feel free (If you have the "skillset") to create a "Pull Request" implementing what's being requested in this ticket.
(new/existing contributors/developers are always welcome)
DO:
DO NOT:
(These will be disregarded/hidden as "spam/abuse/off-topic" etc. as they don't provide anything constructive.)
@ballo commented on GitHub (May 29, 2025):
I don't know what's so hard to understand. There is a very useful feature that other clients have that qbittorrent lacks. Perhaps if you tried other BitTorrent clients you wouldn't be so confused.
To repeat myself (as there is no clearer way to state this), some BitTorrent clients you do not have to manually set the upload rate cap. It is done automatically, and this is a very very very nice feature which I don't ever want to do without especially since I have to switch ISPs often. It's a killer feature.