fbpx

How to gain control over a postfix server by deleting all messages in the queue at once

If your postfix server is running away and it’s chaos because there are 1000s or millions of messages in the queue, your only recourse might be to remove all the messages in the queue and face the backlash of clients who might have missed some email.

However, two situations prevail:

  1. You’re probably deleting millions of SPAM messages so it will be okay.
  2. If the email is really so important, maybe the sender must try again? (It’s called tenacity)

So here we are with the commands:

postsuper -d ALL deferred

postsuper -d ALL

postsuper -d mail_queue_id (run mailq command to get the ID)

Reference
https://sharadchhetri.com/2014/02/06/how-to-delete-mail-queue-in-postfix/

Share this article

Share on facebook
Share on twitter
Share on linkedin

Leave a Reply

Your email address will not be published. Required fields are marked *

Scroll to Top