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

I'm trying to send email from my EC2 instance.

Regardless of the target email address the SMTP service logs show that the email is sent but it never turns up on the remote server.

I've done a blacklist check of my domain at: and it returns ok.

Email to shows the following in /var/log/maillog:

May  6 23:52:33 ip-172-31-21-52 sendmail[10534]: r46NqXPF010534: from=root, size=236, class=0, nrcpts=1, msgid=<201305062352.r46NqXPF010534@ip-172-31-21-52.ap-southeast-2.compute.internal>, relay=root@localhost
May  6 23:52:33 ip-172-31-21-52 sendmail[10535]: r46NqXit010535: from=<root@ip-172-31-21-52.ap-southeast-2.compute.internal>, size=571, class=0, nrcpts=1, msgid=<201305062352.r46NqXPF010534@ip-172-31-21-52.ap-southeast-2.compute.internal>, proto=ESMTP, daemon=MTA, relay=localhost []
May  6 23:52:33 ip-172-31-21-52 sendmail[10534]: r46NqXPF010534:, ctladdr=root (0/0), delay=00:00:00, xdelay=00:00:00, mailer=relay, pri=30236, relay=[] [], dsn=2.0.0, stat=Sent (r46NqXit010535 Message accepted for delivery)
May  6 23:52:35 ip-172-31-21-52 sendmail[10537]: STARTTLS=client,, version=TLSv1/SSLv3, verify=FAIL, cipher=RC4-SHA, bits=128/128
May  6 23:52:38 ip-172-31-21-52 sendmail[10537]: r46NqXit010535: to=<>, ctladdr=<root@ip-172-31-21-52.ap-southeast-2.compute.internal> (0/0), delay=00:00:05, xdelay=00:00:05, mailer=esmtp, pri=120571, [], dsn=2.0.0, stat=Sent (OK 1367884358 kx5si16370724pbc.170 - gsmtp)

We have applied to have the send limits removed and Amazon have confirmed this has been done.

Where else should I look?

share|improve this question
Looks like google's mail server ( is accepting the mail (OK 1367884358 kx5si16370724pbc.170 - gsmtp) I'd try sending mail to another address that doesn't use gmail. – Mark Wagner May 7 '13 at 0:05

The From: address (root@ip-172-31-21-52.ap-southeast-2.compute.internal) is not deliverable. Many mail servers will not accept mail with a From: address that is undeliverable.

You don't appear to have an Elastic IP address. All of Amazon's IP addresses are added to the Spamhaus Policy Blacklist (PBL) by default unless you attain an Elastic IP address, configure a domain to point at it and then fill out the form linked here to have Amazon configure the reverse DNS records to match the forward records you have already created. They also remove the IP addresses from the Policy Blacklist at the same time.

I wouldn't be surprised if Google had a mechanism for either querying the Spamhaus PBL or maintaining their own list.

share|improve this answer
I have an elastic IP – Greg Pagendam-Turner May 7 '13 at 3:44
...and on a side note, because the sender address isn't valid, NDRs from downstream servers wouldn't make their way back to the sender. – Mike B May 7 '13 at 22:37
up vote 2 down vote accepted

The issue appeared to be related to their being no public DNS for the server's domain.

I configured sendmail to masquerade an internet visible domain name and this fixed the problem.

Edit /etc/mail/



m4 /etc/mail/ > /etc/mail/

Restart sendmail

share|improve this answer
This worked for me, except that I needed to execute 'sendmailconfig'. – dirkk0 Dec 16 '13 at 17:33

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.