I have an NFS mount on my Linux server. Sometimes the NFS server is unavailable and is not mounted.
How can I tell Syncovery to first check if the NFS mount is mounted before running the job? If it is not mounted, then don't run the job.
Check if NFS mount is mounted before running job
-
- Posts: 140
- Joined: Sun Nov 20, 2022 5:11 am
Re: Check if NFS mount is mounted before running job
Hello,
the easiest solution is the checkmark
"Run Only If Neither Side Is Empty"
on the "Job" tab sheet in the profile.
the easiest solution is the checkmark
"Run Only If Neither Side Is Empty"
on the "Job" tab sheet in the profile.
-
- Posts: 140
- Joined: Sun Nov 20, 2022 5:11 am
Re: Check if NFS mount is mounted before running job
Oh. Brilliant.
That will work most of the time I think.
Sometimes when the NFS server is down, and my computer is rebooted, it can't mount the NFS mount but the folder is still there on the root disk. And so sometimes files end up writing to it.
But this should work good enough for me.
Or maybe, is there a pascal script I could run that checks for the existing of a specific file and if that file is not there then it doesn't run the job?
That will work most of the time I think.
Sometimes when the NFS server is down, and my computer is rebooted, it can't mount the NFS mount but the folder is still there on the root disk. And so sometimes files end up writing to it.
But this should work good enough for me.
Or maybe, is there a pascal script I could run that checks for the existing of a specific file and if that file is not there then it doesn't run the job?
Re: Check if NFS mount is mounted before running job
Hello,
yes, you can use this script:
yes, you can use this script:
Code: Select all
function OnProfileStart:Boolean;
begin
Result:=FileExists('/mnt/volxyz/signalfile.txt');
end;
-
- Posts: 140
- Joined: Sun Nov 20, 2022 5:11 am
Re: Check if NFS mount is mounted before running job
Love it. Thank you!