Re: [Hampshire] rsync usage

Top Page

Reply to this message
Author: Bob Dunlop
Date:  
To: Hampshire LUG Discussion List
Subject: Re: [Hampshire] rsync usage
On Tue, Oct 02 at 12:46, Chris Dennis wrote:
...
> But does geneweb have write permission on directory /var/lib/? The error
> mentions /var/lib/geneweb/. -- note the final dot -- so it's trying to set
> the timestamp of the geneweb directory, which means updating an entry in
> the parent directory.


Actually you don't need write permission on the parent directory since
time information etc is stored in the files inode (file meta info) which
is not part of the directory. File creation, moving and deletion require
write permission on the directory.

Reading the manuals (in this case utime(2)) means you learn something every
day.

To set the times on a file to anything other than the current time you
need to be the *owner* of the file or root. Write permissions and group
ownership don't come into it.


John, you either need to change ownership of the receive tree to your local
user or run the rsync as root. Since your current errors only refer to
directories you could add --omit-dir-times to the rsync flags but this is
not a true solution and I'd predict problems in the future.

-- 
        Bob Dunlop