Github push 443问题记录
1、背景:
- MacOS系统
- 使用switchhosts组件,引入Github的hosts配置。此时github页面能够访问,ping畅通
- 除以上配置,电脑无其他代理
#无代理
chen@004:~$ git config --global http.proxy
chen@004:~$ git config --global https.proxy
chen@004:~$
140.82.113.25 alive.github.com
140.82.114.26 live.github.com
185.199.108.154 github.githubassets.com
140.82.112.21 central.github.com
185.199.108.133 desktop.githubusercontent.com
185.199.108.153 assets-cdn.github.com
185.199.108.133 camo.githubusercontent.com
185.199.108.133 github.map.fastly.net
199.232.69.194 github.global.ssl.fastly.net
140.82.114.4 gist.github.com
185.199.108.153 github.io
140.82.113.3 github.com
192.0.66.2 github.blog
140.82.113.5 api.github.com
185.199.108.133 raw.githubusercontent.com
185.199.108.133 user-images.githubusercontent.com
185.199.108.133 favicons.githubusercontent.com
185.199.108.133 avatars5.githubusercontent.com
185.199.108.133 avatars4.githubusercontent.com
185.199.108.133 avatars3.githubusercontent.com
185.199.108.133 avatars2.githubusercontent.com
185.199.108.133 avatars1.githubusercontent.com
185.199.108.133 avatars0.githubusercontent.com
185.199.108.133 avatars.githubusercontent.com
140.82.114.9 codeload.github.com
52.216.154.212 github-cloud.s3.amazonaws.com
52.216.139.27 github-com.s3.amazonaws.com
54.231.201.121 github-production-release-asset-2e65be.s3.amazonaws.com
52.217.160.249 github-production-user-asset-6210df.s3.amazonaws.com
52.217.160.249 github-production-repository-file-5c1aeb.s3.amazonaws.com
185.199.108.153 githubstatus.com
64.71.144.202 github.community
23.100.27.125 github.dev
185.199.108.133 media.githubusercontent.com
185.199.108.133 cloud.githubusercontent.com
185.199.108.133 objects.githubusercontent.com
2、问题描述
- 此时通过命令行git push向仓库提交代码,出现443超时提示
- 此时ping github.com 和github.io均通畅,页面也还是能够访问的情况
chen@004:~/files/gitFile/clairechen.github.io$ git push
fatal: unable to access 'https://github.com/CzyerChen/clairechen.github.io.git/': LibreSSL SSL_connect: SSL_ERROR_SYSCALL in connection to github.com:443
3、如何解决
- 由于我的情况不存在系统级别的代理,如果有网络上的意见是取消代理、刷新DNS
#这种情况我这边的情况并不适应
git config --global --unset http.proxy
git config --global --unset https.proxy
- 将switchhosts的配置关闭,如果手动的话,就是手动修改/etc/hosts中内容,将github相关代理部分注释掉
- 此时重新push后,网络稍稳定的情况下就能成功(如果网络着实差,那可能还是443的)
- 并不清楚其中原理,如有了解的,欢迎分享赐教