This is the mail archive of the cygwin mailing list for the Cygwin project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

RE: Rsync link-dest not working for a host with the most recent rsync/cygwin 1.7


Chris Francy wrote:
> It appears something about the about rsync or the 1.7 version of
> cygwin is preventing the --link-destination function of rsync from
> working.  Files that have not been changed at all should be linked
> together.  On the hosts still running a cygwin 1.5 version of rsync
> the link-destination seems to work exactly as I expect it to.
> 
> I am using dirvish (http://www.dirvish.org/) on a Linux box (deb
> 5.0.3) to backup some of the data on windows boxes in the network.  I
> have the cygwin+rsync setup in daemon mode on the servers.  I recently
> upgraded a couple of the boxes to the latest cygwin 1.7.  On the
> systems with cygwin 1.5 files are occasionally missed because of the
> path length limitations so I really want to get a cygwin 1.7 setup
> working.

I'm in a situation somewhat similar to yours. Up to now I have been
using the current stable Cygwin (v1.5) to test rsync as a possible
backup solution. I have a home-baked rsync/--link-dest script that
creates periodic snapshots of the Windows boxes on my LAN, and it
hiccups noisily on long filenames, and on filenames with non-ASCII chars
in them. I am considering trying out the next release of Cygwin (v1.7)
for its supposed fixes to the v1.5 path-length and filename encoding
limitations, but it would really suck if the --link-dest magic stopped
working in v1.7.

> This is the command that is being issued by dirvish to perform the backup.
> 
> rsync -vrltH --delete -pgo --stats -z -D --numeric-ids --timeout=300
> --exclude-from=/srv/dirvish/srv-01/2009101610/exclude
> --link-dest=/srv/dirvish/srv-01/2009101420/tree 10.2.35.241::data/
> /srv/dirvish/srv-01/2009101610/tree

I'm not at all familiar with dirvish, but I've been using rsync quite a
lot. I don't see anything out of the ordinary on the command line. It
appears you are (or rather dirvish is) keeping successive backups on
your Debian box under
/srv/dirvish/srv-01/<date-time-derived-dir-name>/tree/.

Probably a dumb question, but: Are you 100% certain that
2009101420/tree/ and 2009101610/tree/ are on the same filesystem?

> Here is the checksums and the output of stat of two files on my Linux
> box that I should have been linked together.  No changes where made to
> this file on the windows box between the first and second backups.

[Snip the output of 'sha256sum' and 'stat' proving that the following
files on the Debian box are essentially identical:
`2009101420/tree/staff/Supply letter preschool.doc'
`2009101610/tree/staff/Supply letter preschool.doc']

Okay, so the backed-up files appear to be identical in successive
backups on the Debian (destination) side, including many attributes that
one imagines rsync would check for differences (contents, name, size,
type, access perms, ownerships, mod time). If --link-dest were working
correctly, I would expect to see Links > 1 and the two files' Inode
numbers to be the same, but neither is true (Links == 1, and the Inode
numbers are different). Definitely proof that --link-dest is failing to
work as intended. Clearly, rsync on your Debian box thinks that the
source file 'staff/Supply letter preschool.doc' is somehow different
from the existing file in the --link-dest directory.

Just curious: What do 'sha256sum' and 'stat' say about that file on the
Cygwin (source) side?

> I have posted the output of 'cygcheck -s -v -r' here
> (http://pastebin.com/m68d01c02).

Could you post the contents of your rsync daemon's rsyncd.conf ? Are you
using identical rsyncd.conf files in your 1.5 and 1.7 installations?

> I would appreciate some help getting the --list-dest to work properly.
>  If you have some ideas please share.  If you need more information to
> help diagnose or find a solution please ask.

Is --link-dest failing completely (i.e. no hardlinks created at all), or
only partially (i.e. some unchanged files are hardlinked, while some are
merely copied)? What version of rsync is running on the Debian box?

> Thanks,
> Chris Francy

Regards,
-SM
--


--
Problem reports:       http://cygwin.com/problems.html
FAQ:                   http://cygwin.com/faq/
Documentation:         http://cygwin.com/docs.html
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]