[ale] One home directory

Brian Pitts brian at polibyte.com
Tue Oct 13 20:12:34 EDT 2009


On 10/13/2009 02:39 PM, Jeff Lightner wrote:
> Unison is based on rsync I believe.  Haven't used it but have heard good
> things about it.
> 
> By unidirectional I assume you mean rsync only updates one side on a
> given run.  I'm not really sure that is the case (I'd have to explore
> flags) but even if it were it only means you'd need to run two separate
> rsync jobs - one that used one side as the source and the other as the
> target and another that used the original source as target and original
> target as source.

That won't work. The first rsync from system one to system two will
clobber all the files you've changed on system two. From the manpage,
'Rsync  finds  files  that  need to be transferred using a “quick check”
algorithm (by default) that looks for files that have changed  in size
or in last-modified time.'

$ mkdir one two
$ touch one/a one/b
$ rsync -av one/ two/
sending incremental file list
./
a
b

sent 138 bytes  received 53 bytes  382.00 bytes/sec
total size is 0  speedup is 0.00
$ ls -l one two
one:
total 0
-rw-rw-r-- 1 brian brian 0 2009-10-13 20:07 a
-rw-rw-r-- 1 brian brian 0 2009-10-13 20:07 b

two:
total 0
-rw-rw-r-- 1 brian brian 0 2009-10-13 20:07 a
-rw-rw-r-- 1 brian brian 0 2009-10-13 20:07 b
$ echo one > one/a
$ echo two > two/b
$ ls -l one two
one:
total 4
-rw-rw-r-- 1 brian brian 4 2009-10-13 20:07 a
-rw-rw-r-- 1 brian brian 0 2009-10-13 20:07 b

two:
total 4
-rw-rw-r-- 1 brian brian 0 2009-10-13 20:07 a
-rw-rw-r-- 1 brian brian 4 2009-10-13 20:07 b
$ cat two/b
two
$ rsync -av one/ two/
sending incremental file list
a
b

sent 151 bytes  received 50 bytes  402.00 bytes/sec
total size is 4  speedup is 0.02
$ cat two/b
$

-- 
All the best,
Brian Pitts


More information about the Ale mailing list