错误信息: unable to access OpenSSL SSL_read: Connection was reset, errno 10054
文章参考http://www.manongjc.com/detail/27-kyjhwjehuruukpv.html 此篇文章用于记录
总结原因如下:
1 网络问题 用下面的代码去验证能否ping通
ping github.com
2 用户名和邮箱问题:(查看和更改)
git config user.name
git config user.email
git config --global user.name "xxx"
git config --global user.email "xxx"
3 解除SSL验证:执行之后要重启
git config --global http.sslVerify "false"
如果还是报错:
fatal: not in a git directory
那么执行
git init
再次输入:
git config http.sslVerify "false"
4 文件太大:扩大缓冲区(这里大小约为512MB)
git config http.postBuffer 5242880003
5 DNS缓冲区:
ipconfig /flushdns
6 host设置错误:
第一步,在https://www.ipaddress.com/上查询github.com的域名。
第二步,找到C:\Windows\System32\drivers\etc中的host文件,用记事本打开,加一行 [域名] github.com
(不含方括号)。然后保存。
第三步,如果无效,试试重启电脑。