git clone 或者是vscode clone 时遇到the remote end hung up unexpectedly

复制代码
fatal: the remote end hung up unexpectedly
fatal: early EOF
fatal: index-pack failed

使用git clone总是报错

查看原因有三种可能:要么是缓存不够,要么是网络不行,要么墙的原因。

如果是网络不行,可以配置git的最低速度和最低速度时间:

复制代码
git config --global http.lowSpeedLimit 0
git config --global http.lowSpeedTime 999999

【补充】文件太大的解决方法:

当clone或者push git项目时,文件太大也会出现fatal: The remote end hung up unexpectedly

此时需要修改.gitconfig配置文件,打开终端,执行指令:

git config http.postBuffer 524288000

将postBuffer的缓存设置为500M即可。

参考 https://blog.csdn.net/Cai_deLong/article/details/115255735

相关推荐
Irene199110 小时前
查看是否已安装 Git 的方法
git
my_power52010 小时前
检出git项目到android studio该如何配置
android·git·android studio
安果移不动10 小时前
Git 实战:如何优雅地撤销历史中的某一个 Commit?
git
啥都不懂的小小白14 小时前
Git 入门指南:从零开始掌握版本控制
git
AI逐月14 小时前
Git 彻底清除历史记录
大数据·git·elasticsearch
有什么东东15 小时前
Windows安装git教程以及初步使用
git
不爱吃米饭_15 小时前
Gitea 轻量级的Git方案 - Gitlab的替代品
git·gitlab·gitea
CoderJia程序员甲18 小时前
GitHub 热榜项目 - 日榜(2025-12-15)
git·ai·开源·llm·github
大柏怎么被偷了18 小时前
【Git】远程操作
git
猪在黑魔纹里18 小时前
解决VSCode无法高亮、解析numpy中的部分接口(如pi、deg2rad)
ide·vscode·python·numpy