Does syncthing create folder structure before syncing files?

I am having some problems with Syncthing not putting data on the correct unRAID disks. unRAID puts data on various disks based on folder structure. So, if Syncthing creates a bunch of empty folders prior to syncing files, it ends up putting all data on 1 disk which results in a full drive.

Is there anyway to make Syncthing only create folders when a file inside that folder is about to be synced?

No, syncthing precreates directories.

Sorry, but this is a really broken way of implementing “raid” :confused:

It’s called “unRAID”. It’s purpose is data redundancy without striping or raid, and it’s a very popular NAS solution because it has many benefits over raid setups.

Basically, Syncthing is putting 82TB of temp files onto a single 8TB drive because the temp files don’t seem to use drive space until after synced. Since the mapped drive (and Syncthing) sees the full 147TB, it doesn’t realize that disk1 is out of space.

A normal file transfer makes folders only as files are copied, and doesn’t make temp files, so it correctly spreads the data across the disks based on my unRAID split settings.

I am just going to have to sync these servers using old school file transfers, and then let Syncthing take over for the day to day syncing. After the big transfer is done, and the folder structure is in place, things will go to the correct disk(s).

Did you try setting sort sync alphabetically ?

This should not matter, as directory creation is always the first thing that happens.

Of course, I can’t imagine a file being created before the directory it’s linked to. I just suggested to Ben that maybe using alphabetic sort for syncing would create the directories just at the moment they are needed, i.e. not created now and fully populated later at default random choice… whatever this is just a guess and I’m sure I understood his problem.

I’m not even sure he knows that tmp files are created as sparse, i.e. they reserve the space required (IIUC).

No, what I mean is that all directories get created first before we start downloading files, regardless of the pull order.

Yup, changing the pull order doesn’t fix it. From my understanding there’s no way to fix it without changing how Syncthing works. My solution was just to do a manual file transfer, and then use Syncthing to sync once a day or so. This was really only an issue because I was trying to sync dozens of TB of data at the same time.

Folder sructure ? All have the same, or all are different. Which are the criteria?

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