HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials

HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials (http://www.howtoforge.com/forums/index.php)
-   Installation/Configuration (http://www.howtoforge.com/forums/forumdisplay.php?f=16)
-   -   Postfix: how to force MX lookup for 'local' domain? (http://www.howtoforge.com/forums/showthread.php?t=49828)

random.guy 3rd November 2010 01:58

Postfix: how to force MX lookup for 'local' domain?
 
Let's say my server's hostname is site.com. I also run various web based software packages, which send out e-mail to customers. This works great. The problem is that my server also sends out e-mail to user@site.com.

The problem is that the site.com e-mail is not hosted on this server, it's actually hosted on a 3rd party e-mail server, so I am not getting these e-mails. Is there a way of forcing Postfix to use the MX records for site.com, even if this is the local name of the server? The server will not be receiving ANY e-mail, just send out.

Thanks!

jnsc 3rd November 2010 08:19

There is an "External mailserver" option in ISPConfig. Don't forget to set it also for co-domains.

random.guy 3rd November 2010 12:34

Oops, I didn't realize I was in the ISPConfig2 subforum, this is about a clean postfix install on Ubuntu 10.04 LTS. Hopefully a mod can move this thread.

I am hoping I can avoid hardcoding the SMTP server, or I will run into problems when the 3rd party changes its MX records. I just want to force postfix to look up the MX records for site.com whenever e-mail is sent to site.com.

Mods: please move this thread, thanks!

till 3rd November 2010 13:34

Quote:

I just want to force postfix to look up the MX records for site.com whenever e-mail is sent to site.com.
Postfix is always doing this by default. So no need to configure something. Just do not create site.com as local email domain.

random.guy 3rd November 2010 13:45

Ok, finally figured it out. It looks like I had to set mydestination to nothing:
Quote:

mydestination =

till 3rd November 2010 14:36

Mydestination has to be set to the hostname of the server, it my not be empty. Just make sure that you use a subdomain for it as it is described in the perfect setup manuals.


All times are GMT +2. The time now is 02:16.

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