Weblog entry #2 for Wayne

Postfix & procmail help
Posted by Wayne on Tue 8 Jul 2008 at 16:35
I have a postfix box which I have inherited. It is running disk quota's and the main anti-spam features built into postfix. The trouble I'm having is a lot of the email addresses are now no longer used so any email going into them is accepted by postfix then procmail tries to deliver the mail which fails and is then put back into the postfix queue to be sent back to the original sender.

We are not using mysql so I'm unsure of how to stop postfix accepting the email when the user is over quota, failing that how can I redirect (to dev/null or another address) the over quota message from procmail or postfix?

Once I have a list of the boxes over quota I can check the email addresses to see if they are still active or not.


Wayne

 

Comments on this Entry

Posted by simonw (84.45.xx.xx) on Thu 10 Jul 2008 at 21:38
[ Send Message | View Weblogs ]
Just grep the mail log and delete any accounts that have been overquota for too long, or haven't logged in to collect their email (PAM may be able to do this for you!).

Putting the bounce back in the queue is the right thing to do, since the sender should be notified that the email didn't get delivered to the end user. Stop trying to "break" postfix, and fix your user management ;)

If you are stopping most spam, then these bounces should be delivered promptly in most cases. If they aren't perhaps time to review the spam filtering. I have a box forwarding email for tends of thousands of accounts, and the queue is routinely only 20 messages or so (except when we decide to try and contact all our customers).

[ Parent | Reply to this comment ]

Posted by Wayne (82.144.xx.xx) on Thu 10 Jul 2008 at 23:50
[ Send Message | View Weblogs ]
Your absolutely right I was trying to break postfix but only for a short while until I can get the list of dead accounts,,, honest :-) (grabbed 250 so far)

Any tips you can give on using PAM would be great. I have people logging in using ipopd and imapd plus webmail. 1300 accounts and no idea which/how many should be live. So far the spam has greatly reduced since adding the anti-spam features as these were not turned on, in fact the server only had a 9 gig disk and everybody had unlimited mailbox leaving the disk with 50mb free which is why I enabled the quota's. It's been fun I can tell you.

Wayne

[ Parent | Reply to this comment ]

User Login

Username:

Password:

[ Advanced Login ]

Register Account

Mail Filtering

Quick Site Search