How to disable reverse DNS in Sendmail
I would like to disable reverse DNS lookups in Sendmail.
We have an SMTP relay, running Sendmail, with an IP-based access.db. We have no requirement for reverse lookups and, in fact, they may be contributing to delays in response time. This triggers alerts in monitoring ... which make people unhappy.
I've had a search and have been unable to find anything to disable reverse DNS lookups for incoming connections. Obviously I can't just kill all DNS lookups as no mail will then be delivered.
- OS: centos 5
- sendmail.x86_64 8.13.8-8.1.el5_7
- sendmail-cf.x86_64 8.13.8-8.1.el5_7
Thanks in advance!
Check in your sendmail.mc
whether FEATURE(require_rdns)
is enabled. If not check also whether your sendmail binary is compiled with tcp_wrappers support, and if yes, check the policies (specific for sendmail, or default if absent for sendmail) in /etc/hosts.allow
and /etc/hosts.deny
UPDATE:
There are a couple more files to check. First check /etc/nsswitch.conf
(or /etc/mail/service.switch
) if it exists. Normal entries for DNS resolving are:
hosts: files bind
Next check the entries of /etc/resolv.conf
. Are the nameservers listed there responding? Maybe the first one is not reachable and this is the cause of the delays.