Super User is a question and answer site for computer enthusiasts and power users. 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 forgot how to do this and I found this other StackOverflow post about it but now I'm getting this error:

ssh: connect to host xx.xx.xx.xx port 22: Permission denied lost connection

I am pretty sure it has something to do with the permissions to the folder in which I want to write using chmod but I can't remember which ones do I need to change in the target computer.

share|improve this question

migrated from Jan 17 '12 at 6:28

This question came from our site for professional and enthusiast programmers.

Both that linked question and this one would be better suited for SuperUser since they have nothing to do specifically with programming. – paxdiablo Jan 17 '12 at 5:40
could someone please move the question then? – Proxify Jan 17 '12 at 5:41
You have to wait for the five close/move votes or a moderator. I'll hassle a mod. – paxdiablo Jan 17 '12 at 5:42

Looking at your error message, you are being denied access to that port on that IP address, before file permissions come into it. You need to check that:

  1. The IP address you are trying to reach is accessible
  2. The SSH server is running on that machine (Check in System Preferences -> Internet & Wireless -> Sharing that the 'remote login' option is checked)
  3. There is no firewall on that machine, your machine or on the router which is blocking you from getting to port 22.

If that is all OK and you are still not able to connect, then you can start checking file permissions.

share|improve this answer

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .