How to run all batch's

Get help for specific problems
Posts: 10
Joined: 4 Oct 2016

pstoric

I have 4 folders that I plan on crating 4 separate batch jobs for but I do want to schedule them to run nightly. Instead of making 4 separate tasks in Windows task scheduler is there a way to run them all one after the other?
Posts: 2
Joined: 5 Oct 2016

appoidDE

Same question here. I have 5 batches and want to run them with one click.
User avatar
Posts: 2294
Joined: 22 Aug 2012

Plerry

There seem to be several options here.
- You can define a single sync with multiple left-right folder pairs and (if required) folder-pair specific compare-, filter- and sync-settings.
See e.g. viewtopic.php?t=3744
You can save that configuration as a *.ffs_batch file and call that single configuration.
You can achieve the same by calling all *.ffs_gui and/or *.ffs_batch files in one FFS call,
see https://freefilesync.org/manual.php?topic=command-line "4. Merge multiple configurations"

- You can select multiple configurations in the FFS-GUI and then run (requires action via GUI)
See e.g. https://freefilesync.org/manual.php?topic=tips-and-tricks#select-multiple-configurations "Select multiple configurations at a time"

- You can individually call the different batch-files that define the individual syncs.
This creates multiple instances of FFS to run in parallel (normally only works if there is no overlap between the syncs) or you can call multiple batch-files in one FFS-call (=first bullet).
See: viewtopic.php?t=2429
Posts: 2
Joined: 5 Oct 2016

appoidDE

That's really simple. Thanks for your help.Unfortunately this post ist hard to find, because simple searches like "batch" or "batch file" didn't work. These words are too common and will be ignored in the forum search.
Posts: 10
Joined: 4 Oct 2016

pstoric

Bingo, just what I was looking for. Thanks for the help
Posts: 10
Joined: 4 Oct 2016

pstoric

One last question. Looking at their example, running the following command would run them one by one in order correct?

FreeFileSync.exe "D:\test1.ffs_gui" "D:\test2.ffs_batch" "D:\test3.ffs_batch"
User avatar
Posts: 2294
Joined: 22 Aug 2012

Plerry

One last question. Looking at their example, running the following command would run them one by one in order correct?
FreeFileSync.exe "D:\test1.ffs_gui" "D:\test2.ffs_batch" "D:\test3.ffs_batch"pstoric
I don't think so.
The above will result in a single sync with multiple left-right pairs (with individual compare- filter- and sync-settings). The sync will first compare all left-right pairs (effectively deciding/proposing what files to copy or move where) and only then executes the actual sync.
Any dependencies/overlaps that might exist between the folder pairs involved will not result in extra file copy or move actions. E.g. If pair 1 syncs folder A with folder B, and pair 2 syncs folder B with folder C, any files to be synced from pair 1 A to B will not show up in the compare of pair 2 between B and C, as those files do not exist of have not been updated yet on B at the time of the compare.
If you have such dependencies (FFS warns you when running the sync if such overlap/dependencies exist), you really need to run consecutive syncs in the proper sequence.
Your batch file should then call the syncs independently in the correct sequence and make sure the previous sync has ended before launching the next sync. You might then try using the START /WAIT FreeFileSync.exe "D:\test1.ffs_gui" command for calling each of the syncs.
Posts: 10
Joined: 4 Oct 2016

pstoric

Ah ok so run the .exe with each one job per line. Got it.