I'm trying to telnet to a port on an Ubuntu server from a Windows 7x64 machine. When I use Putty it gives me a "Connection closed by remote host" error. When I use the windows telnet client from the command prompt, I get a blank screen with a blinking cursor and no error. When I type anything and press ENTER the telnet client exits.

What is most likely:

  • Putty is lying and I actually can connect to the port
  • The command line client is just not good at giving feedback when it can't connect

EDIT: When I telnet to the port 22 (SSH) the remote host sends a message "SSH-2.0-OpenSSH_5...." - I guess if the other port I'm attempting to reach were open it would say something? I'd love someone to confirm.

link|improve this question
feedback

migrated from serverfault.com Aug 14 '11 at 19:17

This question came from our site for system administrators and desktop support professionals.

2 Answers

up vote 1 down vote accepted

The remote host is closing the connection as soon as it gets any traffic through the stream, otherwise PuTTY would be reporting "connection refused."

This tends to be an issue with a firewall of some sort, but can also indicate issues with the listening service.

What service is it that you are connecting to?

link|improve this answer
It was port 631 for CUPS, but I think you've given me the info I need. – Fritz Meissner Aug 14 '11 at 18:51
feedback

To find out for sure, run Wireshark on your Windows machine during the connections.

link|improve this answer
feedback

Your Answer

 
or
required, but never shown

Not the answer you're looking for? Browse other questions tagged or ask your own question.