all_squash Doesn't Seem to Work?
I have an Ubuntu NFS server with one client, a SCO Unix server. My /etc/exports line in Ubuntu is:
Code:
/media/data/meadows/dtechBackup zeus(rw,sync,no_subtree_check,all_squash,anonuid=1014,anongid=1014)
The directory mounts just fine and I can browse it. uid/gid 1014 are the uid/gid of my backup user on Ubuntu. If I'm logged into SCO as root, I can create/delete files just fine. But if I log into SCO as a regular user in a new group I created with gid 1014, creating a file gives the error
Code:
$ touch /dtechBackup/helloworld
touch: cannot change times on /dtechBackup/helloworld: Permission denied (error 13)
The /dtechBackup directory in SCO has permissions 775. Its uid and gid are both 1014. There is no uid 1014 in SCO, but I did create a group with gid 1014.
Does anyone know what's going on here?
Thanks!
edit: added new things I figured out
Re: all_squash Doesn't Seem to Work?
Quote:
Originally Posted by
gfunkdave
I have an Ubuntu NFS server with one client, a SCO Unix server. My /etc/exports line in Ubuntu is:
Code:
/media/data/meadows/dtechBackup zeus(rw,sync,no_subtree_check,all_squash,anonuid=1014,anongid=1014)
The directory mounts just fine and I can browse it. uid/gid 1014 are the uid/gid of my backup user on Ubuntu. If I'm logged into SCO as root, I can create/delete files just fine. But if I log into SCO as a regular user in a new group I created with gid 1014, creating a file gives the error
Code:
$ touch /dtechBackup/helloworld
touch: cannot change times on /dtechBackup/helloworld: Permission denied (error 13)
The /dtechBackup directory in SCO has permissions 775. Its uid and gid are both 1014. There is no uid 1014 in SCO, but I did create a group with gid 1014.
Does anyone know what's going on here?
Thanks!
edit: added new things I figured out
Looks like you'll just need to add the new user to the 1014 group?
Re: all_squash Doesn't Seem to Work?
Quote:
Originally Posted by
dmizer
Looks like you'll just need to add the new user to the 1014 group?
Indeed, that's what I needed to do. Thanks! I hadn't quite understood how file permissions over NFS work. It makes sense that the creator of the file would need to be the owner. :)
Re: HOWTO: NFS Server/Client
Hello,
I'm having a problem that maybe cannot be solved, but I thought I'd ask in case... (sorry if the solution is somewhere along this thread, I haven't been able to find it).
I mount NFS network shares on my computer (using autofs) and it all worked great until the network admins ask me to connect using gid 20 (dialout) instead of mine (1000). Something about group permissions they need to have.
I could change my gid to 20 but would rather connect to the shares with 20, keeping my local gid to 1000. I've read stuff about NFSv4 and id mapping but have no idea how to set up that - I assume it's on the server side which I don't have access to. If I try a "sudo mount -t nfs4 (etc)" I get "mount.nfs4: Protocol not supported" so I assume they don't use it.
So is it possible to change my gid on the NFS share without having any possibility, on my side, to modify it?
Or do I have no other option than modifying my gid to 20 even locally?
Thanks....
Re: HOWTO: NFS Server/Client
Quote:
Originally Posted by
kalyp
So is it possible to change my gid on the NFS share without having any possibility, on my side, to modify it?
Or do I have no other option than modifying my gid to 20 even locally?
I think you have to change your local gid to 20. The NFS client just passes along your current uid/gid to the NFS server.
Re: HOWTO: NFS Server/Client
Quote:
Originally Posted by
gfunkdave
I think you have to change your local gid to 20. The NFS client just passes along your current uid/gid to the NFS server.
No, all you need to do is add a uid/gid 20 to your system and add your current user to the gid 20. Then mount the NFS server with uid/gid 20 instead of 1000.
Re: HOWTO: NFS Server/Client
Quote:
Originally Posted by
dmizer
No, all you need to do is add a uid/gid 20 to your system and add your current user to the gid 20. Then mount the NFS server with uid/gid 20 instead of 1000.
That's exactly what I wanted to do but couldn't figure out how.
I'm already part of gid 20 (dialout) but can't find the way to mount the server with gid 20 instead of 1000. Adding "gid=20" to my autofs configuration works with samba shares, not NFS...
Thanks!!!
Re: HOWTO: NFS Server/Client
Quote:
Originally Posted by
quad3d@work
Had some serious speed problem with Samba. Setting up NFS from your guide works well! Now I'm doing 30-40Mb (gigabit network) per sec instead of 1-3Mb with Samba. Thanks!
Same here (Ubuntu server 10.04 LTS and Ubuntu client 10.04 LTS) I even tried transferring a file at a speed of 45 mb/s. The file was 3.3 GB. Minimum speed is about 30 mb/s for larger files.
Re: HOWTO: NFS Server/Client
having problems .. installed a new hd - volume name = L-Films
I want to share the whole of the drive to all IP addresses on the network - I can see the drive from other machines, but can't see any files. Obviously I have done something wrong!
/etc/exports:-
Code:
/Lfilms 192.168.1.0/24(rw,no_root_squash,async)
Code:
andrew@linuxpc:~$ mount
/dev/sda1 on / type ext4 (rw,errors=remount-ro)
proc on /proc type proc (rw,noexec,nosuid,nodev)
none on /sys type sysfs (rw,noexec,nosuid,nodev)
none on /sys/fs/fuse/connections type fusectl (rw)
none on /sys/kernel/debug type debugfs (rw)
none on /sys/kernel/security type securityfs (rw)
none on /dev type devtmpfs (rw,mode=0755)
none on /dev/pts type devpts (rw,noexec,nosuid,gid=5,mode=0620)
none on /dev/shm type tmpfs (rw,nosuid,nodev)
none on /var/run type tmpfs (rw,nosuid,mode=0755)
none on /var/lock type tmpfs (rw,noexec,nosuid,nodev)
none on /lib/init/rw type tmpfs (rw,nosuid,mode=0755)
none on /var/lib/ureadahead/debugfs type debugfs (rw,relatime)
binfmt_misc on /proc/sys/fs/binfmt_misc type binfmt_misc (rw,noexec,nosuid,nodev)
gvfs-fuse-daemon on /home/andrew/.gvfs type fuse.gvfs-fuse-daemon (rw,nosuid,nodev,user=andrew)
/dev/sdb1 on /media/L-Films type ext2 (rw,nosuid,nodev,uhelper=udisks)
nfsd on /proc/fs/nfsd type nfsd (rw)
gvfs-fuse-daemon on /root/.gvfs type fuse.gvfs-fuse-daemon (rw,nosuid,nodev)
set permissions for the drive & dirs to 777
I also have /media/L-Films
any ideas please??
Re: HOWTO: NFS Server/Client
Quote:
Originally Posted by
oldfart101
having problems .. installed a new hd - volume name = L-Films
Did you create a mountpoint in /etc/fstab for your new hard drive? If not, you'll be unable to share it via NFS.