LinuxQuestions.org
Share your knowledge at the LQ Wiki.
Go Back   LinuxQuestions.org > Forums > Linux Forums > Linux - Server
User Name
Password
Linux - Server This forum is for the discussion of Linux Software used in a server related context.

Notices

Reply
 
LinkBack Search this Thread
Old 11-24-2009, 08:47 AM   #1
IMAN7
LQ Newbie
 
Registered: Nov 2009
Posts: 11

Rep: Reputation: 0
second domain on the same postfix server


Hello all

I have a postfix relay running in RHEL 5.
It serves as an SMTP server.
Mail traffic is delivers to the exchange server/Active directory system that is handled by another admin.

So far postfix serves example.com
I am asked if it's possible to configure the same server to relay inbound and outbound email for the domain otherexample.com

Any suggestions?
 
Old 11-24-2009, 10:55 AM   #2
isomtech
LQ Newbie
 
Registered: Mar 2005
Posts: 13

Rep: Reputation: 1
In your /etc/postfix/main.cf file, you should find a line that starts with "relay_domains=".
This most likely has your 1st domain listed there. Add the 2nd domain to this line separated by a comma. The final result should look something like:
relay_domains=example.com,otherexample.com

Dave
 
Old 11-24-2009, 11:26 AM   #3
Cybrax
LQ Newbie
 
Registered: Oct 2009
Posts: 11

Rep: Reputation: 0
i was wrong

Last edited by Cybrax; 11-24-2009 at 11:38 AM.
 
Old 11-24-2009, 11:31 AM   #4
isomtech
LQ Newbie
 
Registered: Mar 2005
Posts: 13

Rep: Reputation: 1
If this is a relay server and it is supposed to relay mail to an Exchange server, then it should not be the destination for those domains. It should be configured to relay for those domains.

You may also need to configure transport maps for the domain, since an MX lookup might yield the wrong results. Check to see if your main.cf file has a line like this one:
transport_maps=hash:/etc/postfix/transport

you may have to edit the file that it points to (it may not be /etc/postfix/transport). This file will override the DNS query and directly route mail for a specific domain to a predetermined destination. You may have something like this:

example.com smtp:exchangeserver.example.com

you'll have to make another entry for your new domain, and point it to the appropriate destination server. After you modify this file, run:
postmap /etc/postfix/transport (or whatever the file is that you had to edit)

There are a myriad of other ways to accomplish the same basic function, so your results may vary.

Last edited by isomtech; 11-24-2009 at 11:41 AM.
 
Old 11-24-2009, 11:37 AM   #5
Cybrax
LQ Newbie
 
Registered: Oct 2009
Posts: 11

Rep: Reputation: 0
Quote:
Originally Posted by isomtech View Post
If this is a relay server and it is supposed to relay mail to an Exchange server, then it should not be the destination for those domains. It should be configured to relay for those domains.
Yes im sorry your right since it's relayed it will accept mail for any domain anyways

i was confused with postfix denieing mail for domains not in mydestination but that is only when that server handles it

the admin of the server thats relayed too has todo this then


Sorry my bad
 
  


Reply


Thread Tools Search this Thread
Search this Thread:

Advanced Search

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 Off
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
local postfix server not able to send mails to other domain subramanyabs1984 Linux - Server 1 03-13-2009 06:27 AM
local domain versus official domain in POSTFIX lucmohamed Linux - Server 1 04-14-2008 07:06 AM
Postfix Help - Allow only one domain waddy Linux - Server 7 06-05-2007 06:05 PM
Postfix as a mail server for domain LJ151 Linux - Software 2 07-16-2004 04:53 PM


All times are GMT -5. The time now is 01:26 PM.

Main Menu
 
My LQ
Write for LQ
LinuxQuestions.org is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
Syndicate
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
identi.ca: @linuxquestions
Facebook: @linuxquestions
Open Source Consulting | Domain Registration