【Github】问题解决:Failed to connect to github.com port 443: Operation timed out

原文地址:https://juejin.cn/post/6844904193170341896

1. 打开https://github.com.ipaddress.com/ 如下图:
图1.png

把IP Address 记录下来! 把IP Address 记录下来! 把IP Address 记录下来!

2.打开https://fastly.net.ipaddress.com/github.global.ssl.fastly.net#ipinfo 如下图:
图2.png

把IP Address 记录下来! 把IP Address 记录下来! 把IP Address 记录下来!

3.打开https://github.com.ipaddress.com/assets-cdn.github.com 如下图:
图3.png

把IP Address 记录下来! 把IP Address 记录下来! 把IP Address 记录下来!

4.打开电脑的hosts文件,把下列的东东写在最后,然后保存即可
140.82.113.4(图1的IP Address) github.com 
199.232.69.194(图2的IP Address) github.global.ssl.fastly.net
185.199.108.153(图3的IP Address)  assets-cdn.github.com
185.199.109.153(图3的IP Address)  assets-cdn.github.com
185.199.110.153(图3的IP Address)  assets-cdn.github.com
185.199.111.153(图3的IP Address)  assets-cdn.github.com

效果如图:


5.在终端在输以下指令刷新DNS(需要权限)
sudo killall -HUP mDNSResponder;say DNS cache has been flushed

你可能感兴趣的:(【Github】问题解决:Failed to connect to github.com port 443: Operation timed out)