Postfix delete mail queue
To delete the mail queue in Postfix, you can use the following command:
postqueue -p | postcat -q
This command will delete all messages in the mail queue. The -p
option tells postqueue
to show the message IDs, and the postcat
command is used to delete the messages.
If you want to delete specific messages, you can use the following command:
postqueue -p | postcat -q <message_id>
Replace <message_id>
with the ID of the message you want to delete.
You can also use the postsuper
command to delete messages from the mail queue. For example:
postsuper -d ALL
This command will delete all messages in the mail queue. You can also specify a specific message ID or a range of message IDs to delete.
Note: Be careful when deleting messages from the mail queue, as this can cause mail to be lost. Make sure you have a backup of your mail queue before deleting messages.
Also, you can use postqueue -d
command to delete specific message, for example:
postqueue -d <message_id>
This command will delete the message with the specified ID from the mail queue.