After doing as above, I always got this:
total 22
drwxrwxr-x+ 1 jl None 0 Sep 9 18:44 .
drwxrwxr-x+ 1 jl None 0 Sep 9 18:44 ..
-rw-rw---- 1 jl None 129 Jul 1 14:30 config
and the error on .ssh/config
. So I've run chown
on the .ssh
folder, and chmod
again like this:
> chown -R [USERNAME]:users .ssh/
and then:
> chmod -R 600 .ssh/
and finally I got it working:
total 29
drwxrwxr-x+ 1 jl None 0 Sep 9 18:44 .
drwxrwxrwt+ 1 jl None 0 Sep 9 18:44 ..
drw-------+ 1 jl Users 0 Sep 9 18:44 .ssh
Edit(for bash on Windows10)
When you get the error..
Failed to add the host to the list of known hosts (/PATH_TO_HOME/USERNAME/.ssh/known_hosts).
Make sure that known_hosts is writable
$ chmod 755 known_hosts
Note: I believe you only need to set 600 for your private key
Then, try to ssh.
When you get..
Permanently added 'HOST_IP' (RSA) to the list of known hosts.
You may replace mode 600
$ chmod 600 known_hosts
P.S.: I think this is a bug on Windows 8.