Take the 2-minute tour ×
Server Fault is a question and answer site for professional system and network administrators. It's 100% free, no registration required.

I have just installed POSTFIX on a Debian box, I pointed the relay host config setting to an exchange server which will deliver the mail to external users.

So what I am trying to do is telnet to the debian box and send an email to xxx@gmail.com which will then be past to the exchange server for delivery.

The problem is I get the following:

rcpt to:xxx@gmail.com
554 relay access denied

I have seen a section in the config "mydestination" but i want the exchange server to decide which domains it will deliver for and not the POSTFIX server.

share|improve this question
1  
Data we need to help you: the output of "postconf -n", any logs –  Bill Weiss Oct 27 '09 at 20:01
1  
This should be tagged with exchange as this is an Exchange configuration issue. If your situation was the other way around you would have to configure Postfix to treat your Exchange server as coming from my_networks or require authentication. –  Goran Jurić Nov 2 '09 at 7:29

3 Answers 3

Given we don't have the output of postconf -n, I bet its not the other answers. I suspect that the mynetworks configuration isn't set to trust the computer you are telneting from. I you don't want systems to auth to the postfix server, and not restrict the email address they send to, you will probablly need to add the ips/subnets to the mynetworks variable and have postfix reload its configuration.

share|improve this answer

If I understand this correctly, you have relayhost = myexchangeserver.example.com in your main.cf. If so, the problem is that Exchange is refusing to relay mail from your debian system. The exchange box is issuing the 554 error. You could verify if this is happening by doing:

telnet myexchangeserver.example.com 25

See this tutorial for how to do a test SMTP conversation with the Exchange server:

http://www.activexperts.com/activemail/telnet/

share|improve this answer
    
we have a similar setup, and the Exchange box likely views your Debian box as "foreign". In my experience, it is much easier to configure Postfix to handle relaying properly than it is Exchange, but that's based on my limited experience with Exchange and having to negotiate the configuration with our Exchange admin. –  Greeblesnort Oct 29 '09 at 2:27
    
I have a feeling he wants exchange to be the SMTP so that it can automatically know which deliveries are local and the rest are delivered out. Unfortunately I can't tell you how to configure exchange to do that. In my configuration, the smtp server has no mailboxes, but is postfix. It uses virtual_alias_maps to map user@example.com to user@exchange.example.com and there is a transport set up for exchange. This requires maintaining the mapping file with entries for each exchange account. –  labradort Oct 30 '09 at 11:27

Do you have set up SMTP authentication? Is it required by Exchange? For example, we relay only from authenticated users.

I could help you set it up in exim, but not postfix.

share|improve this answer

Your Answer

 
discard

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