> Here is the problem. > >I have a primary and a secondary web server. I want to sync the home >directory paths on the primary server with the secondary server. I am >fairly ignorant to rsync and wondering what is the best method of doing this >and how would I call the procedure from say a "perl script". >Both Servers are FreeBSD 4.2 and there are actually two directorys I want >to sync 1) /www/home 2) /www/default. Here is my rsyncd.conf file > >##### >motd file = /etc/rsyncmotd >max connections = 5 >syslog facility = local3 > >[home] > path = /www/home > comment = Home Directory Path > uid = nobody > gid = nobody > max connections = 2 > read only = no > >[default] > path = /www/default > comment = ASU Homepage Path > uid = nobody > gid = nobody > max connections = 2 > read only = no >
I sort of have this described at (is a bit out of date but may give some ideas): http://www.ccp14.ac.uk/ccp14admin/rsync Though when will this secure_shell patch(?) be in rsync? ------------- Normally I just call rsync via crontab as often as required - checking that a previous instance of the script is not still running. For an 8 Gig web area - it is only taking rsync a few minutes to recheck for updates. UK to US and UK to Canada. e.g., 43 8,11,14,17 * * * ./mirroring/rsync.mirror.script --------------- Corrections/suggestions appreciated but I use something like the following in the rsyncd.conf - and restrict access to the required computer: (I guess you would want the primary web server to be read only with rsync - and restricted access by password and IP address?) motd file = /etc/motd max connections = 3 syslog facility = local3 [mirror_area] comment = regional mirror area path = /path/to/mirror read only = yes list = yes uid = nobody gid = nobody hosts allow = 666.66.66.66 auth users = rsyncmir secrets file = /etc/where_this_is Lachlan. ----------------------- Lachlan M. D. Cranswick Collaborative Computational Project No 14 (CCP14) for Single Crystal and Powder Diffraction Birkbeck University of London and Daresbury Laboratory Postal Address: CCP14 - School of Crystallography, Birkbeck College, Malet Street, Bloomsbury, WC1E 7HX, London, UK Tel: (+44) 020 7631 6849 Fax: (+44) 020 7631 6803 E-mail: [EMAIL PROTECTED] WWW: http://www.ccp14.ac.uk/