1846431 Members
2645 Online
110256 Solutions
New Discussion

Re: sendmail problem

 
SOLVED
Go to solution
hangyu
Regular Advisor

sendmail problem

I want to send the mail out via sendmail daemon , but however, the mail is stored at mqueue and not send out ,I check that the file in the mqueue , the error is as below , it seems can't file the server asl.srv , but I try to ping it , it is Ok , can advise what is wrong in the sendmail config ? thx

MDeferred: Name server: asl.srv : host name lookup failure
3 REPLIES 3
Bill Hassell
Honored Contributor
Solution

Re: sendmail problem

In order for sendmail to find a particular hostname, it looks up the mail delivery (MX) record so start with: nslookup -type=mx asl.srv

If this fails, your DNS server is not providing MX records and you'll have to put this server (perhaps others) into /etc/hosts. Then change /etc/nsswitch.conf hosts entry to look like this:

hosts: files [NOTFOUND=continue UNAVAIL=continue] dns

Also edit two files in /etc/mail: sendmail.cw and services.switch. In sendmail.cw, the end of the file should look like this:

localhost
mycomptername

and service.switch:

hosts files dns
aliases files

Then restart sendmail:

/sbin/init.d/sendmail stop
/sbin/init.d/sendmail start


Bill Hassell, sysadmin
Steven E. Protter
Exalted Contributor

Re: sendmail problem

Shalom,

Diags:

sendmail -v -d8.99 -d38.99 someaddress@some.net

type some text

.


full diags from this.

also:

sendmail -v -q

This will run the queue.

Without host name resolution the only way to get mail delivered will be to use the DS directive and relay the mail via another server.

SEP
Steven E Protter
Owner of ISN Corporation
http://isnamerica.com
http://hpuxconsulting.com
Sponsor: http://hpux.ws
Twitter: http://twitter.com/hpuxlinux
Founder http://newdatacloud.com
Calandrello
Trusted Contributor

Re: sendmail problem