[vox-tech] NFS Mounting Error

Peter Jay Salzman p at dirac.org
Sat Dec 4 14:57:00 PST 2004


On Sat 04 Dec 04,  2:17 PM, Chris Jenks <jenks at resonance.org> said:
> 
> On Sat, 4 Dec 2004, Peter Jay Salzman wrote:
> 
> >On Sat 04 Dec 04, 10:44 AM, Chris Jenks <jenks at resonance.org> said:
> >>
> >>  Hello,
> >>
> >>  I am trying to mount a NFS volume where both machines are on the same
> >>home network, but I get the following errors. From the client:
> >>
> >>[root at pinky mnt]# mount -t nfs 192.168.0.14:/tmp /mnt/tmp
> >>mount: 192.168.0.14:/tmp failed, reason given by server: Permission denied
> >>
> >>On the server:
> >>
> >>cruncher:/# tail /var/log/syslog
> >>[...]
> >>Dec  4 10:30:31 cruncher rpc.mountd: authenticated mount request from
> >>192.168.0.2:773 for /tmp (/tmp)
> >>Dec  4 10:30:31 cruncher rpc.mountd: getfh failed: No such device
> [...]
> >
> >Chris, if massive log file reading and Googling didn't turn up anything
> >useful, what I would try as a second stab would be to run nfsd by hand with
> >strace:
> >
> ># strace -o /root/nfsd.log rpc.nfsd
> >
> >and look for something that looks like an error near the bottom of the 
> >file.
> >It may not tell you anything useful, but often time strace will tell you 
> >the
> >real, "low level" reason why something failed, which can sometimes be very
> >useful.
> >
> >Pete
> 
>   Dear Pete,
> 
>   Thanks for the new tool. I tried it out on rpc.nfsd and it gave:
> 
> [...]
> close(5)                                = -1 EBADF (Bad file descriptor)
> close(4)                                = -1 EBADF (Bad file descriptor)
> close(3)                                = 0
> open("/proc/fs/nfsd/threads", O_WRONLY) = -1 ENOENT (No such file or 
> directory)
> open("/proc/fs/nfs/threads", O_WRONLY)  = -1 ENOENT (No such file or 
> directory)
> nfsservctl(0, 0xbffff4c0, 0)            = -1 ENODEV (No such device)
> time([1102190507])                      = 1102190507
> open("/etc/localtime", O_RDONLY)        = 3
> [...]
> 
> near the end. Also, I ran exportfs -ra in the same way, and got:
> 
> [...]
> open("/var/lib/nfs/xtab", O_RDONLY)     = 5
> fstat64(5, {st_mode=S_IFREG|0644, st_size=0, ...}) = 0
> mmap2(NULL, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 
> 0x40018000
> read(5, "", 4096)                       = 0
> read(5, "", 4096)                       = 0
> close(5)                                = 0
> munmap(0x40018000, 4096)                = 0
> close(3)                                = 0
> nfsservctl(0x1, 0xbfffe7f0, 0)          = -1 ENODEV (No such device)
> write(2, "192.168.0.2:/tmp: No such device"..., 33) = 33
> open("/var/lib/nfs/etab", O_RDWR|O_CREAT, 010000510074) = 3
> rt_sigaction(SIGALRM, {0x804dec0, [], 0}, {SIG_DFL}, 8) = 0
> [...]
> 
> A google search revealed that nfsservctl is a "syscall interface to kernel 
> nfs daemon." Command number 0 means "This is a server process," while 
> command number 0x1 means "Add an NFS client." I suspect that my kernel 
> configuration is at fault. I'll look at it.
> 
>   Yours,
> 
>     Chris

Hi Chris,

Yeah, I guess that's what my conclusion would be, too.  Good luck!  I think
this will pan out, but if it doesn't, let me know and I'll scratch my head
some more.

BTW, you might be interested in another, similar tool.  If you ever feel that
you "almost" have enough information from strace, but need higher level
information, ltrace is to library functions as strace is to system calls.

ltrace used to be pretty spotty, but in the past 2 years it has gotten quite
complete.

Together, strace and ltrace form a very powerful combination.  If you want to
learn more, I've found that the -s, -o, -f -ff options are what I use most.

I just recently learned about the -p option which wins the "coolness award of
the month".  Post back if you have success.

Pete


-- 
The mathematics of physics has become ever more abstract, rather than more
complicated.  The mind of God appears to be abstract but not complicated.
He also appears to like group theory.  --  Tony Zee's "Fearful Symmetry"

PGP Fingerprint: B9F1 6CF3 47C4 7CD8 D33E  70A9 A3B9 1945 67EA 951D


More information about the vox-tech mailing list