syncthing synchronize the same files several times

Hello

I installed syncthing on a dedicated server (under Debian) It points to the folder “x” only for sending, this folder is synchronized on my hard disk (folder “y”) for file retrieval. on this hard drive syncthing runs locally in a vm and points to the ‘y’ folder only for reception. Sometimes I have to restart the vm and also syncthing locally. I have a problem with syncthing on my dedicated server, it synchronizes files/folders already synchronized before the restart. I cannot delete the files/folders from my server (folder “x”) because they are shared. Would it be possible to ensure that the files already synchronized are not synced a new time? I tried to set up an exclusion in the file “. stignore” >> “date +1d” without success. Any idea?

Sorry for my english Thank you

Welcome here @Niirox!

Sorry, I don’t understand what the problem is. Could you please write a new description? In the new description please consider the following:

  • As far as possible (without revealing secrets), please use real names (instead of aliases) for devices (regardless if they are physical or virtual) and folders.
  • Write the description as a numbered list of steps describing what you need to do to reproduce the problem.
  • Please describe your expectations as well as what you actually observe. Be specific.
  • Screenshots often help give a good understanding.
2 Likes

Hello,

Sorry for my confused explanation!!

I run syncthing on 2 machines: 1>> Syncthing installed on a dedicated server, Os: Debian (Sending device only) 2> syncthing installed on a local VM, Os: Debian (Receiver device, receive only)

I synchronized with syncthing a folder “Expertise” (shared folder) from the dedicated server with a folder: “Backup” located on the hard disk of a NAS (Freebox Delta on which the VM is located) so that each document sent by my collaborators in the folder “Expertise” of the server is automatically downloaded to the NAS folder “Backup” the documents are erased from the server and the NAS after only a few months The problem:

I restart Synchting on my NAS to perform an update. After the restart, once the two instances of syncthing have been synchronized, the instance of my NAS will download the documents present in the “Expertise” folder to the “Backup” folder even though they had already been synchronized/downloaded before the restart. the documents already downloaded from the ‘Expertise’ folder to ‘Backup’ are uploaded a second time. Is it possible to exclude the documents based on their chronology? Or exclude documents already synchronized between the two folders before restarting syncthing to avoid them becoming duplicate by being downloaded twice?

Hope I explained a little better this time!!

thanks

The situation is still not entirely clear to me, but I think I have a few comments to share.

No, it is not possible to exclude based on time and/or date.

It seems like you are trying to use Syncthing as a transfer tool and/or a backup tool. It is none of that. It is a synchronization tool. From what you describe I believe you would be better off using rsync or a proper backup tool like for example restic instead.

If you need more help from me please provide the things below. Or maybe someone smarter than me think they get a grip about your problem and can help anyway?

Please provide screenshots.

Please provide a numbered list of steps needed to reproduce. Made up dummy example:

  1. Create file foo.txt on computer A.
  2. After a few seconds I observe on computer B that the file has been synchronized. I see the folder in the filesystem there.
  3. And so on…

Kind regards /Martin

Syncthing is smart enough to only transfer data that need to be transferred.

Do you delete anything on the receive-only folder (“Backup“ in NAS)?

No, I haven’t deleted anything, but I just understood!! I forgot to mention that I was renaming some folders!!! That’s why they are downloaded again !!! Sorry to have wasted your time!!!

Good that you sorted it out! :slight_smile:

Next time someone ask you for a detailed numbered steps to reproduce a problem, please don’t describe from memory. Instead reproduce the problem again while taking notes. :wink:

1 Like

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