This perl script will bulk remove emails from the Postfix mail queue based on a keyword, email domain, or email address. The script came from this blog post: #!/usr/bin/perl $REGEXP = shift || die “no email-adress given (regexp-style, e.g. bl.*\@yahoo.com)!”; …
This command will tell you how many emails are in the Postfix mail queue postqueue -p | tail -n 1 | cut -d’ ‘ -f5