RFE: Lockfile option for use in cronjobs

Dag Wieers dag at wieers.com
Mon Mar 31 09:43:12 GMT 2008


Hi,

Looking for an easy way to prevent a repetitive rsync to be running 
multiple times, I was wondering if it could be useful to have an option 
like:

 	--pidfile /some/path/rsync-mirror-org.pid

So that rsync can be run directly from cron without requiring a wrapper 
script to do pidfile handling.

This way rsync on startup could check the pid-file, see if another rsync 
is using this pid, and bail out with an error if it is. Otherwise clean up 
the stale pidfile and continue.

I think this would be very useful to instruct mirrors how to configure it, 
rather than providing some script that needs local customizations.

Thanks in advance,
-- 
--   dag wieers,  dag at wieers.com,  http://dag.wieers.com/   --
[Any errors in spelling, tact or fact are transmission errors]


More information about the rsync mailing list