how to delete email in queue sent to a specific user?
I don’t know,
you have not supplied any details about your server like this
SYSTEM INFORMATION | |
---|---|
OS type and version | Ubuntu Linux 22.04.3 |
Webmin version | 2.101 |
Usermin version | 2.001 |
Virtualmin version | 7.8.2 |
Theme version | 21.06 |
Package updates | All installed packages are up to date |
Operating system: Ubuntu Linux 20.04.6
Webmin version: 2.101
Usermin version: 2.001
Virtualmin version: 7.8.2
Theme version: ( i don’t know where to find it)
Package updates: All installed packages are up to date
click the arrowed button will copy the details to the clipboard then you can paste into a post
so do you see messages in the postfix queue ?
webmin➡servers➡postfix mail server➡mail queue
i want to know if it is possible to delete all mail queue sent to a specific email/user with a command?
I delete all the queue, it would be hard otherwise.
You need the command
postsuper -d <msg id>
ran as root … you can get the msg id from your queued messages
i wanted a command to delete in bulk this is why i want to delete emails sent to a specific user
that way will be faster
Write a script the reeds the output from postqueue -p line by line then delete the ones you want. Just wondering why tou get queued messages . If i have a queue it normally means something is afoot
i found this command and it works
it will delete all emails in the queue sent to a specific user
postqueue -p | awk ‘BEGIN { RS = “” } /email@example.com/ { print $1 }’ | sed ‘s/[^a-zA-Z0-9]//g’ | while read queue_id; do postsuper -d “$queue_id”; done
This topic was automatically closed 8 days after the last reply. New replies are no longer allowed.