[blfs-support] Autofs problem on LFS7.2

Cliff McDiarmid cliffhanger at gardener.com
Wed Mar 27 11:29:10 PDT 2013


 > Date: Mon, 25 Mar 2013 16:17:33 +0000
> > From: lfs65 at cruziero.com (akhiezer)
> > To: BLFS Support List <blfs-support at linuxfromscratch.org>
> > Subject: Re: [blfs-support] Autofs problem on LFS7.2
> >
> .
> .
> > > > > 
> > > > > Can you stop/kill the currently-running automount process, and verify via ps or 
> > > > > similar that there's no automount processes running, and then run automount 
> > > > > manually and in debug mode at console via:
> > > > > 
> > > > > $ automount -v -f -d 
> > > >
> > > > $ Without '-d'
> > > > Starting automounter version 5.0.7, master map auto.master
> > > > using kernel protocol version 5.02
> > > > open_mount:244: parse(sun): cannot open mount module nfs 
> > > > (//lib/autofs/mount_nfs.so: undefined symbol: auth_put)
> > > > lookup(file): failed to open parse context
> > > > lookup(file): file map /etc/auto_master missing or not readable
> > > > no mounts in table
> > > >
> > > > Hangs at this point
> > > > $
> > > >
> > > > $ With '-d'
> > > > Starting automounter version 5.0.7, master map auto.master
> > > > using kernel protocol version 5.02
> > > > lookup_nss_read_master: reading master files auto.master
> > > > parse_init: parse(sun): init gathered global options: (null)
> > > > open_mount:244: parse(sun): cannot open mount module nfs 
> > > > (//lib/autofs/mount_nfs.so: undefined symbol: auth_put)
> > > > lookup(file): failed to open parse context
> > > > lookup_nss_read_master: auto.master not found, replacing '.' with '_'
> > > > lookup(file): file map /etc/auto_master missing or not readable
> > > > no mounts in table
> > > >
> > > > Hangs at this point
> > > > $
> > >
> 
> 
> A web search on the 'mount_nfs.so: undefined symbol: auth_put' turned up the 
> bug-report and fix:
> 
> https://bugs.mageia.org/show_bug.cgi?id=6903
> 
> The fix is basically to revert a change that was made going from version 5.0.6 
> (which is what is running here) and 5.0.7 (which is what you've got). The above 
> url links to the following page that shows the change:
> 
> ftp://ftp.kernel.org/pub/linux/daemons/autofs/v5/patches-5.0.7/autofs-5.0.6-fix-libtirpc-name-clash.patch
> 
> So to revert the change, one would edit the file 'lib/rpc_subs.c' in the source 
> distrib, and comment-out the code:
> ---
> #ifdef WITH_LIBTIRPC
> #undef auth_destroy
> #define auth_destroy(auth) \
>  do { \
>  int refs; \
>  if ((refs = auth_put((auth))) == 0) \
>  ((*((auth)->ah_ops->ah_destroy))(auth));\
>  } while (0)
> #endif
> ---
> thus (am not assuming you don't already know some/all of this kind of stuff):
> ===
> /*
> #ifdef WITH_LIBTIRPC
> #undef auth_destroy
> #define auth_destroy(auth) \
>  do { \
>  int refs; \
>  if ((refs = auth_put((auth))) == 0) \
>  ((*((auth)->ah_ops->ah_destroy))(auth));\
>  } while (0)
> #endif
> */
> ===
> ; and do leave single blank line above and below (not required from a technical 
> point of view).
> Then recompile autofs like you did before, and see how it goes. If it all goes 
> well then one would need to determine if there are any unwanted side-effects 
> from commenting out that code.

Right.  I've recompiled autofs(had to include MIT Kerberos)and the results were intially promising.

'automount -v -f -d /etc/auto.master' gave:

Starting automounter version 5.0.7, master map /etc/auto.master
using kernel protocol version 5.02
lookup_nss_read_master: reading master file /etc/auto.master
parse_init: parse(sun): init gathered global options: (null)
lookup_read_master: lookup(file): read entry /testautomount
master_do_mount: mounting /testautomount
automount_path_to_fifo: fifo name /run/autofs.fifo-testautomount
lookup_nss_read_map: reading map file /etc/auto.testautomount
parse_init: parse(sun): init gathered global options: (null)
mounted indirect on /testautomount with timeout 300, freq 75 seconds
st_ready: st_ready(): state = 0 path /testautomount

Then after approx. 1min

st_expire: state 1 path /testautomount
expire_proc: exp_proc = 3060792128 path /testautomount
expire_cleanup: got thid 3060792128 path /testautomount stat 0
expire_cleanup: sigchld: exp 3060792128 finished, switching from 2 to 1
st_ready: st_ready(): state = 2 path /testautomount

However, when inserting the usbstick and try and list any contents, it is only on

/testautomount, i.e. the dir. sandisk is not available and can not be created:

 mkdir: cannot create directory '/testautomount/sandisk': Permission 
denied.

I only get the following again
$
total 4
drwxr-xr-x 2 root root 4096 Mar 23 09:38 ./
drwxr-xr-x 2 root root 4096 Mar 23 09:38 ../

regards

MAC 




More information about the blfs-support mailing list