Limit sync to 1 file at a time?

Hi all,

Just a query. I know that this was previously possible with the pullers option but I believe this has been replaced with maxpendingkb. We use two syncthing instances for film/tv editing with Avid Media Composer, one for media and one for project sync (two instances so that we can prioritise the project). Avid creates lock files when certain files are open, and for most setups this is fine because the bandwidth available is pretty good between the nodes.

What occasionally happens though: a file is modified, the peers start downloading it, but the lock file is deleted virtually instantly and before the file transfer finishes leaving the file vulnerable to being overwritten. Is there any way to limit the peers to download one file at a time? this, along with sync oldestfirst, would allow the file to transfer before the lock file is then removed.

Thanks! Jon

I think you can set copiers to 1, but I think in general you are approaching this poorly.

There aren’t any guarantees that these operations will ever happen in order.

The pull order only applies for stuff that we know needs to be synced, i.e, index entries received. There is no guarantees in what order they are sent, so you could end up syncing the lock file after the file etc.

Thanks Audrius,

I’ll play with the copiers option and see what happens.

I agree its less than ideal, but 95% of the time everything works fine in default settings just because the files being shifted are so small. The devices get their syncthing configs via a crossbar.io server which they remain connected to so I’m toying with the idea of stignoring the lock files and managing them outside of syncthing (and watching with inotify when the syncthing temp files complete to remove them) was just hoping i could go the lazy route :slight_smile:

Thanks for your help. Jon

Is it possible just to ignore the lock files?

Yes, if they are named or located in a way which makes it possible to write an exclude pattern which covers them and nothing else.

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