mountd segfaults in NFSv4 if -alldirs is present in exports
George Mamalakis
mamalos at eng.auth.gr
Fri Feb 19 20:09:38 UTC 2010
On 19/02/2010 20:11, George Mamalakis wrote:
> [root at fbsdclient ~]# mount_newnfs -onfsv4,sec=krb5
> filesrv.ee.auth.gr:/export /mnt
> nfsv4 err=10016
> mount_newnfs: /mnt, : Input/output error
I performed some more test on this setup and I can shed a bit more light
to the issue.
My /etc/export on my server (filesrv.ee.auth.gr) reads:
V4: / -sec=krb5
/home
If I run:
# mount_newnfs -onfsv4,sec=krb5 filesrv.ee.auth.gr:/home /mnt
as root, without having kinited to some principal, the partition gets
mounted in /mnt and I can perform operations on it. Once I kinit to some
user I get the error: nfsv4 err=10016
Then, I read the article on
http://code.google.com/p/macnfsv4/wiki/FreeBSD8KerberizedNFSSetup a bit
more thoroughly (with regard to nfsv4), and changed /etc/fstab to read:
V4: / -sec=krb5
/home -sec=krb5
I restarted nfsd and mountd, switched to a simple user (mamalos),
kinited as mamalos principal, and typed:
[mamalos at fbsdclient ~]$ mount_newnfs -onfsv4,sec=krb5
filesrv.ee.auth.gr:/home mnt
where mnt is a directory in mamalos' homefolder owned by that user. Of
course, one has to run sysctl vfs.usermount=1 in order to allow simple
users to mount filesystems (as was already suggested by the
aforementioned article).
This time the mount worked! I ls'd the directory, cd'd to a folder owned
by mamalos (permissions 700), even touched a file in it. The only
problem was that the first time I touched a file, it took a few seconds
for the touch command to complete. After that, all subsequent touch
commands were executed immediately.
So, for the time being, mounting nfsv4 partitions with sec=krb5 has been
established, but with a few limitations.
I'll test now what can be done with solaris and linux clients.
Good night everybody (~GMT+2).
--
George Mamalakis
IT Officer
Electrical and Computer Engineer (Aristotle Un. of Thessaloniki),
MSc (Imperial College of London)
Department of Electrical and Computer Engineering
Faculty of Engineering
Aristotle University of Thessaloniki
phone number : +30 (2310) 994379
More information about the freebsd-stable
mailing list