合 使用ssh连接报错:Key exchange failed. No compatible key exchange method.
Tags: LinuxOSssh连接问题Key exchange failed
现象
用SecureCRT 6.6.1连接报错:
Key exchange failed.
No compatible key exchange method. The server supports these methods: curve25519-sha256,curve25519-sha256@libssh.org,ecdh-sha2-nistp256,ecdh-sha2-nistp384,ecdh-sha2-nistp521,diffie-hellman-group-exchange-sha256,diffie-hellman-group16-sha512,diffie-hellman-group18-sha512,diffie-hellman-group14-sha256
No compatible hostkey. The server supports these methods: rsa-sha2-512,rsa-sha2-256,ecdsa-sha2-nistp256,ssh-ed25519
用Xshell 4连接报错:
解决
在/etc/ssh/sshd_config
文件中添加