🇩🇪 Deutsch 🇬🇧 English

17 May 2007

Simple backup using rsync

Simple Backup using rsync

This backs up everything in the directory /srv/www/htdocs on a remote host to the current local directory, deleting removed files on remote host locally:

$ rsync -av --delete chrissie@x-tra-designs.org:/srv/www/htdocs/* .

To back up a complete Linux-System, excluding the system-directories, you may use

$ rsync -av --numeric-ids --delete --exclude /proc --exclude /mnt --exclude /tmp \
  --exclude /sys --exclude /dev/pts --exclude /dev/shm / username@remotehost:

this keeps numeric IDs, may require additional privileges on source host, e. g. root