Go Back   HowtoForge Forums | HowtoForge - Linux Howtos and Tutorials > Linux Forums > Server Operation

Do you like HowtoForge? Please consider supporting us by becoming a subscriber.
Thread Tools Display Modes
Old 16th December 2008, 18:37
malco23 malco23 is offline
Junior Member
Join Date: Dec 2008
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Default New to Linux/RedHat, struggling with sendmail

After searching the forums and other places on the web and trying various suggestions that I read for others, I have decided to post my problem, having had no luck in fixing it on my own so far.

I have a new web server running redhat enterprise 5.0. I'm using Drupal CMS, not that it matters, but I noticed the mail function was not working, so I started investigating. We host our own server, and use an external DNS for the web. The server name is testwebserver.lr.edu, and is registered with our external DNS. Port 25 is open. Using the following script and substituting a variety of email addresses, I get a browser message saying "Message successfully sent!" although no mail is being received on the other end:

$to = "anyname@domain.com";
$subject = "Hi!";
$body = "Hi,\n\nHow are you?";
if (mail($to, $subject, $body)) {
echo("<p>Message successfully sent!</p>");
} else {
echo("<p>Message delivery failed...</p>");

The printout out from my maillog says:

Dec 16 11:54:44 testwebserver sendmail[29224]: mBGGsiKM029224: to=malco@pobox.com, ctladdr=apache (48/48), delay=00:00:00, xdelay=00:00:00, mailer=relay, pri=30523, relay=[] [], dsn=2.0.0, stat=Sent (mBGGsigB029225 Message accepted for delivery)
Dec 16 11:54:44 testwebserver sendmail[29227]: mBGGsigB029225: to=<malco@pobox.com>, ctladdr=<apache@testwebserver.lr.edu> (48/48), delay=00:00:00, xdelay=00:00:00, mailer=esmtp, pri=120728, relay=mx-pa-11.pobox.com. [], dsn=4.0.0, stat=Deferred: Connection refused by mx-pa-11.pobox.com.
Dec 16 11:54:44 testwebserver sendmail[29223]: mBGGsi25029221: to=<malco@pobox.com>, ctladdr=<apache@testwebserver.lr.edu> (48/48), delay=00:00:00, xdelay=00:00:00, mailer=esmtp, pri=120597, relay=mx-pa-15.pobox.com. [], dsn=4.0.0, stat=Deferred: Connection refused by mx-pa-15.pobox.com.
Dec 16 11:56:44 testwebserver sendmail[29219]: mBGGsdUt029217: to=<broyhill@lr.edu>, ctladdr=<apache@testwebserver.lr.edu> (48/48), delay=00:02:05, xdelay=00:02:00, mailer=esmtp, pri=120597, relay=lr.edu. [], dsn=4.0.0, stat=Deferred: Connection timed out with lr.edu.
Dec 16 12:13:58 testwebserver sendmail[29288]: mBGHDwQk029288: from=apache, size=56, class=0, nrcpts=1, msgid=<200812161713.mBGHDwQk029288@testwebserver.l r.edu>, relay=apache@localhost
Dec 16 12:13:59 testwebserver sendmail[29289]: mBGHDxdg029289: from=<apache@testwebserver.lr.edu>, size=334, class=0, nrcpts=1, msgid=<200812161713.mBGHDwQk029288@testwebserver.l r.edu>, proto=ESMTP, daemon=MTA, relay=testwebserver.lr.edu []
Dec 16 12:13:59 testwebserver sendmail[29288]: mBGHDwQk029288: to=broyhillg@gmail.com, ctladdr=apache (48/48), delay=00:00:01, xdelay=00:00:00, mailer=relay, pri=30056, relay=[] [], dsn=2.0.0, stat=Sent (mBGHDxdg029289 Message accepted for delivery)
Dec 16 12:13:59 testwebserver sendmail[29291]: mBGHDxdg029289: to=<broyhillg@gmail.com>, ctladdr=<apache@testwebserver.lr.edu> (48/48), delay=00:00:00, xdelay=00:00:00, mailer=esmtp, pri=120334, relay=gsmtp147.google.com. [], dsn=4.0.0, stat=Deferred: Connection refused by gsmtp147.google.com.

Also, the printout from my mailq reveals:

-----Q-ID----- --Size-- -----Q-Time----- ------------Sender/Recipient-----------
mBGGo7S4029181 8 Tue Dec 16 11:50 <root@testwebserver.lr.edu>
(Deferred: Connection refused by gsmtp147.google.com.)
mBGHDxdg029289 18 Tue Dec 16 12:13 <apache@testwebserver.lr.edu>
(Deferred: Connection refused by gsmtp147.google.com.)
mBGHFCUu029296 18 Tue Dec 16 12:15 <apache@testwebserver.lr.edu>
(Deferred: Connection refused by gsmtp147.google.com.)
mBGGsi25029221 92 Tue Dec 16 11:54 <apache@testwebserver.lr.edu>
(Deferred: Connection refused by mx-pa-15.pobox.com.)
mBGGsdUt029217 92 Tue Dec 16 11:54 <apache@testwebserver.lr.edu>
(Deferred: Connection timed out with lr.edu.)
mBGGqECC029193 97 Tue Dec 16 11:52 <apache@testwebserver.lr.edu>
(Deferred: Connection refused by aspmx2.googlemail.com.)
mBGGsigB029225 223 Tue Dec 16 11:54 <apache@testwebserver.lr.edu>
(Deferred: Connection refused by mx-pa-11.pobox.com.)
Total requests: 7

OK -- where do I go from here? Many thanks. I am learning Linux the hard way, i.e., bought a book and teaching myself along with Google. No one in my company has a clue about this, including our server admin!!

thanks again
Reply With Quote
Sponsored Links
Old 17th December 2008, 03:37
marpada marpada is offline
Senior Member
Join Date: Sep 2008
Posts: 139
Thanks: 2
Thanked 14 Times in 14 Posts

First make sure that you don't have outgoing port 25 filetered by telneting remove mail servers to port 25, i.e.

$ telnet mx-pa-11.pobox.com 25
$ telnet gsmtp147.google.com 25

Also check that your IP isn't in a black list and has a reverse DNS record:

Green crack

Last edited by marpada; 13th May 2011 at 02:59.
Reply With Quote


redhat, sendmail

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Sendmail Problem hiren_patel Installation/Configuration 13 7th January 2009 09:58
One Feature i need to know how to do in postfix to move from sendmail ZeroDni Server Operation 0 26th October 2007 22:03
Sendmail: "Relaying denied. Proper authentication required." oskare100 Server Operation 0 2nd October 2007 18:31
I by accident let webmin install sendmail ...? comedit Installation/Configuration 6 2nd June 2006 16:30
sendmail 8.13.6 on FC2 server with SASL/STARTTLS Anne H Server Operation 5 4th April 2006 22:19

All times are GMT +2. The time now is 06:49.

Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2014, vBulletin Solutions, Inc.