Unix/Linux Go Back    


Fedora is an operating system centered on the Linux open source kernel and is developed by the community-supported Fedora Project. Fedora is sponsored by Red Hat. Fedora contains software distributed under a free and open-source license. Fedora focuses on innovation, integrating and adopting new technologies and working closely with various Linux communities. The default desktop in Fedora is the GNOME desktop environment and the default user interface is the GNOME Shell. Other desktop environments include KDE Plasma, Xfce, LXDE, MATE and Cinnamon. Security is an important aspect of Fedora with one specific security feature, Security-Enhanced Linux, implementing a variety of software security policies, including mandatory access controls.

Autofs problem

Fedora


Closed    
 
Thread Tools Search this Thread Display Modes
    #1  
Old Unix and Linux 10-19-2016
HuntWilliamR HuntWilliamR is offline
Registered User
 
Join Date: Oct 2016
Last Activity: 20 October 2016, 12:20 PM EDT
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Autofs problem

Hi all,

I'm having trouble getting autofs working on a new install of Scientific Linux 7.2.

I have the files /etc/auto.master, /etc/auto/homes and /etc/auto.misc and /auto.direct setup, and they are copies of files on a working SL 6 machine. I can include the contents of the files at the end of this post.

When I log on as root on the just rebooted machine, directory listings don't show the directories I expected to see automounted.

If I do :


Code:
systemctl stop autofs

and then from the command line run


Code:
automount&

then I do see the directories mounted correctly.

If I then kill the automount process and run


Code:
systemctl start autofs

I can no longer see the directories, and the file /var/log/messages contains the lines below:


Code:
Oct 18 09:17:37 danube systemd: Starting Automounts filesystems on demand...
Oct 18 09:17:37 danube automount[10906]: Starting automounter version 5.0.7-54.el7, master map auto.master[quote]
Oct 18 09:17:37 danube automount[10906]: using kernel protocol version 5.02
Oct 18 09:17:37 danube automount[10906]: lookup_nss_read_master: reading master files auto.master
Oct 18 09:17:37 danube automount[10906]: lookup(file): file map /etc/auto.master missing or not readable
Oct 18 09:17:37 danube automount[10906]: lookup_nss_read_master: auto.master not found, replacing '.' with '_'
Oct 18 09:17:37 danube automount[10906]: lookup(file): file map /etc/auto_master missing or not readable
Oct 18 09:17:37 danube automount[10906]: lookup_nss_read_master: reading master ldap auto.master
Oct 18 09:17:37 danube automount[10906]: parse_server_string: lookup(ldap): Attempting to parse LDAP information from string "auto.master".
Oct 18 09:17:37 danube automount[10906]: parse_server_string: lookup(ldap): mapname auto.master
Oct 18 09:17:37 danube automount[10906]: parse_ldap_config: lookup(ldap): ldap authentication configured with the following options:
Oct 18 09:17:37 danube automount[10906]: parse_ldap_config: lookup(ldap): use_tls: 0, tls_required: 0, auth_required: 1, sasl_mech: (null)
Oct 18 09:17:37 danube automount[10906]: parse_ldap_config: lookup(ldap): user: (null), secret: unspecified, client principal: (null) credential cache: (null)
Oct 18 09:17:37 danube automount[10906]: parse_init: parse(sun): init gathered global options: (null)
Oct 18 09:17:37 danube automount[10906]: spawn_mount: mtab link detected, passing -n to mount
Oct 18 09:17:37 danube automount[10906]: spawn_umount: mtab link detected, passing -n to mount
Oct 18 09:17:37 danube automount[10906]: do_bind: lookup(ldap): auth_required: 1, sasl_mech (null)
Oct 18 09:17:37 danube automount[10906]: do_bind: lookup(ldap): ldap simple bind returned 0
Oct 18 09:17:37 danube automount[10906]: get_query_dn: lookup(ldap): query failed for (&(objectclass=nisMap)(nisMapName=auto.master)): No such object
Oct 18 09:17:37 danube automount[10906]: get_query_dn: lookup(ldap): query failed for (&(objectclass=automountMap)(ou=auto.master)): No such object
Oct 18 09:17:37 danube automount[10906]: get_query_dn: lookup(ldap): query failed for (&(objectclass=automountMap)(automountMapName=auto.master)): No such object
Oct 18 09:17:37 danube automount[10906]: lookup(ldap): failed to find valid query dn
Oct 18 09:17:37 danube automount[10906]: lookup_nss_read_master: auto.master not found, replacing '.' with '_'
Oct 18 09:17:37 danube automount[10906]: parse_server_string: lookup(ldap): Attempting to parse LDAP information from string "auto_master".
Oct 18 09:17:37 danube automount[10906]: parse_server_string: lookup(ldap): mapname auto_master
Oct 18 09:17:37 danube automount[10906]: parse_ldap_config: lookup(ldap): ldap authentication configured with the following options:
Oct 18 09:17:37 danube automount[10906]: parse_ldap_config: lookup(ldap): use_tls: 0, tls_required: 0, auth_required: 1, sasl_mech: (null)
Oct 18 09:17:37 danube automount[10906]: parse_ldap_config: lookup(ldap): user: (null), secret: unspecified, client principal: (null) credential cache: (null)
Oct 18 09:17:37 danube automount[10906]: parse_init: parse(sun): init gathered global options: (null)

I think the relevant line here is

