Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Log errors of network resource allocation #22228

Open
maximmasiutin opened this issue Feb 2, 2025 · 1 comment
Open

Log errors of network resource allocation #22228

maximmasiutin opened this issue Feb 2, 2025 · 1 comment

Comments

@maximmasiutin
Copy link

maximmasiutin commented Feb 2, 2025

Suggestion

When qBittorrent notices changes in IP addresses, such change is handled but not reported in the log. Improper or repetitive changes may cause qBittorrent to be unresponsive, or cease any transfer.

Logging events when IP change happened would allow to diagnose such cases of unresponsiveness. If the IP changes are supposed to already be logged, than there is some other action that makes qBittorrent unresponsive unless bound to a single IP address. Anyway

Additionally there is an option "Reannounce to all trackers when IP or port changed", but such changes that trigger reannounces are not reported in the log file. There were reports that qBittorrent is unresponsive in #15822 One of the remedies is specifying qBittorrent to bind to a specific IP address rather than all addresses from all interfaces. However, there is no way to confirm or infirm the effectiveness of this remedy unless the event that causes unresponsiveness is logged.

It seems to me that qBittorrent is consuming all the available network resources (Windows handles of sockets or available ports), and then it starts slowing down because there are no more network resources left (it cannot create new sockets or Windows can not allocate new source ports). However, there is no log entry about this issue, as other programs are also reporting errors of out of network resources during this time. If I exit qBittorrent, the network resources become available again, and other programs stop reporting errors.

The main issue seems to be that qBittorrent is using too many network resources without logging the errors, which is affecting the performance of other programs. It might be a good idea to try limiting the number of connections in qBittorrent's settings or using different network configurations to reduce the load on the system. But in order to do that, there should be means to diagnose that.

Thus, qBittorrent should notify in the log any errors of network resource allocation.

Use case

This is reproducible on qBittorrent 5.0.3 64-bit for Windows (built with libbittorrent 1.2.19.0). To reproduce, you need a Windows computer with multiple network adapters. Unless you specify one IP address from one adapter to bind to, qBittorrent becomes unresponsive in a few seconds after start, as described in #15822 but no action is added to the log file that causes unresponsiveness.

@HanabishiRecca
Copy link
Contributor

When qBittorrent notices changes in IP addresses, such change is handled but not reported in the log.

qBittorrent does log IP changes.

@maximmasiutin maximmasiutin changed the title Log IP changes Log errors of network resource allocation Feb 7, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants