How to delete specific messages from sendmail queue FROM a certain email address?
I have suddenly had one of my customer Email servers go balistic (possibly compromised) and they use our sendmail server as a relay. We have over 100,000 rubbish messages from them (all from the SAME Email address) in our mail queue. We have been relaying this nonsense for long enough to have been blacklisted on some of the biggies. I urgently need to run something to delete these messages from the queue.
I have always used Webmin for this task but it seems this time there are too many messages in the queue and Webmin simply gasps and dies, not completing the search.
I hope someone can help - we know the FROM address we want to delete. Is there some script I can run on this queue which will delete specific messages with a specific FROM address in the queue? We currently have our server down and are receiving loads of support calls but I cannot put it back up again until we have deleted the messages currently in the queue.
I have disabled reaying from the customer and blocked their IP in the firewall. Now all I need do is get rid of the pesky messages.