This article introduces the failure of using git to clone the project on github, error error: RPC failed; curl 56 OpenSSL SSL_read: SSL_ERROR_SYSCALL, errno 10054, mainly including the failure of using git to clone the project on github, error error: RPC failed; curl 56 OpenSSL SSL_read: SSL_ERROR_SYSCALL, errno 1 0054 usage examples, application skills, summary of basic knowledge points and precautions are of certain reference value, friends who need it can refer to it.
wrong description
When using git clone on github today for a certain project code, git clone https://github.com/XXXX/xxx-blog.git The download speed is very slow, and after a period of time after downloading, the following error message is always prompted:
remote: Enumerating objects: 33, done.
remote: Counting objects: 100% (33/33), done.
remote: Compressing objects: 100% (8/8), done.
error: RPC failed; curl 56 OpenSSL SSL_read: SSL_ERROR_SYSCALL, errno 10054
fatal: the remote end hung up unexpectedly
fatal: early EOF
fatal: index-pack failed
wrong reason
Due to an error in the Http protocol, when pulling or cloning, or a certain CDN of github is blocked by a great wall.
Solution 1
protocol error
Execute the following command first
git config --global http.postBuffer 524288000
git pull
Execute or git clone
command again
Solution 2
wall shield
- Visit http://github.global.ssl.fast... to get the cdn domain name and IP address
- Visit http://github.com.ipaddress.c... to get the cdn domain name and IP address
Modify the hosts file
Add the IP address obtained above to the hosts file,
Mac is /etc/hosts
in;
windows is C:\Windows\System32\drivers\etc\hosts
in;
# fix git clone github project failed
140.82.113.3 github.com
199.232.5.194 github.global.ssl.fastly.net
flush DNS cache
Mac flushes DNS cache
sudo killall -HUP mDNSResponder
sudo dscacheutil -flushcache
Windows update DNS cache
cmd command window execution:
ipconfig /flushdns
Make the added mapping take effect.
Original address: https://www.cnblogs.com/mmzs/p/12039888.html