Emails are staying in the queue. How do I force Qmail to process all messages in the queue immediately?

Created:

2016-11-16 12:57:16 UTC

Modified:

2017-04-24 11:15:37 UTC

3

Was this article helpful?


Have more questions?

Submit a request

Emails are staying in the queue. How do I force Qmail to process all messages in the queue immediately?

Applicable to:

  • Plesk for Linux

Symptoms

Email can be sent and received without a problem, but some messages are staying in the queue:

# /var/qmail/bin/qmail-qstat
messages in queue: 37
messages in queue but not yet preprocessed: 0

What can I do?How long will these messages stay in the queue?

Cause

Situations in which emails cannot be delivered to certain addresses are common. If Qmail cannot deliver a message to the destination server for temporary reasons (for example, a connection problem), it stores the message in the queue and will make further attempts to deliver it during the period defined in /var/qmail/control/queuelifetime (set by default to one week).

Resolution

There's not much you can do about backed up emails in the Qmail queue. Ultimately, they will be delivered to their intended recipients or they will bounce with fatal errors after seven days.

Qmail's algorithm that determines email sending attempts is hard-coded and cannot be modified. You can find more details and exact values at http://www.lifewithqmail.org/lwq.html#retry-schedule .

You can find the cause of a failed email delivery attempt at $PRODUCT_ROOT_D/var/log/maillog

If you wish to force Qmail to process mail that is stuck in the queue, send the "ALRM" signal to the "qmail-send" process and Qmail will try to send all messages in the queue immediately:

kill -ALRM `ps ax | grep [q]mail-send | awk '{print $1}'`

Learn how to examine messages stuck in the queue and what to do if there are many SPAM messages in the queue in article #213379869 .

Have more questions? Submit a request
Please sign in to leave a comment.