--- In lucknow-lug@yahoogroups.com, anujsingh_1 <no_reply@...> wrote:
>
> It is fairly simple to configure and use rsync. rsync has many features which
suites for
> mirroring data among two or nore unix based systems in a LAN/WAN enviornment.
> I am using redhat enterprise linux 4 in example below.
> Operating system RHEL4
>
> Configuring rsync server
>
> 1. Configure /etc/rsyncd.conf
>
>
> By default the configuration file is called /etc/rsyncd.conf
>
> uid = nobody
> gid = nobody
> use chroot = yes
> read only = yes
> #limit access to private LANs
># hosts allow=192.168.10.0/255.255.0.0 10.0.0.0/255.0.0.0
172.16.0.0/255.240.0.0
hosts allow=10.1.10.0/255.255.0.0 10.0.0.0/255.0.0.0 172.16.0.0/255.240.0.0
^^correction , use ip according to your n/w
> hosts deny=*
> max connections = 5
> motd file = /etc/rsync/rsyncd.motd
> #This will give you a separate log file
> log file = /var/log/rsync.log
> #This will log every file transferred - up to 85,000+ per user, per sync
> transfer logging = yes
> log format = %t %a %m %f %b
> syslog facility = local3
> timeout = 300
> [MirrorDATA]
> path = /home/rolo
> comment = Mirror data on master server
> exclude = usr/ etc/
>
> 2. On rhel rsync is under xinted services .
> Edit /etc/xinetd.d/rsync file as follows
>
> just change disable = yes to disable = no so that the rsync service can be
started.
>
> # default: off
> # description: The rsync server is a good addition to an ftp server, as it \
> # allows crc checksumming etc.
> service rsync
> {
> disable = no
> socket_type = stream
> wait = no
> user = root
> server = /usr/bin/rsync
> server_args = --daemon
> log_on_failure += USERID
> }
>
>
>
> 3. Now restart the xinted service:
>
> [root@master-server ~]# /etc/init.d/xinetd restart
> Stopping xinetd: [ OK ]
> Starting xinetd: [ OK ]
>
>
> 4. Check the service running.
>
> [root@master-server ~]# lsof -i |grep rsyn
> xinetd 26448 root 5u IPv4 104750 TCP *:rsync (LISTEN)
>
>
> Now on client machine you can use rsync command to copy data using command.
>
> [anuj@client-server ~]$ rsync -avz rsync://10.1.10.1/MirrorData
> holy-moly WTF you doing here.
>
> receiving file list ... done
> drwxr-xr-x 4096 2008/02/18 12:19:09 .
> drwxr-xr-x 4096 2008/02/18 12:19:09 alsa-utils-1.0.6
> -rw-r--r-- 18009 2008/02/18 12:19:09 alsa-utils-1.0.6/COPYING
> -rw-r--r-- 883 2008/02/18 12:19:09 alsa-utils-1.0.6/ChangeLog
> -rw-r--r-- 757 2008/02/18 12:19:09 alsa-utils-1.0.6/README
> -rw-r--r-- 187 2008/02/18 12:19:09 alsa-utils-1.0.6/TODO
>
> sent 78 bytes received 179 bytes 514.00 bytes/sec
> total size is 19836 speedup is 77.18
>
>
> Anuj Singh.
>