Hi Dean,


Doesn't this mean that if you're logged out, or power cuts, and you want
to retrieve an accidentally deleted file from the NAS that you're racing
against i3's running of rsync with --delete when you log in?

Cheers, Ralph.

Hi Ralph,

This is the downside of running rsync when you log in. However, I gave myself a little wiggle room as I actually use:

exec "sh -c 'sleep 10; rsync -ua --delete /home/weaner [email protected]:/share/backup'"

Which gives me 10 seconds to disconnect from the network before rsync works it magic. The simplified version should be fine for the OP's USB drive as I'm guessing you could simply unplug it before rsync is run.

Cheers,
Dean

--
Next meeting:  Bournemouth, Tuesday, 2017-07-04 20:00
Meets, Mailing list, IRC, LinkedIn, ...  http://dorset.lug.org.uk/
New thread:  mailto:[email protected] / CHECK IF YOU'RE REPLYING
Reporting bugs well:  http://goo.gl/4Xue     / TO THE LIST OR THE AUTHOR

Reply via email to