John D. Hendrickson
2002-May-17 22:35 UTC
update wrong date, soft links, Debian stable, -L, ...
Debian r2.5 (Potato) rsync version 2.3.2 protocol version 21 ( the latest stable deb version anyway :) RE: absolutely older file keeps getting chosen for update Hi. I have something like: rsync -vxuaz /sendmail/ /mnt/nfs-mount/sendmail In the nfs drive the files are links to other files in a subdirectory of that same directory. Both the links and the files they point to are newer in every respect (both 'stat' and 'newer' say so) than the files in /sendmail. However - rsync chooses the older files in sendmail as updates to the newer files (newer ones get clobbered) -- but only on soft-linked files. If I use the -L option this happens with only one file. BUT even after writing the file (on the nfs drive) to make it today's date across the board, rsync still chooses the older file -- even with the -L option. -------------------------------- The man page says -u chooses the newer date base on mod time. The -L option I though a little unclear - it says treat links like files - but that leaves me wondering as I don't know the special rules for treating links and whether the -a option effects that still. I'll have to admitt I haven't searched all 10MB of prev. questions. Anyway, thanks - I get allot of mileage out of rsync: its a ton better than writing a shell script using rcp :) John Hendrickson jdh@hend.net johndhendrickson22124@yahoo.com PS My most desired feature is: If you use user@host:/directory notation right on host, rysnc won't grok it (you gotta use /directory if your executing on host). That means scripts must be different depending on which host they run on. Hopfully, newer versions of rsync would resolve the remote spec down to a local spec (if host is local) before using it. Guess you knew that :)
On Sat, 2002-05-18 at 01:32, John D. Hendrickson wrote:> Debian r2.5 (Potato) > rsync version 2.3.2 protocol version 21 > ( the latest stable deb version anyway :) > > RE: absolutely older file keeps getting chosen for updateThis could be some sort of NFS bug, but you might want to try the latest version of rsync (2.5.5) to see if it solves the problem. It's pretty easy to recompile it for potato; install libpopt-dev, and dpkg-source -x the sources, then cd rsync-2.5.5 && fakeroot dpkg-buildpackage -us -uc. If you don't feel like doing that, I've put up rsync 2.5.5 compiled for potato on i386 here: http://people.debian.org/~walters/debian/staging/