Delete emails from email queue in PLESK
Published: 14 years ago
The GUI for PLESK's CMS is quite limited when you want to delete a large number of emails in one batch without crashing the website.
Through a linux command line you can filter and delete messages by either their email address, subject, from or to targets.
How to use qmHandle
qmHandle -h
####################################################################
Available parameters:
-a : try to send queued messages now (qmail must be running)
-l : list message queues
-L : list local message queue
-R : list remote message queue
-s : show some statistics
-mN : display message number N
-dN : delete message number N
-fsender : delete message from sender
-f're' : delete message from senders matching regular expression re
-Stext : delete all messages that have/contain text as Subject
-h're' : delete all messages with headers matching regular expression re (case insensitive)
-b're' : delete all messages with body matching regular expression re (case insensitive)
-H're' : delete all messages with headers matching regular expression re (case sensitive)
-B're' : delete all messages with body matching regular expression re (case sensitive)
-t're' : flag messages with recipients in regular expression 're' for earlier retry
-D : delete all messages in the queue (local and remote)
-V : print program version
Additional (optional) parameters:
-c : display colored output
-N : list message numbers only
(to be used either with -l, -L or -R)
Filter & Delete By Subject
qmHandle -S"Subject of Emails"
qmHandle Not installed?
There's a really helpful quick article about how to get this program working on your linux server - Support Facility Blog
comments powered by Disqus