Bug 132105 - autofs (automount) failover does not work
Summary: autofs (automount) failover does not work
Keywords:
Status: CLOSED DUPLICATE of bug 129052
Alias: None
Product: Red Hat Enterprise Linux 3
Classification: Red Hat
Component: kernel
Version: 3.0
Hardware: i686
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Jeff Moyer
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks: RHEL3U8CanFix
TreeView+ depends on / blocked
 
Reported: 2004-09-08 20:27 UTC by Paul Waterman
Modified: 2007-11-30 22:07 UTC (History)
2 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2006-02-21 19:05:31 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2006:0437 0 normal SHIPPED_LIVE Important: Updated kernel packages for Red Hat Enterprise Linux 3 Update 8 2006-07-20 13:11:00 UTC

Description Paul Waterman 2004-09-08 20:27:30 UTC
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 21:12:51 UTC
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 Jeff Moyer 2004-09-23 12:36:52 UTC

*** This bug has been marked as a duplicate of 129052 ***

Comment 4 Red Hat Bugzilla 2006-02-21 19:05:31 UTC
Changed to 'CLOSED' state since 'RESOLVED' has been deprecated.

Comment 5 Ernie Petrides 2006-04-25 03:32:01 UTC
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 21:47:28 UTC
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.