LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Server (https://www.linuxquestions.org/questions/linux-server-73/)
-   -   sendmail mqueue inexplicably growing (https://www.linuxquestions.org/questions/linux-server-73/sendmail-mqueue-inexplicably-growing-867028/)

blainemiller 03-07-2011 01:25 PM

sendmail mqueue inexplicably growing
 
I have a server (RHEL 4.7) with an mqueue that keeps growing over a two or three day interval. Then I have to manually flush the queue by removing all the mail in the spool directory as the sendmail flush command doesn't work.

I've looked at the mail queue manually with a sendmail -bp command and it seems to show an occaisional mail item in the queue. On the other hand, there seems to be a lot more non-legitimate emails in the queue spool.

First, how do I find out the source of the email in the main queue? Next, how do I stop it from building the queue? Next, is there anyway to automatically flush the queue once it builds if I need to?

Sorry, but I'm a serious newbie when it comes to email and specifically sendmail server.

I've googled for an answer and only find links to the Sendmail server site and its' (to me) cryptic command structure.

Thanks!

Blaine

centosboy 03-08-2011 03:05 AM

Quote:

Originally Posted by blainemiller (Post 4281810)
I have a server (RHEL 4.7) with an mqueue that keeps growing over a two or three day interval. Then I have to manually flush the queue by removing all the mail in the spool directory as the sendmail flush command doesn't work.

I've looked at the mail queue manually with a sendmail -bp command and it seems to show an occaisional mail item in the queue. On the other hand, there seems to be a lot more non-legitimate emails in the queue spool.

First, how do I find out the source of the email in the main queue? Next, how do I stop it from building the queue? Next, is there anyway to automatically flush the queue once it builds if I need to?

Sorry, but I'm a serious newbie when it comes to email and specifically sendmail server.

I've googled for an answer and only find links to the Sendmail server site and its' (to me) cryptic command structure.

Thanks!

Blaine


There are a few things you need to do to investigate.
Stop the mail server.
Examine the messages and headers in /var/spool/mqueue and clientqueue to determine the source and destination.

Tail the maillog...

Code:

tail -f /var/log/maillog
Run the above command in the background if you need to.

Check your mail server for an open relay.

Code:

http://spamlinks.net/prevent-secure-relay-test.htm

Report back so we can determine the next course of action

blainemiller 06-08-2011 11:19 AM

I did all of the things as suggested except for turning sendmail off on the server. This is a critical Production system and I couldn't afford to do that.

What I did find out(finally) from an associate is that the mailq and root mail directories are filling up because of a flaw in the application level of the system. Apparently these files and directories need to be purged or deleted manually when they grow to an alerting size.

This was something I wasn't made aware of until yesterday. Oops on the Developer side.

I'm going to close this request for help as solved... Never-the-less thanks for all the information and helpful ideas.

Blaine


All times are GMT -5. The time now is 10:52 PM.