I just installed Cygwin, and openssh ignores the known_hosts file. My guess is that openssh does not even see the ~/.ssh folder. I've defined a Windows environment variable HOME, and Cygwin does start in %HOME%. The permissions on ~/.ssh are 600, and permissions inside ~/.ssh are 600 for everything except that known_hosts and *.pub are 644. All i get is

$ ssh -vvv -Y foo
OpenSSH_6.1p1, OpenSSL 1.0.1c 10 May 2012
debug2: ssh_connect: needpriv 0
ssh: Could not resolve hostname learnlab: hostname nor servname provided, or not known

Note that I don't have the line debug1: Reading configuration data /etc/ssh/ssh_config, and what's even odder, Cygwin doesn't install /etc/ssh.


It turned out I had to not only set %HOME%, but also to create a mount point for /home/myhome.

$ cat /etc/fstab.d/myhome 
c:/Users/myhome/My\040Documents /home/myhome    ntfs    binary  0       0

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.