I use PHP to send email which uses sendmail. I noticed that some emails are not being delivered with the below errors in /var/log/maillog

Example 1
stat=Unknown Sender

Example 2
stat=Deferred: 450 4.1.8 apache@testname.testurl.net: Sender address rejected: Domain not found

Example 3
stat=Deferred: 421 invalid sender domain 'testname.testurl.net' (misconfigured dns?)

Information about the server...

hostname - testname

/etc/hosts - localhost.localdomain hostname
xxx.xxx.xxx.xxx - testname.testurl.net testname
::1 - localhost6.localdomain6 localhost6

Running Centos 5.8

  • 1
    Could you post FULL log entries? [Both from= and to= lines] – AnFi May 16 '13 at 18:52

You have to make sure that all email related names and domains are existent and can resolve to your IP address. vice versa the IP address should be resolved to your domain.

  • How would I check this? – Robert May 16 '13 at 13:49
  • you have to set your hostname to something you can resolve via a public nameserver. in additio to that you have to tell your ISP that he should set the reverse dns entry for your IP address to your choosen domain / hostname – Pascal Schmiel May 16 '13 at 13:54

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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