I have a laptop that I only use when I travel.
I have syntrayzor installed and configured it to sync my work file-set.
The case is that this laptop can be turned off for months, my idea was to turn it on the day before I travel and let it catch up with the latest work files.
BUT it happen twice already, that the sync happen the way around, the Travel Laptop sent its old files to the other two machines in the group, meaning that I lost my latest version of a lot of files (I got them from an external backup).
Is Syncthing not prepared for this case?
What could have gone wrong?
How can I avoid this to happen in the future?
Syncthing is for file synchronization and not a backup tool. If you “lose” files, you should rethink your backup strategy. You can activate file versioning on all computers to keep older/changed files but this is also not a replacement for a backup. If you then find a bug, please report back with steps how to reproduce the error.
There should be no difference whether the laptop has been offline one hour or one month, so there’s something else going on here. I don’t know what though.
I assume they are very much aware of that, as in could immediately recover from this problem as they did have backups in place
Anything special about how these files are stored on the travel laptop or about the files/programs that use them? Otherwise one option to investigate the problem is to set the folder on the travel laptop to receive-only. Then when you reactivate from a long time of inactivity, (perceived) changes on the laptop do not get sent to the other devices and you get a notification which files are affected. Then you can check mod. times etc. in the hopes of finding why that happens. Once everything is resolved, you can switch back to send-receive.
My idea was to use it to SYNC my laptop, that has been off line for weeks with the current “global sync” status, not as a backup method.
The problem is that from what I can see, the sync happen the wrong way, the old files sitting on my out-dated laptop got sent to all the other systems like they were the newer ones.
There should be no difference whether the laptop
Any clues about where to look at it?
Is the logic describing how to determine the “newer file” described somewhere?
Syncthing does not depend on the clock/time to decide which file is newer unless there is a conflict.
What is the method then? Because it looks like that was what didn’t work properly.
When the system came online, its version of the files, that had the content from 2 months ago, was considered the newer version and was sent to all the other devices as the newest version of the files, overriding the files already there that had modification in those 2 months.
Very, very briefly: It’s a set of counters for every device: Whenever a device sees a change of the file, it increases it’s own counter. The version with the highest wins.