User Tools

Site Tools


rsync

This is an old revision of the document!


Rsync

General rsync Commands

Authenticated Rsync

define rsync mount point in rsyncd.conf

| rsyncd.conf
[root]
        path = /srv/www/htdocs
        secrets file = /etc/rsyncd/rsync.secret
        auth users = htdocs
        read only = false
        write only = true
        list = false
| rsync.secret
rsyncusr:password123

NOTE :

  • Password is clear text password.
  • Make sure password file is not world readable else it will fail to authenticate.

Define script for rsync OR run it from command line.

| rsync_test.sh
#!/bin/sh
 
export RSYNC_PASSWORD=password123
/usr/local/bin/rsync -az --delete --exclude='.*' /srv/www/htdocs/ rsync://rsyncusr@rsync.host.com/root/
rsync.1280872470.txt.gz · Last modified: 2020/08/10 02:29 (external edit)