// archives

postfix

This tag is associated with 1 posts

Postfix: Log E-mails’ Subject

In Linux, you can view the statistics of incoming and outgoing E-mails by peeking into a log file called maillog (typically found in /var/log directory). Maillog provides the general information about the mails, for example, the sender and recipient(s), status – sent, rejected, bounced etc. I typically use maillog to check the destiny of mails. At times, it becomes difficult to spot a particular mail due to the sheer volume of mails being logged – especially on a production mail server.

For example: what if we need to check whether a particular mail sent by Person A has been delivered to Person B. Note that Person A might be sending lots of mails to Person B but we need to spot that one particular mail – say the one, which was sent by Person A but did not reach Person B. The only identifier, to identify a particular mail, in the maillog is the cryptic message ID. A better and more readable identifier would be the subject of an E-mail.Unfortunately, the subject of the mails is not logged, by default, in the maillog. But we can configure a mail server like Postfix to log the subject line. Read the rest of this entry »

GD Star Rating
loading...
GD Star Rating
loading...

Postfix issue: Skipped, still being delivered

Today, a client of mine complained about mails not showing up. The system administrator (at the client’s place) claimed to see the mails in the mailq (mail queue). I logged into the server and indeed found the mails in the mailq. After checking the logs (/var/log/maillog) I saw messages, similar to the one below, repeating:

Jul 10 17:01:05 server postfix/qmgr[24347]: CB4F21928CBA: skipped, still being delivered

This message repeated for many (maybe all) messages held in the mailq. Googled and googled for a possible reason/solution or a hint to it. The reason which made most sense to me was “Postfix was restarted when qmgr (Queue Manager) was processing the mails”, found via Google.The system administrator also reported of restarting Postfix.

Flushing the queue (service postfix flush) did not work. The solution that finally worked was re-queuing  the mails using the following command:

postsuper -r ALL

and I could see the queue clearing up!

GD Star Rating
loading...
GD Star Rating
loading...