Bug 9366 - Problem with /etc/rc.d/init.d/autofs
Problem with /etc/rc.d/init.d/autofs
Status: CLOSED RAWHIDE
Product: Red Hat Linux
Classification: Retired
Component: autofs (Show other bugs)
6.1
All Linux
medium Severity medium
: ---
: ---
Assigned To: Cristian Gafton
:
Depends On:
Blocks:
  Show dependency treegraph
 
Reported: 2000-02-11 16:16 EST by Kambiz Aghaiepour
Modified: 2008-05-01 11:37 EDT (History)
0 users

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2000-02-11 17:20:57 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Kambiz Aghaiepour 2000-02-11 16:16:55 EST
There is a bug in RedHat6.1 /etc/rc.d/init.d/autofs file.  On line 59,
inside of the getmounts() shell function, the line that reads:

       if echo $map | grep -- ':' ; then

should read

       if echo $map | grep -- ':' 1>/dev/null 2>&1 ; then

alternatively you could add the -q -s flags to the grep command.  The
reason that this is a bug is that if you look on line 129 (the start
section of the main case), you'll see that the getmounts() function is
intended to produce standard output that is piped to a sh for
interpretation.  The grep output clutters the output and causes errors
(although they are harmless errors and the desired outcome is still
acheived; nonetheless I call it a bug).  You won't run into this if you
do not have a map type prefix separated from the mapname with a ":"
character.  I discovered this because I have a local /etc/auto.master
file and one of the lines in that file read:

/home yp:auto.home

(You'd think this is a common scenario.  But I think if you rely on a
global auto.master map - i.e. you don't have a local /etc/auto.master -
you would not encounter this problem).

Kambiz
Comment 1 Cristian Gafton 2000-02-11 17:20:59 EST
Fixed in the devel tree

Note You need to log in before you can comment on or make changes to this bug.