rsync

rsync command with exclude option, full server backup to a remote server.

rsync -avz --progress --human-readable "-e ssh -p 3333" --exclude /backup --exclude /proc --exclude /sys / root@REMOTE_SERVER_IP:/backup/serverX/

Transfer a file

I normally use scp to do single file transfer. It may be better to it with rsync as you will be able to resume.

rsync -P -e ssh root@SERVER_IP:/path/to/file.tar.gz /local/path/

-P == –partial –progress

If you use non standard SSH port, then replace -e ssh with “-e ssh -p PORT_NUMBER”.

Example

boby@hon-pc-01:~$ rsync -P "-e ssh -p 3333" root@s12:/home/cloud-architect.tar.bz2 /backup/learn/cloud-architect.tar.bz2
  3,120,159,768 100%  995.98kB/s    0:36:27 (xfr#1, to-chk=0/1)
boby@hon-pc-01:~$ 

See backup

Comments

Leave a Reply

Your email address will not be published. Required fields are marked *