Bug 132105 - autofs (automount) failover does not work
autofs (automount) failover does not work
Status: CLOSED DUPLICATE of bug 129052
Product: Red Hat Enterprise Linux 3
Classification: Red Hat
Component: kernel (Show other bugs)
3.0
i686 Linux
medium Severity medium
: ---
: ---
Assigned To: Jeffrey Moyer
:
Depends On:
Blocks: RHEL3U8CanFix
  Show dependency treegraph
 
Reported: 2004-09-08 16:27 EDT by Paul Waterman
Modified: 2007-11-30 17:07 EST (History)
2 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2006-02-21 14:05:31 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 Paul Waterman 2004-09-08 16:27:30 EDT
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.5)
Gecko/20031007

Description of problem:
(Note that this problem apparently also exists in earlier versions of
autofs -- e.g. autofs-3.1.7-41 in RHEL 3.0 Update 2. We have only just
noticed it due to the new functionality in RHEL 3.0 Update 3 which
seeks out the best connection.)

If you have an automount map entry with multiple potential mount
sources and the automounter fails to mount one of those entries, it
will return a failure without attempting to mount the other entries.


Version-Release number of selected component (if applicable):
autofs-4.1.3-12

How reproducible:
Always

Steps to Reproduce:
1. Add "  localhost:/path/does/not/exist/&" as a secondary mount
source to the end of an automount map entry.
2. Restart autofs (e.g., `service autofs restart`)
3. Make sure that the automount point not currently mounted (e.g.,
`umount /mnt/auto/filesystem`).
3. Attempt to change directories to the automount point (e.g., `cd
/mnt/auto/filesystem`). autofs will determine that the localhost entry
is the closest on the network, attempt to mount it, fail, and not
attempt to mount the automount entry from other mount sources.

Actual Results:  # verify /apps/vendor/bin not mounted
% ls /apps/vendor
./  ../

# now automount /apps/vendor/bin and verify
% ls -ld /apps/vendor/bin
drwxr-xr-x    3 toolsadm daemon      12288 Sep  2 12:03 /apps/vendor/bin/

# edit /etc/auto.appsvendor
% vi /etc/auto.appsvendor

# Verify /apps/vendor/bin entry has been updated
% grep ^bin /etc/auto.appsvendor
bin ahfil03:/vol/vol0_03/software/vendor/&   
ahfil01:/vol/vol0_01/software/vendor/& localhost:/path/does/not/exist/&

# restart autofs
% service autofs restart
umount2: Device or resource busy                           [  OK  ]
umount: /apps/public: device is busy
umount2: Device or resource busy
umount: /home: device is busy

Starting automount:                                        [  OK  ]

# unmount /apps/vendor/bin
% umount /apps/vendor/bin

# verify /apps/vendor/bin not mounted
% ls /apps/vendor
./  ../

# try to automount /apps/vendor/bin and verify
% ls -ld /apps/vendor/bin
/bin/ls: /apps/vendor/bin: No such file or directory

# check out syslog entries
% tail -4 /var/log/messages
Sep  8 15:27:34 lnxtst04 automount[7097]: >> mount: special device
/path/does/not/exist/bin does not exist
Sep  8 15:27:34 lnxtst04 automount[7097]: failed to mount /apps/vendor/bin
Sep  8 15:27:34 lnxtst04 automount[7099]: >> mount: special device
/path/does/not/exist/bin does not exist
Sep  8 15:27:34 lnxtst04 automount[7099]: failed to mount /apps/vendor/bin



Expected Results:  The mount attempt should have failed over to one of
the good entries and we should have been able to access
/apps/vendor/bin normally.

Additional info:
Comment 2 Eric Paris 2004-09-17 17:12:51 EDT
Localhost always win the selection process using the get_best_mount in
autofs-4.1.3-12.  But the same behavior is found when you use a map like

mountkey    hostA:/exported/dir  hostB:/not/exported/dir

and hostB wins the selection.  It cannot mount the directory because
it is not exported and fails rather than trying hostA.
Comment 3 Jeffrey Moyer 2004-09-23 08:36:52 EDT

*** This bug has been marked as a duplicate of 129052 ***
Comment 4 Red Hat Bugzilla 2006-02-21 14:05:31 EST
Changed to 'CLOSED' state since 'RESOLVED' has been deprecated.
Comment 5 Ernie Petrides 2006-04-24 23:32:01 EDT
A fix for this problem has just been committed to the RHEL3 U8
patch pool this evening (in kernel version 2.4.21-40.10.EL).
Comment 6 Ernie Petrides 2006-04-28 17:47:28 EDT
Adding a couple dozen bugs to CanFix list so I can complete the stupid advisory.

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