Go Back   HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials > Linux Forums > Server Operation

Do you like HowtoForge? Please consider supporting us by becoming a subscriber.
Reply
 
Thread Tools Display Modes
  #1  
Old 26th February 2008, 00:00
moxie moxie is offline
Junior Member
 
Join Date: Feb 2008
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default Postfix - wildcard email forwarding

Hello All,
I am a postfix newb, so hopefully this one is easy. I have been searching all over the internet and I can't seem how to configure postfix to forward wildcard emails to another email account.

This comes out of the need to handle bounced emails to maintain my email list. I read that a good strategy is to embed the userID in the return-path of all emails being sent out, and if they bounce, you can send all the bounced emails to a catchall account, then process them from there, grab the userID and remove the user from the mailing list.

Well, I wrote all the code to do that, I pull emails from an exchange account, parse out the userid, and remove it if it's a hard bounce, it works great, but I can't figure out how to forward the emails to the catchall account.

I looked at alias, but I couldn't get it to work. I also looked at VERP, but I don't think it's what I want.

for example
<bounce_1234@example.com> ends up in <bounce@example.com>
<bounce_2344@example.com> ends up in <bounce@example.com>
<bounce_3427@example.com> ends up in <bounce@example.com>
<bounce_5349@example.com> ends up in <bounce@example.com>
etc...

thank you very much for any input or direction you could provide!
Reply With Quote
Sponsored Links
  #2  
Old 26th February 2008, 07:24
topdog topdog is offline
Senior Member
 
Join Date: Jan 2008
Location: South Africa
Posts: 1,352
Thanks: 0
Thanked 153 Times in 150 Posts
Default

You can do that using the virtual transport, so this depends on how your postfix is implemented if you are not using external storage ie a database do this

Edit /etc/postfix/virtual
Code:
@example.com <user_to_get_all_unknown>
Then run
Code:
postmap /etc/postfix/virtual
postfix reload
__________________
----
http://www.topdog.za.net - Got Linux problems ? - I can help.
http://www.baruwa.org - Try it.
Reply With Quote
  #3  
Old 27th February 2008, 03:33
moxie moxie is offline
Junior Member
 
Join Date: Feb 2008
Posts: 2
Thanks: 0
Thanked 0 Times in 0 Posts
Default

Thanks for the reply.

I looked at this virtual domain, and the problem is that I already have a catchall account setup on my domain.

@example -> spam@example.com

so, I was hoping in postfix, I could set up some sort of wildcard address that forwarded "bounced*@example.com" -> bounced@example.com

so that anything that was emailed to bounce<anything else>@example.com would show up in bounce@email.com's mailbox.

i guess if all else fails, I could send emails from a sub-domain and have another catch-all on that sub-domain which I could assume would only be bounced-emails. But I would prefer to not have to set up a sub-domain.

Thanks again for any input.
Reply With Quote
  #4  
Old 27th February 2008, 07:35
topdog topdog is offline
Senior Member
 
Join Date: Jan 2008
Location: South Africa
Posts: 1,352
Thanks: 0
Thanked 153 Times in 150 Posts
 
Default

I think you can do that i have never tried but give it a try although i think bounce* to bounce will give you a mail loop
__________________
----
http://www.topdog.za.net - Got Linux problems ? - I can help.
http://www.baruwa.org - Try it.
Reply With Quote
Reply

Bookmarks

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Postfix email server config veremchook Server Operation 10 18th April 2009 16:14
Mail System Error - Returned Mail tristanlee85 General 16 16th March 2008 09:40
Centos 4.4 32bit Hangs, High Server load 3cwired_com Server Operation 11 16th November 2006 15:47
Verify email setup meekish Installation/Configuration 28 27th October 2006 15:36
email forwarding locally consumes all resources rdells General 20 1st May 2006 19:43


All times are GMT +2. The time now is 09:10.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.