Oct 18 09:17:37 danube automount[10906]: lookup(file): file map /etc/auto.master missing or not readable

When automount is run from the command line, the /var/log/messages file does not contain this line :

Code:
Oct 18 09:58:53 danube automount[12826]: Starting automounter version 5.0.7-54.el7, master map auto.master
Oct 18 09:58:53 danube automount[12826]: using kernel protocol version 5.02
Oct 18 09:58:53 danube automount[12826]: lookup_nss_read_master: reading master files auto.master
Oct 18 09:58:53 danube automount[12826]: parse_init: parse(sun): init gathered global options: (null)
Oct 18 09:58:53 danube automount[12826]: spawn_mount: mtab link detected, passing -n to mount
Oct 18 09:58:53 danube automount[12826]: spawn_umount: mtab link detected, passing -n to mount
Oct 18 09:58:53 danube automount[12826]: lookup_read_master: lookup(file): read entry /Users
Oct 18 09:58:53 danube automount[12826]: lookup_read_master: lookup(file): read entry /-
Oct 18 09:58:53 danube automount[12826]: lookup_read_master: lookup(file): read entry +auto.master
Oct 18 09:58:53 danube automount[12826]: lookup_nss_read_master: reading master files auto.master
Oct 18 09:58:53 danube automount[12826]: parse_init: parse(sun): init gathered global options: (null)
Oct 18 09:58:53 danube automount[12826]: lookup_nss_read_master: reading master ldap auto.master
Oct 18 09:58:53 danube automount[12826]: parse_server_string: lookup(ldap): Attempting to parse LDAP information from string "auto.master".
Oct 18 09:58:53 danube automount[12826]: parse_server_string: lookup(ldap): mapname auto.master
Oct 18 09:58:53 danube automount[12826]: parse_ldap_config: lookup(ldap): ldap authentication configured with the following options:
Oct 18 09:58:53 danube automount[12826]: parse_ldap_config: lookup(ldap): use_tls: 0, tls_required: 0, auth_required: 1, sasl_mech: (null)
Oct 18 09:58:53 danube automount[12826]: parse_ldap_config: lookup(ldap): user: (null), secret: unspecified, client principal: (null) credential cache: (null)
Oct 18 09:58:53 danube automount[12826]: parse_init: parse(sun): init gathered global options: (null)
Oct 18 09:58:53 danube automount[12826]: do_bind: lookup(ldap): auth_required: 1, sasl_mech (null)
Oct 18 09:58:53 danube automount[12826]: do_bind: lookup(ldap): ldap simple bind returned 0
Oct 18 09:58:53 danube automount[12826]: get_query_dn: lookup(ldap): query failed for (&(objectclass=nisMap)(nisMapName=auto.master)): No such object
Oct 18 09:58:53 danube automount[12826]: get_query_dn: lookup(ldap): query failed for (&(objectclass=automountMap)(ou=auto.master)): No such object
Oct 18 09:58:53 danube automount[12826]: get_query_dn: lookup(ldap): query failed for (&(objectclass=automountMap)(automountMapName=auto.master)): No such object
Oct 18 09:58:53 danube automount[12826]: lookup(ldap): failed to find valid query dn
Oct 18 09:58:53 danube automount[12826]: lookup(file): failed to read included master map auto.master
Oct 18 09:58:53 danube automount[12826]: master_do_mount: mounting /Users
Oct 18 09:58:53 danube automount[12826]: automount_path_to_fifo: fifo name /run/autofs.fifo-Users
Oct 18 09:58:53 danube automount[12826]: lookup_nss_read_map: reading map file /etc/auto.homes

Any idea why when run as a service, automount would not be able to read the auto.master file, but it can when run from command line ? I realize the second log excerpt also contains some error messages, but they don't seem to be affecting the functionality - the remote directories do get mounted correctly.

Not sure if it's relevant, but the permissions on the /etc/auto.master file are currently set to 600 and it is owned by root.

Thanks very much !

Bill


Contents of /etc/auto.master :

Code:
#
# Sample auto.master file
# This is a 'master' automounter map and it has the following format:
# mount-point [map-type[,format]:]map [options]
# For details of the format look at auto.master(5).
#
#/misc  /etc/auto.misc
#
# NOTE: mounts done from a hosts map will be mounted with the
#       "nosuid" and "nodev" options unless the "suid" and "dev"
#       options are explicitly given.
#
#Maps for home folders
/Users  /etc/auto.homes
# Direct maps
/-      /etc/auto.direct

              
#/net   -hosts
#
# Include central master map if it can be found using
# nsswitch sources.
#
# Note that if there are entries for /net or /misc (as
# above) in the included master map any keys that are the
# same will not be seen as the first read key seen takes
# precedence.
#
+auto.master

Contents of /etc/auto.homes:


Code:
*    -fstype=nfs     gambo:/Data/Users/&

Sponsored Links
Closed

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Linux More UNIX and Linux Forum Topics You Might Find Helpful
Thread Thread Starter Forum Replies Last Post
NFS, AD, AutoFS cjhilinski Red Hat 5 06-05-2015 12:58 AM
Autofs dinu Solaris 2 04-15-2011 11:23 AM
autofs sijocg Solaris 1 02-11-2010 07:32 AM
Autofs b_manu78 AIX 0 02-10-2006 03:55 AM
RedHat autofs larryase UNIX for Dummies Questions & Answers 0 12-02-2004 06:59 PM



All times are GMT -4. The time now is 07:02 PM.