I have a nas set up an am trying to rsync files to it. It works fine for file I own
$ id dogmatic69
uid=1000(dogmatic69) gid=1000(dogmatic69) groups=1000(dogmatic69),4(adm),20(dialout),24(cdrom),33(www-data),46(plugdev),110(lpadmin),111(sambashare),112(admin)
The problem files belong to the www-data user
$ id www-data
uid=33(www-data) gid=33(www-data) groups=33(www-data)
When running there are loads of errors like:
rsync: failed to set permissions on "/some/file": Operation not permitted (1)
I have tried setting up the share for both users but still get the issue
sudo smbmount //server/development development -o credentials=/home/dogmatic69/.smbpassword,uid=33,gid=33
and
sudo smbmount //server/development development -o credentials=/home/dogmatic69/.smbpassword,uid=1000,gid=1000
all the source files are owned by www-data and have g+rw so the user dogmatic69 can view / edit them.
$ ls -al
total 956
drwxrwxr-x 11 www-data www-data 4096 2012-06-21 14:09 .
drwxr-xr-x 13 root root 4096 2012-06-26 11:44 ..
drwxrwxr-x 17 www-data www-data 4096 2012-06-21 14:10 folder1
drwxrwxr-x 7 www-data www-data 4096 2010-10-11 02:24 folder2
-rw-rw-r-- 1 www-data www-data 510649 2011-05-26 20:48 file.html
-rw-rw-r-- 1 www-data www-data 78792 2011-05-26 20:15 other.html
Any idea how I can set this up so there are no errors and possibly keep the owner details correct.
Edit:
The server hosting the files is a linux based NAS, it is a simple box with no ssh and the choice of NFS or SMBFS. I played with NFS but found it pretty crap and a few people said its quite dated.