Bug 9366 - Problem with /etc/rc.d/init.d/autofs
Summary: Problem with /etc/rc.d/init.d/autofs
Alias: None
Product: Red Hat Linux
Classification: Retired
Component: autofs   
(Show other bugs)
Version: 6.1
Hardware: All
OS: Linux
Target Milestone: ---
Assignee: Cristian Gafton
QA Contact:
Depends On:
TreeView+ depends on / blocked
Reported: 2000-02-11 21:16 UTC by Kambiz Aghaiepour
Modified: 2008-05-01 15:37 UTC (History)
0 users

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

Attachments (Terms of Use)

Description Kambiz Aghaiepour 2000-02-11 21:16:55 UTC
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).


Comment 1 Cristian Gafton 2000-02-11 22:20:59 UTC
Fixed in the devel tree

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