Question

Unable to Sendmail to Google on NYC3 but NYC1 works fine

Posted February 4, 2015 4.5k views

I have been in touch with Tech support about this but they are saying everything is working like it should.

This all started when on NYC3 I installed the one click Ruby on Rails Application gitlab and was not getting email.

I moved over to NYC1 and all mail worked fine with it

Then I created several test droplets on NYC3 with different IP addresses, different versions of Ubuntu as well

I would try to send mail and it would just fail.

For the last round of tests I did the exact same server set up

I fired up a Ubuntu Droplet for 14.04 and only did the following

sudo apt-get install apache2
sudo apt-get install php5 libapache2-mod-php5 php5-mcrypt
sudo apt-get install sendmail

Then I used the following php file for the test

<?php
$to = ’testing@gmail.com’;
$subject = ‘the subject’;
$message = 'hello’;
$headers = 'From: git@mydomain.com’ . “\r\n” .
'Reply-To: webmaster@example.com’ . “\r\n” .
'X-Mailer: PHP/’ . phpversion();

mail($to, $subject, $message, $headers);
?>

Once again NYC3 failed to deliver any mail and NYC1 delivered mail

I have checked the NYC3 IP address to see if it is black listed and it is not

http://mxtoolbox.com/SuperTool.aspx?action=blacklist%3a104.236.247.175&run=toolpage

Here are the log values for the last attempt

syslog


Feb 3 15:50:35 test sendmail[5032]: unable to qualify my own domain name
(test) – using short name
Feb 3 15:50:35 test sendmail[5032]: t13KoZZ5005032: from=www-data,
size=187, class=0, nrcpts=1, msgid=201502032050.t13KoZZ5005032@test,
relay=www-data@localhost
Feb 3 15:50:35 test sm-mta[5034]: t13KoZLw005034: from=www-data@test,
size=390, class=0, nrcpts=1, msgid=201502032050.t13KoZZ5005032@test,
proto=ESMTP, daemon=MTA-v4, relay=localhost [127.0.0.1]
Feb 3 15:50:36 test sendmail[5032]: t13KoZZ5005032: to=
testing@gmail.com, ctladdr=www-data (33/33), delay=00:00:00,
xdelay=00:00:00, mailer=relay, pri=30187, relay=[127.0.0.1] [127.0.0.1],
dsn=2.0.0, stat=Sent (t13KoZLw005034 Message accepted for delivery)
Feb 3 15:50:36 test sm-mta[5036]: STARTTLS=client, relay=
gmail-smtp-in.l.google.com., version=TLSv1/SSLv3, verify=FAIL,
cipher=ECDHE-RSA-AES128-GCM-SHA256, bits=128/128
Feb 3 15:50:36 test sm-mta[5036]: t13KoZLw005034: to=<
testing@gmail.com>, ctladdr=www-data@test (33/33), delay=00:00:01,
xdelay=00:00:01, mailer=esmtp, pri=120390, relay=gmail-smtp-in.l.google.com.
[74.125.29.26], dsn=5.0.0, stat=Service unavailable
Feb 3 15:50:36 test sm-mta[5036]: t13KoZLw005034: t13KoaLw005036: DSN:
Service unavailable
Feb 3 15:50:37 test sm-mta[5036]: t13KoaLw005036: to=www-data@test,
delay=00:00:01, xdelay=00:00:01, mailer=local, pri=30000, dsn=2.0.0,
stat=Sent
Feb 3 16:00:01 test CRON[5043]: (smmsp) CMD (test -x /etc/init.d/sendmail
&& /usr/share/sendmail/sendmail cron-msp)
Feb 3 16:00:01 test sm-msp-queue[5059]: My unqualified host name (test)
unknown; sleeping for retry
Feb 3 16:01:01 test sm-msp-queue[5059]: unable to qualify my own domain
name (test) – using short name

mail.log
Feb 3 15:50:35 test sendmail[5032]: unable to qualify my own domain name
(test) – using short name
Feb 3 15:50:35 test sendmail[5032]: t13KoZZ5005032: from=www-data,
size=187, class=0, nrcpts=1, msgid=201502032050.t13KoZZ5005032@test,
relay=www-data@localhost
Feb 3 15:50:35 test sm-mta[5034]: t13KoZLw005034: from=www-data@test,
size=390, class=0, nrcpts=1, msgid=201502032050.t13KoZZ5005032@test,
proto=ESMTP, daemon=MTA-v4, relay=localhost [127.0.0.1]
Feb 3 15:50:36 test sendmail[5032]: t13KoZZ5005032: to=
testing@gmail.com, ctladdr=www-data (33/33), delay=00:00:00,
xdelay=00:00:00, mailer=relay, pri=30187, relay=[127.0.0.1] [127.0.0.1],
dsn=2.0.0, stat=Sent (t13KoZLw005034 Message accepted for delivery)
Feb 3 15:50:36 test sm-mta[5036]: STARTTLS=client, relay=
gmail-smtp-in.l.google.com., version=TLSv1/SSLv3, verify=FAIL,
cipher=ECDHE-RSA-AES128-GCM-SHA256, bits=128/128
Feb 3 15:50:36 test sm-mta[5036]: t13KoZLw005034: to=<
testing@gmail.com>, ctladdr=www-data@test (33/33), delay=00:00:01,
xdelay=00:00:01, mailer=esmtp, pri=120390, relay=gmail-smtp-in.l.google.com.
[74.125.29.26], dsn=5.0.0, stat=Service unavailable
Feb 3 15:50:36 test sm-mta[5036]: t13KoZLw005034: t13KoaLw005036: DSN:
Service unavailable
Feb 3 15:50:37 test sm-mta[5036]: t13KoaLw005036: to=www-data@test,
delay=00:00:01, xdelay=00:00:01, mailer=local, pri=30000, dsn=2.0.0,
stat=Sent
Feb 3 16:00:01 test sm-msp-queue[5059]: My unqualified host name (test)
unknown; sleeping for retry
Feb 3 16:01:01 test sm-msp-queue[5059]: unable to qualify my own domain
name (test) – using short name

