Setting up NFS client

Michael Abbott michael at araneidae.co.uk
Sat Apr 18 17:53:36 UTC 2009


On Sat, 18 Apr 2009, Paul Smith wrote:
> On Sat, 2009-04-18 at 01:52 -0700, Chris Plasun wrote:
> > On the board I run "mount -t nfs 192.168.1.102:/home/na/nfstest 
> > /nfstest" but it eventually returns with the following error:
> > 
> > mount: RPC: Timed out
> > mount: nfsmount failed: Bad file descriptor
> > mount: Mounting 192.168.1.102:/home/na/nfstest on /nfstest failed:
> > Bad file descriptor
> Also, if you're seeing a delay on the client you probably don't have the
> portmapper running on the client.  If you don't want to add it there
> that's OK, but then you have to disable lock management; add the "-o
> nolock" option to your mount command on the client.

This issue, the portmapper, threw me for a long time.  Is it still not 
built into busybox?  I have to build this separately (and ended up having 
to make a couple of tiny patches for out of tree building to work).  I 
downloaded portmap-6.0 from http://neil.brown.name/portmap/ .

Presumably it would be worth pulling portmap.c into busybox?  I've often 
wondered why it's not there, don't know how much work would be needed to 
do that.


The patches I needed are below, and I use this command to cross compile it 
out of tree:

PORTMAP_PROGRAMS = portmap pmap_dump pmap_set
build:
        make -C $(O) -f $(srcdir)/Makefile $(PORTMAP_PROGRAMS) \
            srcdir=$(srcdir) VPATH=$(srcdir) \
            CC=$(COMPILER_PREFIX)-gcc CFLAGS='$(CFLAGS)' NO_TCP_WRAPPER=y


diff -ur portmap_6.0/pmap_check.c portmap_6.0.patched/pmap_check.c
--- portmap_6.0/pmap_check.c    2007-05-11 04:02:10.000000000 +0100
+++ portmap_6.0.patched/pmap_check.c    2008-10-26 17:47:05.000000000 
+0000
@@ -44,7 +44,9 @@
 #include <netinet/in.h>
 #include <rpc/rpcent.h>
 #endif
+#ifdef HOSTS_ACCESS
 #include <tcpd.h>
+#endif
 #include <arpa/inet.h>
 #include <grp.h>
 
--- portmap_6.0/Makefile        2007-05-11 04:02:10.000000000 +0100
+++ portmap/Makefile    2008-10-30 15:56:24.000000000 +0000
@@ -148,7 +148,7 @@
            core portmap.man
 
 -include .depend
-.depend: *.c
-       $(CC) -MM $(CFLAGS) *.c > .depend
+.depend: $(srcdir)/*.c
+       $(CC) -MM $(CFLAGS) $(srcdir)/*.c > .depend
 
 .PHONY: all clean install



More information about the busybox mailing list