Get your server issues fixed by our experts for a price starting at just 25 USD/Hour. Click here to register and open a ticket with us now!

Author Topic: Unable to negotiate with xxx.xxx.xxx port 22: no matching host key type found.  (Read 112288 times)

0 Members and 1 Guest are viewing this topic.

mansoorm

  • Newbie
  • *
  • Posts: 3
  • Karma: +0/-0
If you receive the following error when connecting remote server via SSH.


Unable to negotiate with xxx.xxx.xxx port 22: no matching host key type found.
fatal: Could not read from remote repository.
Please make sure you have the correct access rights and the repository exists.

In this case, the client and server were unable to agree on the key exchange algorithm. As a workaround, you need to tell your ssh client that you want to accept DSA host keys,

Resolution:

Add following lines into your ~/.ssh/config

Host your-remote-host
    HostkeyAlgorithms +ssh-dss


OR

specify the following option below while connecting via SSH.

ssh -oHostKeyAlgorithms=+ssh-dss user@remotehost.com