LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Enterprise (https://www.linuxquestions.org/questions/linux-enterprise-47/)
-   -   Sendmail - External email getting connection refused (https://www.linuxquestions.org/questions/linux-enterprise-47/sendmail-external-email-getting-connection-refused-4175514735/)

vorpel 08-13-2014 05:20 PM

Sendmail - External email getting connection refused
 
Hello. I am trying to send an email message outside of my company from my Oracle Linux Database server (REL 5.10). The server is configured to use Sendmail, and I can get email to deliver internally (corp network).

When I try and send an email to Gmail, Yahoo or AT&T (for getting pages on my cellphone) I get a connection refused error.

Here is the output from /var/log/maillog for trying to send to a Gmail address:

Aug 13 15:58:11 blanked_hostname sendmail[18423]: s7DLwBeV018423: from=oracle, size=57, class=0, nrcpts=1, msgid=<201408132158.s7DLwBeV018423@blanked_hostname.xxxx.xx.xx>, relay=oracle@localhost
Aug 13 15:58:12 blanked_hostname sendmail[18428]: s7DLwBd3018428: from=<oracle@blanked_hostname.xxxx.xx.xx>, size=382, class=0, nrcpts=1, msgid=<201408132158.s7DLwBeV018423@blanked_hostname.xxxx.xx.xx>, proto=ESMTP, daemon=MTA, relay=localhost.localdomain [127.0.0.1]
Aug 13 15:58:12 blanked_hostname sendmail[18423]: s7DLwBeV018423: to=destination_email@gmail.com, ctladdr=oracle (505/507), delay=00:00:01, xdelay=00:00:01, mailer=relay, pri=30057, relay=[127.0.0.1] [127.0.0.1], dsn=2.0.0, stat=Sent (s7DLwBd3018428 Message accepted for delivery)
Aug 13 15:58:12 blanked_hostname sendmail[18430]: s7DLwBd3018428: to=<destination_email@gmail.com>, ctladdr=<oracle@blanked_hostname.xxxx.xx.xx>, (505/507), delay=00:00:01, xdelay=00:00:00, mailer=esmtp, pri=120382, relay=alt4.gmail-smtp-in.l.google.com. [74.125.131.27], dsn=4.0.0, stat=Deferred: Connection refused by alt4.gmail-smtp-in.l.google.com.

I am able to connect to Gmail via telnet. Here's the output:

DBNAME 15:14:46 $ telnet smtp.gmail.com 465
Trying 74.125.25.109...
Connected to smtp.gmail.com (74.125.25.109).
Escape character is '^]'.


Connection closed by foreign host.

This is happening on both of my Oracle Linux Database servers, however my AIX 6.1 Database servers are able to send email externally.

Any advice on where to go from here?

Thanks.

ceyx 08-14-2014 02:03 AM

Quote:

relay=localhost.localdomain [127.0.0.1]
Seems to me the relay is setup improperly. I could be reading it incorrectly though ?
Check the logs of the successful Database servers, find out what the relay is and copy it into the sendmail config file.

vorpel 08-14-2014 10:45 AM

Thanks for the reply. In comparing the AIX server's sendmail.cf with the REL server's sendmail.cf, I found that the "Smart relay" on AIX did have the prod mail server listed, while the REL server did not (just "DS").

I've asked the SA to please change this on the development box, bounce sendmail and we'll give it a try.

I really appreciate the pointer of where to look. I was getting fooled by the fact that the email was getting a connection refused by the Gmail smtp server - made me think that it was able to negotiate outside of the local network and that my issue would be elsewhere. Definitely need to learn more about this!

-DC

vorpel 08-19-2014 09:03 AM

Issue resolved - SA fixed the relay setup.

Thanks again for the help!

ceyx 08-19-2014 10:57 AM

Glad to be able to help !

:)


All times are GMT -5. The time now is 07:44 AM.