修改自 https://blog.51cto.com/11887934/2051323

 

设置

查询域名global-ssl.fastly.Net github.com 公网地址;windos电脑上用ping或nslookup命令

查询命令见这里 https://blog.csdn.net/hzwwpgmwy/article/details/79043251

但是查了之后的地址没用,用原文的反而快

windows修改host文件: C:\Windows\System32\drivers\etc\hosts
linux 修改host文件: /etc/hosts   tab分割两列

151.101.72.249 github.global.ssl.fastly.net  
192.30.253.112 github.com

加快git clone 几十倍速度的小方法  (30KB vs 2M)

 

2、刷新DNS缓存 
linux:sudo /etc/init.d/networking restart

windows:ipconfig /flushdns

Logo

腾讯云面向开发者汇聚海量精品云计算使用和开发经验,营造开放的云计算技术生态圈。

更多推荐