Table of Contents

Postfix - Queue Management

About

How to manage the postfix queues

Management

The management is done with this tools:

Number of emails

postqueue -p | grep -c "^[A-Z0-9]"

Resend

postqueue -f
postqueue -i “Queue ID”
postqueue -I EmailID

Remove

postsuper -d ALL
postsuper -d EmailID
postsuper -d “Queue ID”
$PATTERN="Header: bad"
for id in `postqueue -p | grep '^[A-Z0-9]' | cut -f1 -d' ' | sed 's/*//g'`; do 
    postcat -q $id | grep $PATTERN && postsuper -d $id; 
done

List

 
postqueue -p

See

You need first to list in order to retrieve the email id.

postcat -q EmailID

Move between queue

postsuper -h ALL
postsuper -r ALL

Documentation / Reference