Autofs problem

Login or Register to Reply

 
Thread Tools Search this Thread
# 1  
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/&

Login or Register to Reply

|
Thread Tools Search this Thread
Search this Thread:
Advanced Search

More UNIX and Linux Forum Topics You Might Find Helpful
NFS, AD, AutoFS
cjhilinski
Here's my challenge. I have a RedHat7 machine running a statistical software package. It needs to NFS-mount directories from a Windows 2008R2 machine. The RH7 machine uses MSAD (Microsoft Active Directory) to handle authentication of people connecting via SSH. AD is on a separate 2008R2 machine....... Red Hat
5
Red Hat
Autofs issue
maverick_here
Hi I'm trying to use autofs to mount a directory structure. I have a directory with sub directories in it and all of them mounted on their respective filesystems /dbname /dev/mapper/vg_dbname-Home /dbname/oracle00 /dev/mapper/vg_dbname-Data00...... Red Hat
3
Red Hat
Autofs
dinu
what are all the advantages of direct map and indirect map in 'AUTOFS' and which one is better for our usage... Solaris
2
Solaris
autofs
sijocg
hi tell me difference between direct automount and indirect automount. thanks you... Solaris
1
Solaris
Autofs
b_manu78
Hi Guys, Autofs works fine on AIX 5.2, but the same thing is not getting mounted automatically on AIX 5.3.. Is there ant difference for autofs confiiguration between 5.2 and 5.3 Thanks & Regards Manu... AIX
0
AIX
Linux and UNIX

Linux is a family of open source Unix-like operating systems based on the Linux kernel. The Linux kernel is an operating system kernel first released by Linus Torvalds on 17 September 1991. Linux distributions include the Linux kernel, system software and libraries. Popular free open source Linux distributions include Debian, Fedora, and Ubuntu. Commercial Linux distributions include Red Hat Enterprise Linux and SUSE Linux Enterprise Server. Linux may be freely modified and redistributed. Anyone on the planet may create a Linux distribution for any purpose.
Unix (trademarked as the UNIX certification mark) is a very mature family of multitasking, multiuser computer operating systems that evolved from the original AT&T Unix. Unix development starting in the 1970s by legendary Bell Labs programmers Ken Thompson, Dennis Ritchie, and others. Unix was first targeted for the Bell System and AT&T licensed Unix to outside parties. In the 1970s time period, this lead to a variety of for-profit as well as not-for-profit Unix variants.
In the early days, this included the University of California, Berkeley (BSD), Microsoft (Xenix), IBM (AIX), and Sun Microsystems (Solaris). In the early 1990s, AT&T sold their Unix rights to Novell. In 1995 Novell sold their Unix business to the Santa Cruz Operation (SCO). The UNIX trademark was passed to The Open Group, a "neutral" industry consortium. The Open Group promoted the use of the UNIX trademark for certified operating systems that comply with the Single UNIX Specification (SUS). In 2014 Apple's macOS became the Unix version with the largest global install base and macOS remains the largest Unix-user base today.
Please enjoy and help our forum community by "showing your work" and posting your code, even when your code is not working as expected. To help others help you, please wrap your code blocks, sample input, sample output, error messages, and other data in CODE tags and wrap your short commands and short data objects in ICODE tags. We were all beginners in the beginning. If you have any questions about how to register or how to post, please contact us in Live Chat. Thank you and enjoy this "forever free" technical support community for UNIX, Linux and computer information technology in general.