User Tools

Site Tools


rsync

rsync is an open source utility that provides fast incremental file transfer.

Serveur

/etc/rsyncd.conf

log file = /var/log/rsyncd.log
pid file = /var/run/rsyncd.pid
lock file = /var/run/rsync.lock

[web]
path = /var/www/
read only = yes
use chroot = no
hosts allow=192.168.144.0/255.255.255.0
hosts deny=*

Dans /etc/default/rsync, changer

RSYNC_ENABLE=false

en

RSYNC_ENABLE=true

Démarrer le service:

/etc/init.d/rsync start

On peut vérifier qu'il tourne:

 netstat -a | grep rsync
tcp        0      0 *:rsync                 *:*                     LISTEN

Client

Depuis le client, taper:

rsync --verbose  --progress --stats --recursive narsil:/var/www/* /home/backup/web/ > rsync_web.log
rsync --verbose  --progress --stats --recursive narsil:/var/lib/mysql/* /home/backup/db/ > rsync_db.log
rsync.txt · Last modified: 2013/01/30 17:50 by 127.0.0.1