How the Syncthing is tracking changes made offline?

Hi Everyone,

I’m currently testing Syncthing and looks very promising. Thank you. I successful installed and configured Syncthing on my desktop and my laptop. I’m currently syncing single repository called ‘tasks’. This repository contains about 4 XML based files. I have 100% sync status, in other words all my files on both machines are synced. I verified it with MD5 hushes.

Next I shutdown Syncthing on both computers. Then I work on my laptop while syncthing is offline. ‘tasks’ repository is my TODO list, as result my files on my laptop get modified as I complete my tasks, but no single change is made on my desktop that remains off all day.

When I get home I turn on my desktop and my laptop. Next I start Syncthing on both machines and let it sync the repository. Unfortunately, I encounter a problem. Often, but not always my ‘tasks’ repository on the laptop will be overwritten by outdated version on my desktop. At this time it seams random. I tried both:

  1. Start syncthing on the desktop first and second on my laptop; and
  2. Start syncthing on my laptop first and second on my desktop.

Is this a bug or I’m using syncthing incorrectly?

ps. I tried ‘Master repository’ option, but it doesn’t work for me, because I need to able to modify my TODO list on both laptop and desktop as I work.

When starting up, syncthing reads an index of the previous known contents and checks the current state against the previous known. Files where the timestamp doesn’t match the expected are rehashed to check for actual differences and then synced as appropriate.

What you describe should not happen, unless the file has changed on both sides.

I suspected this is the problem, but no because I verified MD5sums of the files. Looks like on my systems (or one of them) the index is not saved correctly. How do I verify/validate syncthing indexes are stored correctly before the shutdown and before I restart syncthing.

ps. How I can enable more verbose output in the terminal in order to observe index operations of syncthing during the startup.