Large pauses while syncing files

I am right now in the process of syncing many large files to and from an off-site server.

The download of files from the off-site server is progressing slowly even though my internet connection would support at least 5x faster transfer speeds.

When doing some tests I found out that the download rate of syncthing is very inconsistent. It reaches the maximum supported data rate for short amounts of time only to drop back to zero for a while. Compared to that, the upload rate stays constant all the time.

I have not set a puller pause or anything that would justify this behavior. All settings are pretty much at default, Syncthing is on the newest available version (v1.3.3), it’s not using a relay.

What could be reasons for this behavior?

I am a bit lost on how upload rate can stay consistent but download rate can fluctuate. These are two ends of a pipe, so the rate should be the same on both sides.

Syncthing does fsync after every file which on slower filesystems/drives can be in the number of seconds. I suggest you check your IO device utilisation, cpu and memory usage.

Thanks for the quick reply.

The issue occurs while Syncthing is pretty much the only process running on the system that uses significant amounts of IO and CPU time. IO and CPU utilization are still low and both are not limiting factors.

It should be noted that the download rate of my internet connection is 10x higher than the upload rate (55mbit / 5mbit).

Also, doing the whole analysis again, I found that the download rate is not reaching zero anymore but still fluctuating strongly and almost never reaching the theoretical maximum.

I suggest you try to sync one large (10GB or so) file, and see if the same is happening, this would rule out the fsync possibility.

Also, check the other side, as the other side might be struggling.

As a test I have disabled all the folders that were uploading. This lead to a large increase in download speeds and the download speed is also more consistent now.

I’ll just finish downloading and then start uploading.

It’s also the case that Syncthing does syncing in phases, first copying existing data on disk that can be reused, then fetch from network, rinse and repeat. If there are a few large files to sync I’d expect these phases to be visible in network utilization. Doesn’t mean it’s not doing anything when not downloading.

The issue is clearly related to simultaneous uploading and downloading. I worked around the issue by pausing all uploading folders and the download rate is now at the theoretical maximum. When the download is done I will unpause them.

It looks like my low upload rate slows down the rate at which response packets are sent that are necessary to continue downloading. I couldn’t identify any other possible bottlenecks. With all uploads paused, syncthing uses around 2.2 Mbit/s, which is a significant fraction of the available 5 Mbit/s. When uploads are unpaused, those packets are displaced.

Is there something I can do to reduce the response overhead? That would probably solve the issue for me.

Are you on an internet connection with a slow uplink, such as ADSL? If you are, then saturating the uplink with uploads means there is less bandwidth for requests to go out which also means there will be less responses coming back. This is the nature of things.

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.