Red Hat Bugzilla – Bug 187525
FC5 autofs package missing patches from RHEL
Last modified: 2007-11-30 17:11:29 EST
Description of problem:
It looks like the autofs package in FC diverged from the RHEL autofs package at
version 4.1.3-123. FC jumped to autofs-4.1.4-x while RHEL stayed on 4.1.3-x and
the FC autofs package is missing patches that are included in RHEL. The missing
patch that I noticed adds the $LDAPAUTOMASTER variable to the
/etc/sysconfig/autofs and /etc/rc.d/init.d/autofs files, but there are probably
Version-Release number of selected component (if applicable):
RHEL autofs-4.1.3-165 added support for $LDAPAUTOMASTER
FC autofs-4.1.4-16.2.2 is missing this variable
Steps to Reproduce:
1. Install FC5's autofs package
Check /etc/sysconfig/autofs and /etc/rc.d/init.d/autofs and note that
support for the $LDAPAUTOMASTER variable is missing
A blank variable $LDAPMASTER should be defined in /etc/sysconfig/autofs, and the
/etc/rc.d/init.d/autofs script should use this variable in the
Created attachment 127137 [details]
Patch to add support for $LDAPAUTOMASTER to FC5 autofs
Fedora is different from RHEL. If you want features in Fedora, it is best to
take the issue upstream, as the autofs packages in Fedora match upstream almost
(In reply to comment #1)
> Created an attachment (id=127137) 
> Patch to add support for $LDAPAUTOMASTER to FC5 autofs
It looks to me like $LDAPAUTOMASTER contains the master map name only.
Is that correct?
Exactly. See https://bugzilla.redhat.com/bugzilla/show_bug.cgi?id=161648
No, we're actually using a different LDAP schema so we're using all of the
options available to the autofs-ldap-auto-master command. Our
/etc/sysconfig/autofs file has this line:
LDAPAUTOMASTER="-m automountMap -e automount -n automountMapName -k automountKey
-v automountInformation auto_master_linux"
Some background: the original schema for putting NIS like data into LDAP stored
the automount key in the cn field. The cn field, however, is case insensitive
which is different from NIS, NIS+, local files, etc. I.E., with NIS, /mnt/foo
and /mnt/FOO would mount two different directories, but under LDAP they look the
same and which one gets mounted depends on which record the LDAP server decides
to return first.
Old schema (case insensitive):
map object class: nisMap
entry object class: nisObject
map name: nisMapName
entry key: cn
entry value: nisMapEntry
New schema (case sensitive):
map object class: automountMap
entry object class: automount
map name: automountMapName
entry key: automountKey
entry value: automountInformation
Finally, you'll notice that our auto.master map name is auto_master_linux. We
had to create two different auto.master maps -- one for Linux and one for
Solaris. The Linux automounter for some reason does not read the /etc/ldap.conf
file nor does it remember the values passed in to the autofs-ldap-auto-master
program, so we have to duplicate information in the auto.master map, i.e., the
automountInformation field has to have the name of the LDAP server and the map
name in it:
$ ldapsearch -x -LLL -b automountMapName=auto_master_linux,ou=foo \
dn: description=/home, automountMapName=auto_master_linux, ou=foo
(Host names and ou names changed to protect security.)
The auto_master tabled used by Solaris only needs the mount options, not the
LDAP server name and map location, because it gets that info from the LDAP
I believe I have a feature request in the RHEL IssueTracker system to enhance
the automounter with better LDAP support so I don't need two auto.master maps.
FYI, the new LDAP scheme with case sensitive fields was defined in RFC 2307bis.
Apparently this RFC never made it out ot the draft stage, but Sun has
implemented it with their Solaris automounter and, with a couple of patches that
I submitted for RHEL3, it too supports the new schema.
Clarification (or correction) on my earlier comment: the Solaris auto.master
automountInformation field only has the map name (e.g., auto_home) and the mount
options. The Linux automountInformation field requires
1. the fact that the information is stored in LDAP
2. the names of the LDAP servers
3. the map name
4. the base dn to the map is stored under
It seems kind of silly to have to tell the automounter that the map is stored in
LDAP when it just queried LDAP to get this information. And the automounter
should be able to get #2 and #4 from the /etc/ldap.conf file. Only #3 is really
should be able to be reduced to
but the /etc/rc.d/init.d/autofs script basically launches the automount daemon
with the automountInformation verbatim (it just changes the : after ldap to a
But I digress. The point of this BZ is just to add the $LDAPAUTOMASTER variable
to /etc/sysconfig/autofs and /etc/rc.d/init.d/autofs. We can work on making the
automounter more intelligent wrt LDAP in another BZ.
Much of this work is already going on upstream, and that is the right place for it.
An update has been applied for this bug Apr 11.
I believe it is fixed so if I don't hear otherwise I will
close this case tomorrow.
I finally got a chance to update autofs on my FC5 box and the latest version
does have the $LDAPAUTOMASTER variable in it now and it works great. Thanks!