Rsync v: 3.0.1 OS: IRIX 6.5.28f HW Plat: SGI 2400 Disclaimer: I am running rsync 3.0.1. It's difficult and costly for us to get new versions put on our system, so I'm hoping you will all help me out anyways. If the solution is indeed suspected in a later version of rsync, then we will go through the pain to get it installed. Problem: Rsync seems to always synch soft links instead of only synching "new" ones. I have 2 machines and I run 2 rsync commands from one of them to keep them in synch. First I rsync to the remote box and have it send the local side all new stuff (rsync -auvz) and then I rsync from the local box and send the local new stuff back. This works really well for standard files and directories... but it breaks on soft links. On the first rsync I will get an older link from the remote site copied over a newer link on the local side. It seems to always synch the links as opposed to comparing the age. Is there a way around this? Or, is there indeed a fix in a later version of rsync? I will check the mailing list, but please feel free to e-mail me directly. Best for me would be to send to both. Thanks, Matt Jones Lockheed Martin -------------- next part -------------- HTML attachment scrubbed and removed
On Fri, 2009-01-23 at 09:57 -0700, Jones, Matthew L (N-Scitor) wrote:> I have 2 machines and I run 2 rsync commands from one of them to keep > them in synch. First I rsync to the remote box and have it send the > local side all new stuff (rsync ?auvz) and then I rsync from the local > box and send the local new stuff back. This works really well for > standard files and directories? but it breaks on soft links. On the > first rsync I will get an older link from the remote site copied over > a newer link on the local side. It seems to always synch the links as > opposed to comparing the age.This is by design: the man page description for --update says that it only applies to regular files. I believe the original rationale was that regular files are the only files for which mtimes are both meaningful and arbitrarily settable, but perhaps that should be reconsidered now that Linux can set symlink mtimes. In any case, rsync is not designed for two-way synchronization. The recommended solution is to use Unison ( http://www.cis.upenn.edu/~bcpierce/unison/ ).> I will check the mailing list, but please feel free to e-mail me > directly. Best for me would be to send to both.Sending to both is in fact my default behavior. :) -- Matt
Thanks, Matt. I will take a look at Unison. Matt Jones Lockheed Martin -----Original Message----- From: Matt McCutchen [mailto:matt@mattmccutchen.net] Sent: Friday, January 23, 2009 12:03 PM To: Jones, Matthew L (N-Scitor) Cc: rsync@lists.samba.org Subject: Re: Soft link trouble with rsync on SGI On Fri, 2009-01-23 at 09:57 -0700, Jones, Matthew L (N-Scitor) wrote:> I have 2 machines and I run 2 rsync commands from one of them to keep > them in synch. First I rsync to the remote box and have it send the > local side all new stuff (rsync ?auvz) and then I rsync from the local > box and send the local new stuff back. This works really well for > standard files and directories? but it breaks on soft links. On the > first rsync I will get an older link from the remote site copied over > a newer link on the local side. It seems to always synch the links as > opposed to comparing the age.This is by design: the man page description for --update says that it only applies to regular files. I believe the original rationale was that regular files are the only files for which mtimes are both meaningful and arbitrarily settable, but perhaps that should be reconsidered now that Linux can set symlink mtimes. In any case, rsync is not designed for two-way synchronization. The recommended solution is to use Unison ( http://www.cis.upenn.edu/~bcpierce/unison/ ).> I will check the mailing list, but please feel free to e-mail me > directly. Best for me would be to send to both.Sending to both is in fact my default behavior. :) -- Matt