###起因: 今天git clone 本地仓库时报ssh: connect to host localhost port 22: Connection refused
的错,记录解决办法。
方法来源:https://blog.csdn.net/bluecom24/article/details/39593793
开始的时候用apt update升级了一些系统依赖,之后用git的时候就报错了。
然后安重新用apt-get 安装了ssh相关的就好了。
openssh-server 相互依赖 openssh-client
sudo apt-get install openssh-server
sudo apt-get install openssh-client