2

I am using Windows 8 for connecting to the Linux server. It would connect fine few days back but now I can not connect to it using my computer. I can connect to that server with any other computer.

I have checked the ports those are not blocking in routers way or server hasn't block any port regarding ssh or telnet (22 port is wide open).

  • can ping the system from my computer
  • can access the system using any other computer
  • port 22 is open on that system
  • ssh or telnet both are not working from my system but I can ping that system

I do not know what I have done or installed, but its not working. How do I track down the problem ?

  • Start by checking firewall – hjpotter92 May 1 '14 at 5:41
  • i even disabled the firewall still its does the same thing – Waqas May 1 '14 at 5:50
  • 1
    Knowing some more details would be useful. Is the Linux box on your local network? Can you connect to that server using another computer on your local network? Can you ping that server using your computer? In other words, do two things: 1) draw out the connection that should exist between your computer and the Linux box, and pinpoint where it is that it isn't working, and 2) see if SSH is the only connection that's failing. – Pockets May 1 '14 at 8:45
  • @SamuelLijin check the question now i have added the bullets – Waqas May 1 '14 at 21:53
  • Same network? Same Switch? Any NAT between? Where are the pcs that are able to connect? – davidbaumann May 2 '14 at 5:52
1

My first attempt to solve this problem would be to

  • open PuTTY
  • select Session > Logging
  • enable logging of SSH output to a file
  • try to connect
  • review the logfile

What does the logfile say? Anything that points you into a specific direction? It could me messages ranging from "Connection timed out" to "Access denied".

Connection timed out:

Make sure you really have the correct IP address and TCP port given in PuTTY's session options. If you are using a hostname instead of the IP address, make sure that the hostname resolves to the correct IP address. Eventually also check c:\system32\drivers\etc\hosts

Do you administer the SSH server? If so, make sure that SSH really listens on port 22; if not, either change /etc/ssh/sshd_config on the server or adjust the port in PuTTY. Also check that iptables will let your client's IP address pass through.

If you do not administer the SSH server, get in touch with the administrator.

I personally like to install knockd on my SSH servers, so that I can only connect to them after knocking certain ports. Ask the administrator whether you have to do something like that.

Access Denied:

If you try to login as root, chances are, that this is forbidden in /etc/ssh/sshd_config on the server. Login with another / your username.

If you are using public key authentication, make sure that your private key

  • is in PuTTY's .ppk format
  • is entered in PuTTY's Connection > SSH > Auth section.

Also check whether the corresponding public key is in /home/yourusername/.ssh/authorized_keys. Make sure that there are no line breaks (I am using nano for that, and it sometimes adds linebreaks if I copy the key into it). A correct line should read like that, for instance for RSA: ssh-rsa ALOTOFCHARACTERS yourusername@hostname.

So. First step: enable logging and post the output here. ;)

  • That question was 2 years ago and I don't have the same environment now. But your answer seems helpful – Waqas Jun 9 '16 at 6:14
  • Yeah, I saw the date a tenth of a second after I pushed the button. Thanks for accepting. Thanks for still being here on superuser! :) – stueja Jun 9 '16 at 6:32
0

I was having a similar problem to yours recently. I found that this can be caused by a whole host of problems so I'll do my best to break it down.

Since you can connect via other computers, I am going to assume you have port forwarded correctly.

If you are trying to connect with your external IP from the same wifi as the server, I found that doesn't really work. Try connecting to it via someone else's wifi, or even the server's internal IP to see if that works.

Overall, try and think what is different between this computer and the others you've connected on. Best of luck.

0

I faced the similar issue. Reinstalling the putty and launching the putty session to the server was successful. Unsure about the Root cause of the issue.

Hope this helps for anyone who is facing the same issue.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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