今天拉github的仓库,报错:Connection reset by 18.141.90.153 port 443
参考: blog.csdn.net/natahew/art…
第一步:打开ipaddress.com,查询如下两个域名,并分别记录下其对应的ip:
1、github.com
2、github.global.ssl.fastly.net
查到结果,如下:
140.82.112.4 github.com
199.232.69.194 github.global.ssl.fastly.net
第二步:通过设置host文件解决,在文件C:\Windows\System32\drivers\etc\hosts里面增加如下配置:
# fix github 拉取项目报错: Connection reset by 18.141.90.153 port 443
140.82.112.4 github.com
199.232.69.194 github.global.ssl.fastly.net
然后 win+R 输入 cmd 打开命令行窗口输入:ipconfig /flushdns
(注意在vscode的终端输入可能会报错,使用上面的正规操作一定能成功!)
重新拉项目,可以成功!!oh yeah~~