Ask Ubuntu is a question and answer site for Ubuntu users and developers. Join them; it only takes a minute:

Sign up
Here's how it works:
  1. Anybody can ask a question
  2. Anybody can answer
  3. The best answers are voted up and rise to the top

I have a vps running Ubuntu 12.04 LTS and I have installed openSSH but I can't connect to it with putty. I get error saying Network error:Connection timed out. How to fix this?

share|improve this question

Telnet to port 22 of your VPS. If sshd is accepting connections, you should see something similar to the following:

$ telnet 22
Connected to
Escape character is '^]'.

Protocol mismatch.
Connection closed by foreign host.

If you aren't getting that response from the vps, you may have a firewall blocking the port, or a configuration problem in /etc/ssh/sshd_config.

  • man sshd_config explains how that file file works
share|improve this answer

Your Answer


By posting your answer, you agree to the privacy policy and terms of service.

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