解决:no matching key exchange method found. Their offer: diffie-hellman-group1-sha1

来源:csdn博客 分类: 文章浏览史 发布时间:2021-01-07 20:23:10 最后更新:2021-01-07 浏览:3706
转载声明:
本文为摘录自“csdn博客”,版权归原作者所有。
温馨提示:
为了更好的体验,请点击原文链接进行浏览
摘录时间:
2021-01-07 20:23:10

第一种方法,在当前用户的.ssh目录下新建config文件,如当前用户为root

vi  ~/.ssh/config
Host *
KexAlgorithms +diffie-hellman-group1-sha1

此方法只对当前用户生效,使用其他用户是又会报错。

 

第二种方法,修改/etc/ssh/ssh_config文件,在最末尾加入即可。

KexAlgorithms +diffie-hellman-group1-sha1

 

php技术微信