rsync to a SOHO NAS copies files everytime

Savage, Elijah elijah_savage at
Thu Dec 29 19:52:16 GMT 2005

They are surely off like you indicated, but I get this when I try to
sync the times. I thought this may be some permissions error on the
mount point so I chmod 777 on the backup dir but that did not fix

67 files to consider
rsync: failed to set times on "/musicbackup/.": Bad file descriptor (9)

stat /music/Reggae/Damon\ Marly/01\ -\ Confrontation.mp3 
49869672 7816569 "Dec 29 10:49:53 2005" "Sep  9 22:21:57 2005" "Dec 17
08:04:24 2005" "Sep  9 22:21:57 2005" 16384 15328 0 /music/Reggae/Damon
Marly/01 - Confrontation.mp3

stat /musicbackup/Damon\ Marly/01\ -\ Confrontation.mp3 
4294967295 7816569 "Sep  9 22:21:56 2005" "Sep  9 22:21:56 2005" "Sep  9
22:21:56 2005" "Jul  5 11:30:08 1937" 16644 15266 0 /musicbackup/Damon
Marly/01 - Confrontation.mp3

-----Original Message-----
From: John Van Essen [mailto:vanes002 at] 
Sent: Thursday, December 29, 2005 2:14 PM
To: Savage, Elijah; rsync at
Subject: Re: rsync to a SOHO NAS copies files everytime

On Thu, 29 Dec 2005, Savage, Elijah <elijah_savage at> wrote:
> I am trying to use a SOHO NAS to rsync my music dir to. Every time I
> the command it copies the entire dir and files each time.
> I am using FreeBSD 5.4 with the latest port build and I run the
> below to try and accomplish what I need. But what I have done since
> NAS is running smbfs I have simply mounted this drive with mount_smbfs
> to /musicbackup/. As you can see below it copies every file each time.

If you are copying from a *nix filesystem to a Windows filesystem
(which is implied by your use of mountsmbfs) then the timestamps may
not be matching since Windows uses a 2-second granularity.

Try using the 'stat' command on a file in the source and destination:

  stat "/music/Reggae/Damon Marly/01 - Confrontation.mp3"
  stat "/musicbackup/Damon Marly/01 - Confrontation.mp3"

The "Modify" times should be the same, down to the second.

If they differ by one second, use  --modify-window=1  and that will
allow rsync to match the timestamps.

(Wayne - the "copies every file" entry in the FAQ should also mention
this problem with Windows timestamps.  Even though it may not be "every
file", it may seem like it...)


More information about the rsync mailing list