Article ID: 6010, created on Feb 4, 2009, last review on Aug 12, 2014

  • Applies to:
  • Plesk


The current article is obsoleted by this one:

169 I see that some messages are staying in the queue. How do I force Qmail to process all messages in the queue immediately?

Mail can be sent and received fine, but some messages are staying in queue:
# /var/qmail/bin/qmail-qstat
 messages in queue: 37
 messages in queue but not yet preprocessed: 0

What can I do?
How long the messages staying in queue before removing?


Actually, the situation when email messages cannot be delivered to some addresses occurs often. If Qmail cannot deliver the message to the destination server for some temporarely reasons (for example connection problem), it stores the message in queue and will try to deliver it again and again during the period that is defined in /var/qmail/control/queuelifetime (by default it is set to one week).


You may do nothing regarding several messages in Qmail queue. At the end they will be delivered to recipients or bounced with the fatal errors after seven days.
The algorithm of mail sending attempts is hard-coded in Qmail, it cannot be modified. You can see for more details and exact values at

Also, you can find the reason of the mail delivery failing in $PRODUCT_ROOT_D/var/log/maillog.

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

kill -ALRM `ps ax | grep qmail-send | grep -v grep | awk '{print $1}'`

See how to examine messages in queue and what to do if there are many SPAM messages in queue in the 766 article.

a914db3fdc7a53ddcfd1b2db8f5a1b9c 56797cefb1efc9130f7c48a7d1db0f0c

Email subscription for changes to this article
Save as PDF