running realtime backup as a task

Get help for specific problems
Posts: 31
Joined: 2 Oct 2019

davidwf

I have been running a nightly file sync for a few months, called from a batch file that is in turn triggered by a system task which wakes the PC (the batch file later triggers an Acronis backup task when FFS completes) and it all works fine

I recently attempted to create a task to run FFS in realtime backup mode, starting when the PC starts and failed

I followed the guides / examples in the help section and copied in my original ".ffs_batch" file
I call the realtimesync exe file with the task, additionally adding the location of the newly saved "realtime.ffs_real" file in the arguments section of the scheduled task as per the attached
I set the user account to be system
I do not use the UAC notifications which are turned off in control panel and always have been

The task starts OK with the PC and two instances of realtime sync appear in task manager but it doesnt pick up any changes or create any sync entries if new test files are created

If I manually start the realtimesync program (the red icon) it both starts and picks up any changes as expected

I cannot see why it doesnt work with the task scheduler, I have set the task to run as windows 10 and also tried running with the the highest privileges which made no difference
Attachments
2.JPG
2.JPG (140.49 KiB) Viewed 1448 times
1.JPG
1.JPG (70.29 KiB) Viewed 1448 times
User avatar
Posts: 4056
Joined: 11 Jun 2019

xCSxXenon

Your picture of Task scheduler shows you running FFS, not RTS. The picture labeled "2", the top one, looks correct, you need to save that as a .ffs_real file. Then in the task scheduler, you run "XXXX\RealTimeSync.exe" with the location to the .ffs_real file as the paramater
Posts: 31
Joined: 2 Oct 2019

davidwf

oops, made a bit of a mess of that - my apologies...I AM triggering RTS - I posted the wrong pics from earlier experimentation!.... I have also moved the file to another location (again posted incorrectly)....
This is the argument box content
"D:\Misc_Updates\__daily backups RealTime.ffs_real"
3 shows the correct task and 4 shows its' location
Attachments
4.JPG
4.JPG (33.84 KiB) Viewed 1441 times
3.JPG
3.JPG (37.85 KiB) Viewed 1441 times
User avatar
Posts: 4056
Joined: 11 Jun 2019

xCSxXenon

The task should run as the normal user that you log in with. You also mentioned two RTS icons showing up? Don't you only have the one config?
Posts: 31
Joined: 2 Oct 2019

davidwf

I meant two instances in task manager as here
Attachments
5.JPG
5.JPG (28.4 KiB) Viewed 1437 times
User avatar
Posts: 4056
Joined: 11 Jun 2019

xCSxXenon

Confirm that you are running the task as the user you are logged in as. If it works when you manually run it, it should work with a task
Posts: 31
Joined: 2 Oct 2019

davidwf

It seems to work if I set it as my user account but not if I set it as system - which is what the guide suggests ......
User avatar
Posts: 4056
Joined: 11 Jun 2019

xCSxXenon

I was just trying to see if it worked or not. Since it did, that tells us your setup and commands are correct. SYSTEM must not have access to the locations you are trying to monitor/sync. You could leave it as your user if you only care if it runs while you are logged in. SYSTEM would allow it to run whenever since SYSTEM is always "logged in".
Posts: 31
Joined: 2 Oct 2019

davidwf

Thanks again for your quick response and advice....problem is I DO need it to run all the time and have several users on the PC hence SYSTEM should be the ideal solution
Posts: 31
Joined: 2 Oct 2019

davidwf

Thank you again for your prompt response and advice
I have now managed to get it to work on all user accounts as attached

I THINK these were the issues:
The inverted commas may have been copied & pasted wrongly - possibly from an Outlook email
There was a space in the arguments line where there should have been a backslash
It would not (and still will not) however run under the "system" account as I believe it should - and as the help file suggests it should....however I am not going to mess with it as it is now working!!!
Attachments
8.JPG
8.JPG (159.37 KiB) Viewed 1422 times
7.JPG
7.JPG (110.77 KiB) Viewed 1422 times
6.JPG
6.JPG (117.48 KiB) Viewed 1422 times
Posts: 31
Joined: 2 Oct 2019

