Server Fault is a question and answer site for system and network administrators. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

Is there a way in Postfix to ignore the relayhost?

I have something like

relayhost = []:587

Now for a certain domain I don't want to send it out to that relay but want it to just send from that machine.

How do I have to configure Postfix to do that?

share|improve this question
up vote 11 down vote accepted
#relayhost = []:587
transport_maps = hash:/etc/postfix/transport

domaintodeliverdirectyto :
* smtp:[]:587

Don't forget to postmap /etc/postfix/transport

May want to use relay instead of smtp as the transport mechanisim.
For reference

share|improve this answer
thanks worked great – Mike Oct 12 '11 at 22:41

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.