Relay access denied, means a server will not send the message because it is configured not to do so. Either because the sender is unknown or the IP from where the email is coming is unknown.
First, looking at the latter, a server might employ SMTP authentication (with, or without SSL or TLS) or POP BEFORE SMTP authentication to tell the server that the connecting IP address (client machine) is allowed to send email and the server will relay in this case. (I hope your machine is not an open relay so you should be employing one of these 2 methods).
Second, not all NDR are legitimate, some are spam, however I'm guessing we can rule that out as a possibility for now and we are dealing with a real issue.
Setting up a PTR record with whoever manages your IP address/range is a good idea to minimize spam, since receiving mailservers or anti-spam appliances (like Barracudas) might do a reverse DNS check to see if it matches the hostname in the email header.. if not, it may be tagged as spam.. However...though it may be tagged, it is unlikely to generate the above mentioned error messages. It will more likely generate a 451 or 452 message (if any at all).
In a case like this, it would be very useful if you have access to the mailserver logs, particularly from the smtpd daemon/service or better yet, if you can record the SMTP conversation between the servers. Either with a "recordio" like utility or a TCP sniffer in verbose mode to troubleshoot the issue.
If that is not an option, open a telnet window on port 25 to your mailserver and manually inject a message. Sometimes you get a more meaningful error message there: Just search Google for "telnet test smtp" and many hits will come up.
Lastly, the above error, really is a relaying issue, sometimes this happens because of DomainKeys or SPF violations. Is your mailserver using this? To what behaivour is it set? tag only or does it do more? If there is an anti-spam appliance in between (like the Barracuda), what do these logs say? Probably they would say "allowed", but they can still be blocked for technical reasons or SPF violations. For example if Domain A sends to you through the Barracuda then it will be blocked since the Barracuda is not in the SPF record of Domain A. and will not arrive at B, though this should generate another message (and not one of the above).
Main Topics
Browse All Topics





by: debuggerauPosted on 2008-11-16 at 16:21:00ID: 22972517
Yes, I got this too sometimes, what really improved its reliability was to use a better DNS server for the lookups. It appears some DNS servers fail to give the right MX record, or were set to use another server where a SMTP receiver was not present.
I still get them occasionally when sending to flaking domains, but at least now I can point the customer to their email server or provider.
I also used the detailed SMTP logs to deduce this, really helps...