mail.err

Feb 3 15:50:35 test sendmail[5032]: unable to qualify my own domain name
(test) – using short name
Feb 3 16:00:01 test sm-msp-queue[5059]: My unqualified host name (test)
unknown; sleeping for retry
Feb 3 16:01:01 test sm-msp-queue[5059]: unable to qualify my own domain
name (test) – using short name

Yet I do the exact same set up on NYC1 and the mail sends perfectly

Here is the log of that effort

Feb 3 20:55:36 testing sendmail[4896]: My unqualified host name (testing) unknown; sleeping for retry
Feb 3 20:55:52 testing sendmail[4899]: My unqualified host name (testing) unknown; sleeping for retry
Feb 3 20:56:36 testing sendmail[4896]: unable to qualify my own domain name (testing) – using short name
Feb 3 20:56:36 testing sendmail[4896]: t141uaal004896: from=www-data, size=187, class=0, nrcpts=1, msgid=201502040156.t141uaal004896@testing, relay=www-data@localhost
Feb 3 20:56:37 testing sm-mta[4901]: t141uack004901: from=www-data@testing, size=396, class=0, nrcpts=1, msgid=201502040156.t141uaal004896@testing, proto=ESMTP, daemon=MTA-v4, relay=localhost [127.0.0.1]
Feb 3 20:56:37 testing sendmail[4896]: t141uaal004896: to=testing@gmail.com, ctladdr=www-data (33/33), delay=00:00:01, xdelay=00:00:01, mailer=relay, pri=30187, relay=[127.0.0.1] [127.0.0.1], dsn=2.0.0, stat=Sent (t141uack004901 Message accepted for delivery)
Feb 3 20:56:37 testing sm-mta[4903]: STARTTLS=client, relay=gmail-smtp-in.l.google.com., version=TLSv1/SSLv3, verify=FAIL, cipher=ECDHE-RSA-AES128-GCM-SHA256, bits=128/128
Feb 3 20:56:38 testing sm-mta[4903]: t141uack004901: to=testing@gmail.com, ctladdr=www-data@testing (33/33), delay=00:00:02, xdelay=00:00:01, mailer=esmtp, pri=120396, relay=gmail-smtp-in.l.google.com. [74.125.69.27], dsn=2.0.0, stat=Sent (OK 1423014998 p13s$
Feb 3 20:56:52 testing sendmail[4899]: unable to qualify my own domain name (testing) – using short name
Feb 3 20:56:52 testing sendmail[4899]: t141uq3A004899: from=www-data, size=187, class=0, nrcpts=1, msgid=201502040156.t141uq3A004899@testing, relay=www-data@localhost
Feb 3 20:56:52 testing sm-mta[4904]: t141uqbX004904: from=www-data@testing, size=396, class=0, nrcpts=1, msgid=201502040156.t141uq3A004899@testing, proto=ESMTP, daemon=MTA-v4, relay=localhost [127.0.0.1]
Feb 3 20:56:52 testing sendmail[4899]: t141uq3A004899: to=testing@gmail.com, ctladdr=www-data (33/33), delay=00:00:00, xdelay=00:00:00, mailer=relay, pri=30187, relay=[127.0.0.1] [127.0.0.1], dsn=2.0.0, stat=Sent (t141uqbX004904 Message accepted for delivery)
Feb 3 20:56:53 testing sm-mta[4906]: STARTTLS=client, relay=gmail-smtp-in.l.google.com., version=TLSv1/SSLv3, verify=FAIL, cipher=ECDHE-RSA-AES128-GCM-SHA256, bits=128/128
Feb 3 20:56:53 testing sm-mta[4906]: t141uqbX004904: to=testing@gmail.com, ctladdr=www-data@testing (33/33), delay=00:00:01, xdelay=00:00:01, mailer=esmtp, pri=120396, relay=gmail-smtp-in.l.google.com. [74.125.69.26], dsn=2.0.0, stat=Sent (OK 1423015013 e6si$

I would love some insight as even though I can create droplet after droplet and I can reproduce this every time Tech support claims they are unable to reproduce the issue.

Also the failure is so silent I have wondered if it is a more widespread issue just so new no one has noticed.

These answers are provided by our Community. If you find them useful, show some love by clicking the heart. If you run into issues leave a comment, or add your own answer to help others.

×
3 answers

Try sending an e-mail in accordance with the RFCs (valid hostname, valid headers, FQDN as RDNS, etc.)

I do not know anything about email setup or the RFC’s around email.

However, that should not matter.

If sendmail on 14.04 works on NYC1 with a standard install and using standard PHP then it should work on NYC3

Also gitlab is most likely RFC compliant as a company creates it and it was also having the same failing issue on NYC3 but working on NYC1

Hello,

I have the same problem. Did you find any solution??

Thanks!

Submit an Answer