From 28b8e6d8365d44158c51895878b23904153bcbbc Mon Sep 17 00:00:00 2001 From: Nicole Rappe Date: Mon, 29 Dec 2025 20:35:14 -0700 Subject: [PATCH] Add Servers/Email/iRedMail/Query SMTP Outgoing Queue.md --- .../iRedMail/Query SMTP Outgoing Queue.md | 25 +++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 Servers/Email/iRedMail/Query SMTP Outgoing Queue.md diff --git a/Servers/Email/iRedMail/Query SMTP Outgoing Queue.md b/Servers/Email/iRedMail/Query SMTP Outgoing Queue.md new file mode 100644 index 0000000..528eec7 --- /dev/null +++ b/Servers/Email/iRedMail/Query SMTP Outgoing Queue.md @@ -0,0 +1,25 @@ +## Purpose +You may need to troubleshoot the outgoing SMTP email queue / active sessions in iRedMail for one reason or another. This can provide insight into the reason why emails are not being delivered, etc. + +### Overall Queue Backlog +You can run the following command to get the complete backlog of all email senders in the queue. This can be useful for tracking the queue's "drainage" over-time. + +```sh +postqueue -p | awk '/^[A-F0-9]/ {id=$1} /from=<[^>]+>/ && $0 !~ /from=<>/ {print id; exit}' +``` + +!!! example "Example Output" + 10392 problematic@bunny-lab.io + 301 prettybad@bunny-lab.io + 39 infrastructure@bunny-lab.io + 20 nicole.rappe@bunny-lab.io + +### Investigating Individual Emails +You can run the following command to read detailed information on any specific queued SMTP message: + +```sh +postqueue -p +postcat -vq 4dgHry5LZnzH6x08 # (1) +``` + +1. Example message ID gathered from the previous `postqueue -p` command. \ No newline at end of file