Loading...
 

RSync

Server

Server configuration (rsyncd.conf)

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

[simple_path_name]
   path = /rsync_files_here
   comment = My Very Own Rsync Server
   uid = nobody
   gid = nobody
   read only = no
   list = yes
   auth users = username
   secrets file = /etc/rsyncd.scrt

Run rsyncd –daemon on the server

Client

rsync --verbose  --progress --stats --compress --rsh=/usr/bin/ssh --recursive --times --perms --links /local/path server_name:/remote/path/

rsync --verbose  --progress --stats --recursive --times --compress /local/path/* user@server_name:remote/path/

Directory slashes are important for what is copied


Verbose, progress and stats are only needed as information.

If ssh authorised_keys are on the server, this can be added to cron.