davidwf

Marked as answered
User avatar
Posts: 4056
Joined: 11 Jun 2019

xCSxXenon

Awesome! Glad you got it working
Posts: 31
Joined: 2 Oct 2019

davidwf

I decided to try and resurrect this as I believe it should work as a system task
A (long suffering) colleague suggested using NETWORKSERVICE rather than SYSTEM but again it simply doesnt work....
It does however work perfectly if I start RTS once I am logged in to windows so I believe the arguments and settings are all correct
I tried adding the command line to windows user startups
<< C:\Users\David\AppData\Roaming\Microsoft\Windows\Start Menu\Programs\Startup >> and it works fine from there but of course if another user logs on or switches user without me logging off it triggers two or more instances of the program which then fight with each other waiting for the sync.ffs_locks to clear
My colleague also suggested that it could be because SYSTEM doesnt have the relevant access permissions to the NAS where the backups are stored.....I would like to get this working properly as I have found it to be an otherwise faultless program.
User avatar
Posts: 2451
Joined: 22 Aug 2012

Plerry

You indicates the task as "continuous FFS".
However, FFS will not run continuously.
You can have the Task Scheduler launch a RealTimeSync (RTS) job to monitor one or more specified location(s) for changes, and upon detecting any such change, launch a specified FFS sync (*.ffs_batch), which will then run a single sync and then close (see the Attention remarks)
User avatar
Posts: 4056
Joined: 11 Jun 2019

xCSxXenon

@davidwf
If you put it into your user startup folder, it won't launch when another user logs in, that's the whole point of having your own startup folder. Your colleague nailed the issue though. The normal user may have access to a network location, but if SYSTEM doesn't, running the task as SYSTEM won't work.
One workaround I have implemented is having a user account auto-login so that the user startup items run. Once it logs in, I have a task scheduled to then lock the computer after the user logs in. This does bypass the password and I have seen it take anywhere from 0 to 10 seconds to lock itself. Luckily, I am using it in an environment where that small window presents no real risk to being compromised, if the task can be interrupted anyway to leave it logged in. Also, there is no personal data on it, it is simply a resource location for tools.
Posts: 31
Joined: 2 Oct 2019

davidwf

Finally got this to work properly - it starts per user and only runs one session
Attachments
2.PNG
2.PNG (327.31 KiB) Viewed 862 times
1.PNG
1.PNG (376.62 KiB) Viewed 862 times
Posts: 31
Joined: 2 Oct 2019

davidwf

still having some issues with RTS...the (should be red) icon in the system tray shows grey and has a message that it is "waiting until directory xxxx becomes available" and obviously sync is not happening

I have re-arranged the folder list and proved that it is not any particular folder causing the problem

I am running the task as above and syncing to my NAS drive, which I can freely access from file explorer etc.

suddenly and for no apparant reason or time the icon will go red and the message disappears and sync happens

I am the only user logged in and have re-started the PC

If I close it and start a new session it is red straight away and sync happens
Attachments
1.jpg
1.jpg (27.53 KiB) Viewed 631 times
User avatar
Posts: 4056
Joined: 11 Jun 2019

xCSxXenon

Are you running it with highest privileges, because it's been noted many times that you can't. That doesn't use your user account and probably doesn't have permissions.
Posts: 31
Joined: 2 Oct 2019

davidwf

sorry...when you say I cant, are you saying I cant do it or that it cant be done?
Attachments
3.JPG
3.JPG (80.34 KiB) Viewed 613 times
Posts: 31
Joined: 2 Oct 2019

davidwf

OK... "you cant because it doesnt work" !!
Having un-ticked the box it now, finally, WORKS :) :) :)
Thanks to all for your help
User avatar
Posts: 4056
Joined: 11 Jun 2019

xCSxXenon

Yes, it can't be done, I don't doubt your skills! It just how Windows handles it, that's all.
Glad it's working for you, here to help!