Configure a receive connector to work from anonymously from the Exchange 2013 server

I set a receive connector to allow anonymous relay for internal addresses and all works except when I try to send from the Exchange server itself. The exchange server will only send to internal address and not to external addresses. The email is sent using a powershell script running on 2012 R2 servers in addition to printers. All email sent using the anonymous allowed receive connector works, except from the Exchange server itself.

I created the connector as a frontend connector. Allowed specific IP addresses to use it (including the IP of the exchange 2013 server). Authentication: TLS and Permission Groups: Exchange Servers & Anonymous users . I added the required AD extended rights for anonymous (Ms-Exch-SMTP-Accept-Any-Recipient).

After I did all above to make the receive connector, sending from printers and with powershell scripts on others servers listed in the allowed IPs works, except for the powershell script running on the exchange server itself. I added AD permission for the computer account of the exchange server and added Exchange Servers to the permission groups, but did not help.

The error message is: "Mailbox unavailable. The server response was: 5.7.1 Unable to relay".
Who is Participating?
Simon Butler (Sembee)ConsultantCommented:
When sending email to itself, Exchange will see the connection as coming from the IPv6 address.
If you send to an internal recipient with the same script, then look at the headers you will see how Exchange is seeing the email.

byt3Author Commented:
Simon Butler,
you sir, are a gentleman and a scholar.

The Exchange server was indeed connecting to itself using the IPv6 Link Local address. I changed the anonymous receive connector to be bound to all IPv6 interfaces and added the link-local IPv6 address of the exchange server to the allowed remote servers. I also changed the scope of the internet connector to not include the link-local address range .
byt3Author Commented:
Thanks Simon
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.