異常問題:
下班之前升級了一下Git的版本,結果第二天過來拉取遠端最新程式碼的時候就提示了下面的異常問題:
Unable to negotiate with xx.xxx.xxxx port 22: no matching host key type found. Their offer: ssh-rsa Git failed with a fatal error. Git failed with a fatal error. Could not read from remote repository. Please make sure you have the correct access rights and the repository exists.
問題分析:
1、修改原生程式碼關聯的遠端地址
git remote set-url origin https://gitee.com/ysgdaydayup/pingrixuexilianxi.git
2、重新拉取成功
git pulll
解決方案二、在.ssh檔案中建立config檔案並新增配置
Host * HostkeyAlgorithms +ssh-rsa PubkeyAcceptedKeyTypes +ssh-rsa