-
Notifications
You must be signed in to change notification settings - Fork 800
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
Massive slow down when NC tray icon is open #4918
Comments
I'd like to add my current experience with a newly added sync folder using virtual files: Maybe this is just a problem of logging all the activity in the tray window, even while syncing initially? Or a repaint problem? Solving this heavy issue could also pay off in improving the speed problems with initial sync mentioned in #4424 I can confirm that restarting the client helps for some time until performance decreases again. |
I can also confirm this behavior with the placeholders (virtual files) in my computer with Windows 10. |
+1 same behavior noticed |
This issue should not be very hard to profile: e. g. add 100 000 small files (a maildir folder, for example) to a Nextcloud and measure the download to a Nextcloud Client. Even the upload to Nexcloud via a Client should suffer from the same problem. |
In it is mentioned that performance decreases with time and restarting the client helps, which underpins the suggestions I made in #4918 (comment) I can confirm that restarting the client helps for some time until performance decreases again. |
See #4424 (comment) for a good analysis of the issue. |
For me it doesn't appear to be opening the tray but if I open the settings page it grinds to a complete halt The tray seems to work fine when started but over a few days it becomes completely bogged down, just opening the tray takes foverer, it refreshes very slowly, network transfer has ground to a halt It seems like others that restarting the app every day keeps it somewhat alive but there's definitely some sort of issue with logs or something that block it up over time |
In my case it was beacause I set upload speed limitation to "automatic". I switched back to "unlimited" and everything works as it should. |
With latest Nextcloud Client 3.7.3 an inital sync on ~150k files took <1 hour where it was a whole night and endless errors in the past. Even if the sync process is now way faster, I can see a huge difference in speed where the NC tray window is shown or not. In my case there are multiple accounts connected in the Nextcloud Client. |
I will do a new timing test on my setup, I thought I saw a speed up after the last update, will verify it. |
It's still an issue with 3.7.3. Please keep in mind, that syncing thousands of small files are a different story and worth a different bug report. (which are surely exist) |
I am seeing the same issue. Windows 10. Latest client. I'd even go a step further and say that the application syync speed is just MUCH slower than all other methods. Downloading and uploading the same 12 GB file to the same location through 3 different methods (Samba, Web client, and windows application) showed the windows client is 10x+ slower than any other method, even in best case for windows app. I have a 10GbE network, and expect to run up against my hard drive throughput limit on the server, not some arbitrary 25 MB/sec limit. The app is terribly slow. |
@jonofmac |
These tests were all done with the tray icon closed. When i open the tray, the speeds plummet to 5-8 MB/sec. Close tray and it jumps back to 25 |
The issue has some more implications than I can read from here:
Basically opening the client in any way destroys any upload performance. Additionally it never reaches its full network potential. |
I have the same issue that my nextcloud app not even responding on my windows 11 machine. I used the latest stable 3.8.2 for some days and now I downgraded to 3.7.3 and it seems to work well. |
This problem is affecting users on virtual files only it seems. We have the latest available version of Nextcloud 25, Nextcloud 25.0.6 on server and the clients have the latest client installed, version 3.8.2. We signed up a new company and they have about 6 users and the files shared among them totals more than 800 000 small files. The users cannot work at all as their PC's are too slow. It is as if Nextcloud restarts the sync just as it completed the previous sync and just never stops. This is a huge issue and we are about to loose our new customer. As this thread is almost a year old, it seems the Nextcloud devs are not looking into this or releasing any fixes at all. What is going on? |
I have the same issue. |
I can confirm that using the Nextcloud client 3.7.3 works well and the issue stops. Please Nextcloud, please fix the latest client to have better performance using sync. |
3.7.3 stopped working for me after some hours. I needed to disable now the virtual files. |
Windows client version 3.9, slowdown issue with tray open issue is still here. |
I can confirm the slowdown when the tray is open. My setup:
Test case:
Observations:
Findings:
I also recorded a quick video showing the slowdown when downloading a large file (using VFS): https://www.youtube.com/watch?v=THqeszUO9Ws In the video, the transfer already starts "medium slow". I'm not sure yet when exactly this happens. Restarting the client and starting the download without opening the tray resulted in a higher initial transfer speed.
That's what I was thinking too... I'll take a look at the code and see if I can find something. |
I've done some investigation and found what's causing the issue. While synchronizing, the window shows an animated blue sync icon. The animation of the icon is causing the slowdown. I've disabled the animation locally and now the synchronization runs with full speed - whether the tray is open or not. That's the change that disables the animation: diff --git a/src/gui/tray/syncstatussummary.cpp b/src/gui/tray/syncstatussummary.cpp
index 8f74985c8..adf8519cd 100644
--- a/src/gui/tray/syncstatussummary.cpp
+++ b/src/gui/tray/syncstatussummary.cpp
@@ -151,7 +151,7 @@ void SyncStatusSummary::setSyncStateForFolder(const Folder *folder)
break;
case SyncResult::SyncRunning:
case SyncResult::NotYetStarted:
- setSyncing(true);
+ setSyncing(false);
setSyncStatusString(tr("Syncing"));
setSyncStatusDetailString("");
setSyncIcon(Theme::instance()->syncStatusRunning()); Here's a video showing the slowdown when the tray is open: https://drive.google.com/file/d/18FHSYBcek133wcvFyhY27Y7bwTN63GwM/view?usp=sharing And here's the same upload operation again with the animation being deactivated: https://drive.google.com/file/d/1iNM3KMazQZAqZP_VrSuQ9cKzOUOyNmu9/view?usp=sharing I'm not sure yet why the animation is causing such a big slowdown. CPU usage isn't high while this is happening. I suspect that it's a scheduling issue somehow (e.g. that scheduling the animation X times per second is in the same loop as the code driving the file transfer), but that's only a guess currently. I'll see if I can find the root cause. Anyway, would it be an option to disable the animation for the time being? It's not as pretty, but the animation is causing slowdowns even after the tray has been closed again and I'd argue for performance rather than aesthetics. I can do a PR deactivating the animation if that's a viable option. |
In my opinion the faster Nextcloud can operate the better and I am sure no one will mind the animation going away. Either the Nextcloud team must look into this issue and release a fix or the animation must be disabled completely until there is a fix |
Great finding, kudos! Can you see if this holds true for the animation in the settings/account window (like https://nextcloud.com/wp-content/uploads/2022/04/linux.png)? |
Unfortunate to still see this issue. I'm on the latest NC client for windows with latest nextcloud 25 release. In my case, I transfer video files. So it's large files (several gigs each), but not a ton of them. I still arbitrarily see this 25 MB/sec limitation via the client when I keep the tray minimized/hidden. Very frustrating that the client is so slow. Has anyone been able to see transfer speeds anywhere near a 1 gbE limit with the app? Again, I have 10GbE for my video editing machines (specifically for fast transfers to my server) and the nextcloud desktop client never syncs faster than 25 MB/sec (~200 mbps). No heavy CPU usage, it's not a network limitation... I can open the nextcloud web client and download files at near full speed of the array (it's a ZFS raid 10-like rust array, so ~560MB/s (~5 gbps) for sequential writes. With nextcloud app I can't even come close to touching 1 gbe link speeds, let alone near the array speed... |
The situation is similar. When I synchronize with the client, I can reach 300 mbps in the first half minute. Over time it will drop to around 150 mbps. No high cpu utilization. Using web uploads and downloads can run up bandwidth, only the client is so slow |
Still an Issue for me: When Tray is closed I get around 200MBit/s Upload speed and when it is opened I get around 10 MBit/s or slower. Also other people mentioned, that the client slows down in general after some time. I also observed this behavior. Shortly after restarting the client I get upload speeds at around 1GBit/s and after some time it slows down to the above 200MBit/s when the tray is closed. |
This issue has been around for at least a year. We also experience the same problem. The issue with the tray is the animation of the sync icon. When that is stopped, the tray does not limit download speed. See this article for the fix: #4918 (comment) |
Feel free to test this build with a fix https://cloud.nextcloud.com/s/2X5wM5Y3rRMs5ZJ, in my tests, this specific issue is fixed with it |
@allexzander I have no possibility to test with that test build for the next days, but maybe some other contributors of this issue do. |
Hi. I have tested with following observations.
Regards Rob |
Hi Allexzander, regards PS: Of course, synchronization speed could be even better, but the specific problem with the open tray icon has been solved. |
I can also confirm the observations by @roberix and @koppd. There are other problems mentioned in this comment #4918 (comment) that are not covered by the solution. |
I can confirm the same issue with the client. Although it took me a while to figure it out, the Nextcloud sync client was buggy since I had just installed Nextcloud. So, I thought something was wrong with my Nextcloud VM. Indeed, there is an issue with the live version of the client. While the tray is open, the upload speed tanks, but that's not the only thing that happens. In my findings: I have a server with a 6-core processor, 16GB of RAM, running Ubuntu 24 Noble, latest version from 08/05/2024. I noticed that when the tray was open and the upload issue was occurring, my Nextcloud server began to spike in RAM usage significantly. It was using the entire 16GB while essentially doing nothing, just waiting for the file. I can also confirm this is not due to Redis since I installed Redis on a separate VM. I tried the new build you made, @allexzander A. This seems to solve all those issues. |
Has anybody tried it, that is, has CPU core parking disabled? |
Is there a timeline for when this build will be folded into the nextcloud client proper? It seems the test build link no longer works, but the issue is still present in current nextcloud desktop client |
I just upgraded to 3.13.1 and can confirm that the fix works. When opening the main dialogue while downloading, there's no slowdown anymore. |
Fixed in #6691 |
Bug description
When the tray icon is open (I don't know how to describe it) then the network performance is slow down by 90%.
Here's an example of a 400 MB file transfer between two virtual machine with 1 GBit/s connection. => only 20 MBit/s
Without the opened tray icon the speed is MUCH faster => 400 MBit/s
Steps to reproduce
Copy some files (40 x 10 MB) and wait a second for the sync to start. (=upload to server; VFS is used)
Open the tray icon a the speed goes down to 20 MBit/s; close the tray icon and the transfer speed accelerate to 400 Mbit/s
Expected behavior
Transfer should not be affected if tray icon is opened or not
Which files are affected by this bug
10485760 - Kopie (5) - Kopie - Kopie - Kopie - Kopie - Kopie - Kopie - Kopie - Kopie.txt
Operating system
Windows
Which version of the operating system you are running.
Windows 10
Package
Appimage
Nextcloud Server version
25.0.0 beta 5
Nextcloud Desktop Client version
3.6.0
Is this bug present after an update or on a fresh install?
Updated to a major version (ex. 3.3.6 to 3.4.0)
Are you using the Nextcloud Server Encryption module?
Encryption is Disabled
Are you using an external user-backend?
Nextcloud Server logs
No response
Additional info
No response
The text was updated successfully, but these errors were encountered: