git clone代码时提示:no matching key exchange method found
2016-08-25 11:23
726 查看
最近接受一个新项目在使用git clone克隆代码时,遇到了如下错误:
Unable to negotiate with xxx.xxx.xxx.xxx: no matching key exchange method found. Their offer: diffie-hellman-group1-sha1
fatal: Could not read from remote repository.
从提示来看,这个应该是server的key exchange方法无法匹配导致的。而server支持的算法是:
所以此处需要在~/.ssh/config当中添加如下配置:
之后再次执行git clone命令就可以正常执行了。
Unable to negotiate with xxx.xxx.xxx.xxx: no matching key exchange method found. Their offer: diffie-hellman-group1-sha1
fatal: Could not read from remote repository.
从提示来看,这个应该是server的key exchange方法无法匹配导致的。而server支持的算法是:
diffie-hellman-group1-sha1。所以此处应该将client端的算法强制使用
diffie-hellman-group1-sha1。
所以此处需要在~/.ssh/config当中添加如下配置:
host xxx.xxx.xxx.xxx #服务器ip地址 KexAlgorithms diffie-hellman-group1-sha1 identityfile ~/.ssh/xxx.pub #如果不是默认的公钥,此处需要指定一下
之后再次执行git clone命令就可以正常执行了。
相关文章推荐
- git clone出现unbale to negotiate with 192.168.53.31 no matching key exchange method found
- git 配置SSH error: no matching key exchange method found. Their offer: diffie-hellman-group1-sha1
- git:no matching key exchange method found. Their offer: diffie-hellman-group1-sha1
- git出错"no matching key exchange method found"
- Git 常见问题: unable to negotiate with *.*.*.*: no matching key exchange methodfound...
- no matching key exchange method found
- 解决:no matching key exchange method found. Their offer: diffie-hellman-group1-sha1
- no matching key exchange method found. Their offer: diffie-hellman-group1-sha1
- repo init 报错:no matching key exchange method found. Their offer: diffie-hellman-group1-sha1
- 解决:no matching key exchange method found. Their offer: diffie-hellman-group1-sha1
- 更新macOS Sierra后,解决:no matching key exchange method found. Their offer: diffie-hellman-group1-sha1
- no matching key exchange method found. Their offer: diffie-hellman-group1-sha1
- Unable to negotiate with legacyhost: no matching key exchange method found.
- no matching key exchange method found. Their offer: diffie-hellman-group1-sha1
- 测试代码的报错java.lang.Exception: No tests found matching Method ***
- No valid signing identities (i.e. certificate and private key pair) matching the team ID “(null)” were found.
- 解决git 提交代码时提示空间不足:error: unpack failed: error No space left on device
- Git 解决同步 No value for key branch.master.merge found in
- eclipse git 报错:the current branch is not configured for pull No value for key branch.xxx.merge found
- 解决单元测试的No tests found matching Method