Instead of using the server with the best RPC ping time, automount always selects the server randomly. The -r option for autofs is not set. /var/log/messages with autofs debug enabled in /etc/sysconfig/autofs: Dec 10 17:04:12 xxxxxx automount[25958]: get_nfs_info: called for host server4 proto udp version 0x30 Dec 10 17:04:12 xxxxxx automount[25958]: get_nfs_info: nfs v3 random selection time: 0.949207 Dec 10 17:04:12 xxxxxx automount[25958]: get_nfs_info: nfs v2 random selection time: 0.505903 Dec 10 17:04:12 xxxxxx automount[25958]: get_nfs_info: host server4 cost 727555 weight 0 master_parser.y: 816 entry->ap->flags |= MOUNT_FLAG_RANDOM_SELECT; This is apparently set unconditionally so it looks like there is no way to unset this flag.
Patch proposed by Ian. autofs-5.0.5 - fix random selection option From: Ian Kent <raven themaw net> When parsing the master map we fail to check if the random selection option has been seen and set the random selection option unconditionally. --- lib/master_parse.y | 3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) diff --git a/lib/master_parse.y b/lib/master_parse.y index 8ca7df7..2db483b 100644 --- a/lib/master_parse.y +++ b/lib/master_parse.y @@ -806,7 +806,8 @@ int master_parse_entry(const char *buffer, unsigned int default_timeout, unsigne ops->timeout(ap->logopt, ap->ioctlfd, &tout); } } - entry->ap->flags |= MOUNT_FLAG_RANDOM_SELECT; + if (random_select) + entry->ap->flags |= MOUNT_FLAG_RANDOM_SELECT; if (negative_timeout) entry->ap->negative_timeout = negative_timeout;
Created attachment 379016 [details] Patch - fix random selection option Proposed patch without email wrap.
Created attachment 379149 [details] Patch - fix random selection option (corrected) Oops!
~~ Attention Customers and Partners - RHEL 5.5 Beta is now available on RHN ~~ RHEL 5.5 Beta has been released! There should be a fix present in this release that addresses your request. Please test and report back results here, by March 3rd 2010 (2010-03-03) or sooner. Upon successful verification of this request, post your results and update the Verified field in Bugzilla with the appropriate value. If you encounter any issues while testing, please describe them and set this bug into NEED_INFO. If you encounter new defects or have additional patch(es) to request for inclusion, please clone this bug per each request and escalate through your support representative.
An advisory has been issued which should help the problem described in this bug report. This report is therefore being closed with a resolution of ERRATA. For more information on therefore solution and/or where to find the updated files, please follow the link below. You may reopen this bug report if the solution does not work for you. http://rhn.redhat.com/errata/RHBA-2010-0265.html