Showing results for 
Search instead for 
Did you mean: 

NFS and Netgroups

Matt Sears
Occasional Advisor

NFS and Netgroups

I'm trying to figure out why clients can not mount when a share is exported to a netgroup that the client(s) are specified in. I'm running CENTOS5 - 2.6.18-128.

>cat /etc/exports
/share @my_netgroup(rw,sync,no_root_squash)

>cat /etc/netgroup
my_netgroup (client1,,)

From the server, 'host client1' returns the fqdn and ipaddress of the client.

From client1 I try (and get returned):
>mount -t nfs server:/share /mnt/1
mount: server:/share failed, reason given by server: Permission denied

Messages from mountd on the server say:
mountd: mount request from unknown host for /share (/share)

I know this normally indicates some kind of name resolution issue, but I have tried changing the client host name listed in the /etc/netgroup file to the ip address of the client as well as the fqdn of the client and neither of those ideas worked.

Another interesting thing is that if I use a Red Hat 2.6.18-92 box as the server, it works just fine.

nfs-utils on the RH box is 1.0.9-33.el5.
I am trying to eliminate variables so I retrieved, compiled and installed the base 1.0.9 version of nfs-utils. Both the base 1.0.9 and 1.1.6 versions of nfs-utils produce the same result (with the exception that 1.1.6 mountd give a slightly different message - "refused mount request from for /share (/share): unmatched host".

Any help is greatly appreciated.

Matt Sears
Occasional Advisor

Re: NFS and Netgroups

Well, I finally figured out what was wrong. The /etc/nsswitch.conf file had a line that looked like:

netgroup: nisplus

I changed it to:

netgroup: files nisplus

I may have rexported the shares, but that's really all it took.