Gentoo Forums
Gentoo Forums
Gentoo Forums
Quick Search: in
How to set up mail forwarding with Postfix and no relayhost?
View unanswered posts
View posts from last 24 hours

 
Reply to topic    Gentoo Forums Forum Index Networking & Security
View previous topic :: View next topic  
Author Message
olsberg
n00b
n00b


Joined: 24 Sep 2003
Posts: 19
Location: Sweden

PostPosted: Sat Jan 10, 2009 8:14 pm    Post subject: How to set up mail forwarding with Postfix and no relayhost? Reply with quote

Hi, this is a mail newbie question. You have been warned. :)

I have a Postfix server running that recieves mail for multiple accounts on the server. Everything works here, and the mails are stored locally in /home/[user]/.maildir directory.

But, I'd like to forward the mail to different domains, depending on where my colleagues are having their primary e-mail accounts (eg xxx@yahoo.com, yyy@gmail.com AND zzz@hotmail.com. Reading different guides, I've tried to use the .forward file in each user dir root, but it doesent work.

Are there any way to forward mail without using an external relayhost? Or am I walking the wrong path here?

Best,
Back to top
View user's profile Send private message
magic919
Advocate
Advocate


Joined: 17 Jun 2005
Posts: 2182
Location: Berkshire, UK

PostPosted: Sat Jan 10, 2009 9:21 pm    Post subject: Reply with quote

I've used the .forward file method in the past with Postfix.
Back to top
View user's profile Send private message
olsberg
n00b
n00b


Joined: 24 Sep 2003
Posts: 19
Location: Sweden

PostPosted: Sun Jan 11, 2009 8:43 am    Post subject: Reply with quote

As soon as the .forward file is in place, the mail is not delivered at all. Do I need additional software to do this?
Back to top
View user's profile Send private message
magic919
Advocate
Advocate


Joined: 17 Jun 2005
Posts: 2182
Location: Berkshire, UK

PostPosted: Sun Jan 11, 2009 10:13 am    Post subject: Reply with quote

The .forward file should be read by Postfix acting as the delivery agent. Postfix should then pass the email to forward@example.com. I would examine your Postfix logs as they will show what Postfix is doing with the mail.
Back to top
View user's profile Send private message
olsberg
n00b
n00b


Joined: 24 Sep 2003
Posts: 19
Location: Sweden

PostPosted: Sun Jan 11, 2009 7:58 pm    Post subject: Case solved Reply with quote

OK, the follow-up: It was probably working from the beginning, when I look at the logs. The problem was that I was sending mail from my Gmail account to the e-mail adress on my server - which was forwarded back to my Gmail account. Gmail seems to be smart enough to avoid endless loops and filters them out :)

In short: I thought the forward didn't work since I didn't get the forwarded mail that was filtered out from Gmail.

Thanks for pointing me to the logs!
Back to top
View user's profile Send private message
Display posts from previous:   
Reply to topic    Gentoo Forums Forum Index Networking & Security All times are GMT
Page 1 of 1

 
Jump to:  
You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum