I'm trying to connect to an NFS drive shared from my Debian Squeeze box from my OSX 10.6 laptop, and try as I might I can't get it to let me write to the disk from the mac. I have the following in /etc/exports:
/mnt/usbdrive 192.168.1.0/24(rw,insecure,sync,no_subtree_check,all_squash,anonuid=1000,anongid=1000)
making all requests come from UID/GID 1000/1000, my user, who owns the whole drive. However, when I mount the drive on the Mac, everything is owned by 1000/1000 as well, so I can never write to the disk:
~> ls -la /Volumes/USBDrive/
drwxr-xr-x 6 1000 1000 4096 5 Sep 19:31 .
drwxrwxrwt@ 4 root admin 170 6 Sep 22:41 ..
drwx------ 2 1000 1000 16384 28 Aug 21:24 lost+found
drwxr-xr-x 2 1000 1000 4096 29 Aug 15:35 music
I've seen a few other people having this problem, but the only solution I've seen is to chmod the whole disk 777, which I'd rather avoid. Unfortunately I can't use nfs-user-server on my system so I can't use UID/GID mapping.
Best Answer
Rather than assign all files to uid 1000, assign all files to your uid on the Mac (run
id -u
in a terminal to see your uid). While you're at it, do the same for the gid (id -g
).