Hello,
I recently set up a VM running Debian Wheezy (amd64) to be used as an NFS server. I noticed that running "/etc/init.d/nfs-kernel-server start" would hang for about 60 seconds while starting nfsd, but if I started nfsd directly, there was no problem. After a lot of strace adventures and Google searches, I eventually traced the problem to the "rpcinfo" command. I commented out the following lines from the nfs-kernel-server init script, everything started working:
$PREFIX/bin/rpcinfo -u localhost nfs 3 >/dev/null 2>&1 ||
RPCMOUNTDOPTS="$RPCMOUNTDOPTS --no-nfs-version 3"
Indeed, running "rpcinfo -u localhost nfs 3" causes a long pause before it finally outputs the following:
rpcinfo: RPC: Port mapper failure - Timed out
program 100003 version 3 is not available
Running "rpcinfo -p localhost" causes the same long pause, and then outputs this:
rpcinfo: can't contact portmapper: RPC: Remote system error - Connection timed out
Running "showmount --exports" results in the long pause, and then outputs this:
clnt_create: RPC: Port mapper failure - Timed out
However, running "rpcinfo -p" without specifying the host returns immediately:
program vers proto port service
100000 4 tcp 111 portmapper
100000 3 tcp 111 portmapper
100000 2 tcp 111 portmapper
100000 4 udp 111 portmapper
100000 3 udp 111 portmapper
100000 2 udp 111 portmapper
100024 1 udp 42629 status
100024 1 tcp 56434 status
I have confirmed that rpc.statd is running, which I believe is the port mapper in newer distributions.
Any idea why I would be seeing this behavior? Is there a configuration option I'm missing? Any help would be greatly appreciated.
Thanks!
Dave
--
Dave Parker
Systems Administrator
Utica College
Integrated Information Technology Services
(315) 792-3229
Registered Linux User #408177