Linux - NetworkingThis forum is for any issue related to networks or networking.
Routing, network cards, OSI, etc. Anything is fair game.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
Distribution: Fedora, Debian, OpenSuSE and Android
Posts: 1,820
Rep:
telnet to port 25 connects but without reply?
I know, I know, telnet isn't secure. I am just using it to test connectivity to my recently configured mail server. When I telnet to it I get the following..
> telnet <mailsvr-ip> 25
connected to <mailsvr-ip>
Escape character is [^
And nothing else...
It should respond with something like
Postfix version blah blah etc etc
I checked the server, port 25 is open and postfix is running.
Anyone know why it would let me telnet to it without any reply?
Originally posted by Pcghost > It should respond with something like
Postfix version blah blah etc etc
Why would it respond like that? You are using the telnet protocol on an smtp port. In my experience the "Escape character is [^" means that the port is open and you are connected to it. If you type a few things, it doesn't matter what you type, you should get a connection closed message because again you are using the telnet protocol.
What are you trying to accomplish by telnetting into the smtp port?
Distribution: Fedora, Debian, OpenSuSE and Android
Posts: 1,820
Original Poster
Rep:
When I telneted to port 25 on my domino server it would reply with
Lotus Domino R5.0.5 on raptor status up etc etc
I figured it would do the same with postfix. I am trying to test the postfix installation/configuration. The mx records on the internet have yet to update so sending mail to my domain doesn't use this server, it uses our old mail server.
What is the best way to test a mail servers forwarding? I cant use the ip address in the to: field right?
Distribution: Fedora, Debian, OpenSuSE and Android
Posts: 1,820
Original Poster
Rep:
Can anyone tell me which of the settings in main.cf sets up forwarding of all incoming mail to an internal server? I know they say it's easier than Sendmail, but I don't remember Sendmail giving me this much trouble..
Distribution: Fedora, Debian, OpenSuSE and Android
Posts: 1,820
Original Poster
Rep:
I found a HOWTO at redhat that has helped alot. I now have it setup but am fighting with the connectivity between our two mail servers. They keep rejecting the mail I forward to them as relaying. Sigh... It is easier than Sendmail in the design of the conf files..
No one has answered your question yet about telnetting to port 25. Yes you *can* test your smtp server like that. I do it all the time. You might want to turn on local_echo in your telent client first; I find that it helps to see what I'm typing. How to do that would depend on your telnet client - try "set localecho" or "set local_echo" at the telnet cmd prompt. Then "open ip.addr.xxx.xxx 25". You may not see any response yet. Type "HELO testdomain.com" and you should see a response. Then "MAIL FROM: me@otherdomain.com" should get you another Ok response. Then "RCPT TO: myuser@mydomain.com" should give another Ok. Then "DATA" <cr> followed by "Subject: blah, blah" <cr> text of test message... <cr> and finally "." followed by a final <cr> should place the message in the queue for delivery. "QUIT" to end your telnet session and you're done. The message should be delivered by the time you quit.
As for all the other configuration issues, I find it much easier to use Webmin at least for the initial configuration. If you're not familiar with it, webmin is a browser based server configuration tool. It incorporates a built-in web server so you don't need to have Apache running. You do need to have X windows installed though.
I was wondering how you'd fixed your problem. I have the same. I installed postfix, a portscanner says that port 25 is open, I can telnet to port 25, but I can't see: blablabla postfix ...If I type helo me (enter) it does not respond.
If I go to the shell, and stop postix, the connection is lost. I am puzzled.
Distribution: OpenBSD 4.6, OS X 10.6.2, CentOS 4 & 5
Posts: 3,660
Rep:
See above regarding local echo.
By the way, you can telnet to ANY TCP application port, and if they're a simple cleartext protocol with no special negotiation (like SMTP, HTTP, etc) it will work! You just have to know what sequence to enter the commands in, what syntax to use, and if you want to have any clue what's going on, make sure you set local echo.
I've used telnet to complete entire SMTP transactions, verify that I can download the correct information from a web site, used it for proprietary provisioning protocols developed by a company I worked for, verify ssh banner (ssh requires complicated handshaking that is not possible for a human to mimic), etc.
nah, it is not the local echo. Cauz I am still a newbie, I forgot one thing: create an alias! I know stupid. Created the alias, logged in using telnet, and bingo, I saw the 220 postfix ...line. Thanks anyway!
Well, I edited the file /etc/postfix/aliases. Now I have webmin running, which is enableing me to easy administer postfix. Does this solve your problem?
you probably want the last one uncommented (as shown). My guess is the inet_interfaces=localhost is active (by default?). If so, you would be able to "telnet 127.0.0.1 25" or "telnet localhost 25" and get the expected results, while "telnet <hostname> 25" won't connect.
After making the change, "telnet <hostname> 25" will work as expected.
Don't forget to restart postfix (/etc/init.d/postfix restart) after the change is made. Good luck.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.