redundant server

Martin Pool mbp at samba.org
Wed Sep 5 06:30:50 EST 2001


On  5 Sep 2001, robert slater <robert at synapticserver.com> wrote:
> Hello all
> i am sorry to bring what may seem like a silly question to this list..
> 
> I have to set up a server to sync with the main server.[local network]
> This needs to be done to an entire directory tree an to be done as often as is practical.
> The aim is to have a synchronised server to satisfy stringent redundancy .
> What happens if i set a cron job on to rsync hourly and the process takes 65mins?

That depends on your script.  If you start two copies in the same
directory, then rsync will 'do what you say, not what you want'.  So,
you should make your script do some kind of locking mechanism, or just
run

  while true; do rsync -avz foo bar; sleep 5m; done

There are example scripts on the net to do this...

> Does a new process start and the "old" one continue?
> It also needs to verify the contents of the files  checksum -c ? 

The files will be byte-for-byte identical.  If you need the 'checksum
-c' output you will need to runn that yourself.

> I read in a previous post that timestamps were important. 
> Would it be worth setting synchronisation with a time server?

Yes, worthwhile but not absolutely necessary.  If you use -a, rsync
will set the timestamps on the first transfer, and check them in the
future.  But if the clocks are not synchronized, the second machine
will think the timestamps are wierd.

--
Martin




More information about the rsync mailing list