不清楚是什么问题,电脑几个月前还可以和gitlab链接,提交代码。
突然不行了。
折腾了各种手段,进入~/.ssh 不断的生成ssh key。修改.config等等。
后来直接删除了~/.ssh , 再重新生成~/.ssh 还是不行。
进入~/.ssh后发现,没有.config
上google搜索了好久。
大多数是教导人,如何生成ssh key , 以及加上配置的基础。
直到我看到这个。
Sign_and_send_pubkey: no mutual signature supported
When I updated my Mac system, all the ssh server can’t ssh with the private key, you can add the 3 lines below in the beginning of your /etc/.ssh/config. But the best solution is create a new private key and upload the public key to each server one by one, because when you got this error, means your private key is deprecated to use.
# vim ~/.ssh/config, add the lines at the beginning
Host *
PubkeyAcceptedKeyTypes=+ssh-rsa
HostKeyAlgorithms=+ssh-rsa
之前还是知其然,不知其所以然,其实现在也不知道。
先保证能用吧。
Leave a Reply