1832871 Members
2746 Online
110048 Solutions
New Discussion

Re: the sendmail problem

 
peterchu
Super Advisor

the sendmail problem

I found there are some mails store in the mailq ( /var/spool/mqueue ) , I tried sendmail -q and restart the sendmail service , but still can't pull all mails out , and the new mail still append to the mailq , could suggest how can I fix it ? thx
11 REPLIES 11
Muthukumar_5
Honored Contributor

Re: the sendmail problem

What you are getting by executing mailq or sendmail -bp.

hth.

Easy to suggest when don't know about the problem!
Doug O'Leary
Honored Contributor

Re: the sendmail problem

Hey;

There's a couple of things you can do all of which relate to finding out why the mail isn't flowing. Probably the quickest and easiest is to find the ID number of one of the emails. If you do a mailq, the ID number will be the long string of digits and letters on the left side. Once you have that, you can execute:

sendmail -v -qI${ID}

That will execute sendmail in verbose mode to process the queue for that ${ID}. Note there is no space beween -qI${ID}. Watch the sendmail transaction and then troubleshoot whatever error results.

HTH;

Doug

------
Senior UNIX Admin
O'Leary Computers Inc
linkedin: http://www.linkedin.com/dkoleary
Resume: http://www.olearycomputers.com/resume.html
Steven E. Protter
Exalted Contributor

Re: the sendmail problem

Try sendmail -v -q

That will give you error messages.

Diagnostic:

dig hp.com

dig

DNS problems often keep mail from getting off the box and getting in the box.

If it is DNS make sure the name servers in /etc/resolv.conf are pingable, valid name servers. Make sure those boxes are providing good connections to the public Internet.

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
RAC_1
Honored Contributor

Re: the sendmail problem

What does mail.log file say??
What does mailq -v say??

Anil
There is no substitute to HARDWORK
peterchu
Super Advisor

Re: the sendmail problem

thx replies,

It seems find the problem as below , but I am not sure why the problem happen suddenly ,
could suggest how to fix it ? thx

Running /var/spool/mqueue/j4QBHMp13821 (sequence 6 of 7)
abs.com: Name server timeout
... Transient parse error -- message queued for future
delivery
gpe-hkg.com: Name server timeout
Muthukumar_5
Honored Contributor

Re: the sendmail problem

There is a problem in nameserver to reach it. Check the nameserver configuration in /etc/resolv.conf.

Check connectivity with ping / nslookup / nsquery / dig

hth.
Easy to suggest when don't know about the problem!
Doug O'Leary
Honored Contributor

Re: the sendmail problem

"Name server timeout" means the name lookup for that host died.

Troubleshoot your DNS by:

1. pinging each host listed in /etc/resolv.conf. If the systems are down, find out why and turn them back on.

2. If the systems are up, execute nslookup. Try searching for known local hosts - the DNS server, your mail server, your database servers, etc. If all that comes back correctly, then your DNS is working and the problem is outside of your control. If it doesn't come back correctly, troubleshoot the DNS issue.

Once the DNs is fully functional, your mail will start flowing again.

HTH;

Doug

------
Senior UNIX Admin
O'Leary Computers Inc
linkedin: http://www.linkedin.com/dkoleary
Resume: http://www.olearycomputers.com/resume.html
Rick Garland
Honored Contributor

Re: the sendmail problem

Appears the name server has gone south.
Is DNS as a whole having trouble?

Cem Tugrul
Esteemed Contributor
Steven E. Protter
Exalted Contributor

Re: the sendmail problem

As I noted, this is a name resolution problem.

You need to take the following steps:

1) Make sure your can communicate with the DNS name server.
2) Make sure the dns name server is communicating correcting with the Iternet.
3) Make sure the name that is not resolving is valid.

If you can not improve the DNS name situation, you may need to forward mail to a server that gets better name resolution results.

The fast, easy way is to use the DS directive in sendmail.cf

edit /etc/mail/sendmail.cf

DS
mail.relayserver

or

DS
192.168.0.10

That IP address is a theoretical mail relay server. I use the IP address to avoid DNS problems with mail relay.

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

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
peterchu
Super Advisor

Re: the sendmail problem

thx all