ssh: connect to host github.com port 22: Connection timed out

版权声明:本文为博主原创文章,未经博主允许不得转载。 https://blog.csdn.net/linton1/article/details/90141555

git连接超时处理:

1. 首先找到git的安装目录,找到/etc/ssh/ssh_config文件

2. 用notpad++打开,在文件末,加入:

Host github.com
User git
Hostname ssh.github.com
PreferredAuthentications publickey
IdentityFile ~/.ssh/id_rsa
Port 443

3. ssh -T [email protected]来测试git是否成功连接github

猜你喜欢

转载自blog.csdn.net/linton1/article/details/90141555