bindiego
9/12/2014 - 6:39 AM

backup and synchronization

backup and synchronization

#!/bin/bash -ex

tar czf - r2 r2.cn/ r2.edanzediting.com/ | ssh -p 2323 wubin@192.168.0.113 'tar xzf - -C /home/wubin/workspace/tmp/gitplay'
#!/bin/bash -ex

#Local:  rsync [OPTION...] SRC... [DEST]

#Access via remote shell:
# Pull: rsync [OPTION...] [USER@]HOST:SRC... [DEST]
# Push: rsync [OPTION...] SRC... [USER@]HOST:DEST

#Access via rsync daemon:
# Pull: rsync [OPTION...] [USER@]HOST::SRC... [DEST]
#   rsync [OPTION...] rsync://[USER@]HOST[:PORT]/SRC... [DEST]
# Push: rsync [OPTION...] SRC... [USER@]HOST::DEST
#   rsync [OPTION...] SRC... rsync://[USER@]HOST[:PORT]/DEST


rsync -acvz wubin@asof.eja.hk:/var/www/html/asof/* .
#!/bin/bash

# crontab settings
# 0 3 * * * <path to file>/homedir_bak.sh

rsync -acz /home/wubin /data/backup/wubin_home > /dev/null 2>&1 &