Red Hat Bugzilla – Bug 495890
autofs5: large number of DNS lookups for hostnames associated with multiple ip addresses.
Last modified: 2011-02-16 09:20:30 EST
autofs5 produce massive number of DNS queries when one nfs server name is associated with many IP adresses. For example when one host has 40 IP adresses associated mounting one autofs directory produce ~160 DNS queries.
steps to reproduce :
1) Configure roundrobin DNS so that the autofs client resolve host1.example.com as below .
host1.example.com has address 10.65.6.193
host1.example.com has address 10.65.7.143
host1.example.com has address 10.65.7.225
host1.example.com has address 10.65.6.128
2) nfs server exports /tmp *(ro)
on autofs5 client , configure the map such as ,
Capture the network packets using tcpdump.
On the client cd into /misc/test.
Check the number of DNS queries in the captured dump.
The table below lists the number of host lookups for varying number of ip addresses.
1 ip : 2 DNS lookup .
2 ip : 14 DNS lookups
3 ip : 20 DNS lookups
4 ip : 26 DNS lookups
The problem is also seen with autofs on RHEL 5.
Using the following patch fixes the problem.
(In reply to comment #0)
> The problem is also seen with autofs on RHEL 5.
> Using the following patch fixes the problem.
Right, this is one of the few (I think there are probably only two
things actually) that haven't been back ported to 5.0.1 in RHEL.
Sorry about this, I'll get onto it.
The test packages resolve the issue on RHEL 4.
The DNS lookups no longer increase with higher number of ip addresses associated with the hostname.
If the hostname is associated with
1 ip : 2 DNS lookup
3 ip : 2 DNS lookup
4 ip : 2 DNS lookup
5 ip : 2 DNS lookup
Committed in autofs5-5.0.1-0.rc2.108
Technical note added. If any revisions are required, please edit the "Technical Notes" field
accordingly. All revisions will be proofread by the Engineering Content Services team.
Previously, the number of DNS lookups corresponded to the number of IP addresses returned from a host name lookup for a single NFS server. NFS servers which resolved to multiple IP addresses increased the number of DNS lookups and caused excessive system load. This update removes redundant DNS lookups for NFS servers.
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.