[CentOS] Sending Email Via Telnet
John Reddy
linuxpencil at hotmail.com
Tue Oct 16 17:46:45 UTC 2012
> > netstat -pant|grep ":25"|grep LISTEN
> > to see if any program is listening... output should look like:
> > tcp 0 0 0.0.0.0:25 0.0.0.0:* LISTEN 21493/sendmail
> >
> > guess it'll say 'postfix' or 'master' instead of 'sendmail' on RH6.
]# netstat -pant|grep ":25"|grep LISTEN
tcp 0 0 209.216.9.56:25 0.0.0.0:* LISTEN 14058/master
tcp 0 0 127.0.0.1:25 0.0.0.0:* LISTEN 14058/master
>
> How long are you waiting for a response to appear? Mailers do an
> assortment of reverse-dns lookups and perhaps an ident query to the
> source before responding. If you firewall these with a 'drop'
> instead of 'reject' you leave the application hanging for fairly long
> timeout. And some mailers have a config option for an intentional
> delay before their first message and will drop the connection it the
> other end sends first (snmp protocol requires the connecting host to
> wait). Also, you should have something showing up in
> /var/log/mailllog about the connections.
I can't find anything in there that corresponds to the attempt to send an email. And why would I when there is no communication from the server in my telnet session? The problem appears to be in telnet, not in postfix. Again, this is one of 3 examples of my telnet sessions from 2 emails ago:
[root at mydomain john]# telnet 127.0.0.1 25
Trying 127.0.0.1...
Connected to 127.0.0.1.
Escape character is '^]'.
HELO justtesting
MAIL FROM: testing at gmail.com
RCPT TO: testing at gmail.com
DATA
To: testing at gmail.com
From: testing at gmail.com
Subject: testing
Date: Tu, Oct 2012 10:21:11 -0500
Testing
.
QUIT
Then it hangs. I never get back to a command prompt. There is never any interaction with the telnet program after the initial response. How do I trouble-shoot this?
TIA,
John
More information about the CentOS
mailing list