Advertisement
Guest User

Untitled

a guest
Jul 22nd, 2017
57
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Bash 0.16 KB | None | 0 0
  1. #!/bin/sh
  2. lockfile=/tmp/rsync.lock
  3.  
  4. [ -f "${lockfile}" ] && exit 100
  5.  
  6. echo $$ > ${lockfile}
  7.  
  8. rsync -avP /source user@host:/destination
  9.  
  10. rm -f ${lockfile}
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement