Performance Issues when decreasing fsWatcherDelayS to 1?

Hi Syncthing Community,

i’m using Syncthing in my local kubernetes cluster to sync local storage volumes across different nodes. I know it’s not a perfect solution and only works for applications with not-so-frequent file changes, but I can’t afford a shared storage solution like SAN and still want to configure my applications high-available though (so the data has to by synced somehow).

So I installed Syncthing to do that for me. By default the fsWatcherDelayS is set to 10 seconds, wich means it takes at least 10 seconds till the data is transferred to other devices. Of course I want Syncthing to minimize this Syncronisation-Delay as low as possible, so my cluster storage solution works smooth with the least possible data inconsisty.

But nevertheless I’m afraid of just setting the fsWatcherDelayS to 1 second, since I don’t exactly know the impact this could have on performance or something else. I mean, there has to be a reason, why it’s 10 seconds and not 1.

Can I safely set this Delay to 1 second, or would I run into some Issues with that configuration when the Sync Directory is filled with hundrets of files with hundrets of gigabytes?

Thank you!

There are no specific performance benchmarks, so you will probably need to test yourself on your own hardware to see whether there is any negative performance impact. The number of files and how frequently they change will also likely play a factor here.

Please keep in mind that the default is 10s for new files and file modifications, and 60s for deletions. If you decrease that to 1s, then deletions will still be delayed by 6s. On a side note, in the upcoming Syncthing version you will be able to use even lower values, e.g. 0.1s and so on which should make change detection almost instantaneous.

1 Like