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
High CPU Usage [pegs a single core] #1998
Comments
Startup debug log |
Thanks for your logs. From having a quick glance over them:
To verify if you are being affected by the above known issues or not, you can clear your Uploads list (you could backup |
Nicotine+ starts minimized to my tray. CPU usage only appears to increase with active uploads. Setting upload slots to 3 reduces the usage to 8-10% of total CPU (4 core CPU) |
What is your average upload speed, and normally what number of active users do you serve at any one time? |
Currently, 9 users between 700KB/s and 4MB/s (occasionally 25MB/s depending on the users) |
The only situation where I have seen a core being pegged in the way you describe, is when the Uploads history is very large and the the Uploads tab is being viewed on-screen (Edit: Actually, this bug can still present even when Nicotine+ is minimized after Uploads was the active tab.), although this seems unrelated to the problem you are experiencing. If the issue has suddenly begun, then perhaps there is an erroneous item(s) in your Uploads history. Clearing finished transfers might remedy the problem, if you make a backup of uploads.json first that could help to narrow down the offending item. |
Looking at ProcMon it looks like I'm getting a lot of buffer overflows reffering to AppData\Roaming\nicotine, some related to uploads.json. |
Could you test Nicotine+ 3.2.3.dev1 and see if the issue still occurs? https://github.com/nicotine-plus/nicotine-plus/blob/3.2.x/doc/TESTING.md |
No change |
I've made a change to only save the upload list to file once every minute, which should rule out any high CPU usage related to it. Try the latest build at the same link again. |
The combination of these two symptoms could suggest that possibly the external module responsible for dumping data into the json file has got stuck into an endless loop.
Perhaps the reason why the issue is not immediately present upon startup is because there is nothing to write into uploads.json until there is an Upload item to save into it. The OP's library versions according to log:
Please test the latest build https://github.com/nicotine-plus/nicotine-plus/blob/3.2.x/doc/TESTING.md and post with an update if you still need this looking into @tordenflesk |
No change. |
Thanks, I have a couple of questions:
Also, please provide:
|
Uploads is empty on restart. Windows 7 w/ current ESU patches |
@tordenflesk Please can you tell us:
|
It's on. toggling it with a restart made no change. |
@tordenflesk A promising fix for a very similar CPU thrashing issue has been pushed to the master branch. Please can you switch to Nicotine+ 3.3.0dev1 (master branch) to test it on your machine and let us know if this makes a difference for you or not, link: https://github.com/nicotine-plus/nicotine-plus/blob/master/doc/TESTING.md#windows By the way, I was mistaken before (see above) about how the known CPU usage bug presents itself:
Actually, it didn't matter if the application is hidden or was on-screen in the foreground, infact if 'Uploads' was the active (or remembered) tab then the CPU was thrashed (at 100%) during transfers on certain affected systems even when minimized, but was fine (at <5%) when another tab was selected. That particular issue has now been resolved in master with commit 2e0fc99. Hopefully this addresses the same issue as yours (however I can see that turning Autoclear > off will fix your forgotten uploads.json history, that's unrelated to this bug anyway). Please test Nicotine 3.3.0dev1 (not 3.2.3) at link: |
Yes |
Alright cool! @mathiascode please can you push 2e0fc99 to the 3.2.x branch to close this issue, because this is an 'Important' fix for legacy users. Affected systems:
. @tordenflesk Thank you for this bug report. |
I'm a bit skeptical about 2e0fc99 actually fixing the issue, and not some other commit present in master. I've cherry-picked the commit to the 3.2.x, can you compare the master and 3.2.x branches and confirm that it's actually fixed in 3.2.3rc1? 3.2.3rc1: https://nicotine-plus.org/doc/TESTING.html |
Rc1: Not fixed |
My mistake, sorry I hadn't realized any specific effort had been put in so I have avoided the Uploads tab without testing it for a while. |
I believe the issue was originally fixed in f1930fa for master. ee6fa92 should do the same for 3.2.x. @tordenflesk A new 3.2.3rc1 build should be ready in about 15 minutes. Could you test it and check if the issue is fixed? |
From the GTK docs: "Columns resize to be the optimal size everytime the model changes. Please note that Gtk.TreeViewColumnSizing.AUTOSIZE are inefficient for large views, and can make columns appear choppy."
It does fix the issue in Nicotine+ 3.2.3rc1 on Linux Debian 9 Stretch LTS with Python 3.5 and GTK 3.22.11 @tordenflesk How is it now in the latest 3.2.3rc1 build on your Windows machine? https://nicotine-plus.org/doc/TESTING |
Seems fine now. |
Thanks for your help @tordenflesk :) if you notice any further issues please let us know! TL'DR: it didn't matter if the application is hidden or was on-screen in the foreground, infact if 'Uploads' was the active (or remembered) tab then the CPU was thrashed (pegged at 100%) during transfers on certain affected systems even when minimized, but was fine (at <5%) when another tab was selected. Affected systems (confirmed):
FIXED in Nicotine+ 3.2.3 |
Updated to 3.2.3, and this issue(or similar) seems to have returned. |
Can you check if it's any better in 3.2.4rc1? https://github.com/nicotine-plus/nicotine-plus/blob/3.2.x/doc/TESTING.md |
A new build with more improvements should be available at the link above in about 20 minutes. |
Working well now |
Nicotine+ version: 3.2.2 (Scoop/portable)
Operating System/Distribution: Windows
High CPU usage occurs (and persists) shortly after starting Nicotine+
Additional context
Screenshots, logs, stacktraces or relevant information.
debug_1650821597.log
The text was updated successfully, but these errors were encountered: