git克隆失败提示RPC failed的解决方法

现象

bash 复制代码
$ git clone https://github.com/guillemj/dpkg.git
Cloning into 'dpkg'...
remote: Enumerating objects: 113312, done.
remote: Counting objects: 100% (18045/18045), done.
remote: Compressing objects: 100% (3915/3915), done.
error: RPC failed; curl 18 transfer closed with outstanding read data remaining
fatal: The remote end hung up unexpectedly
fatal: early EOF
fatal: index-pack failed

关键字:git, error, RPC failed, curl 18 transfer closed with outstanding read data remaining

git pull也会遇到同样的错误,解决方法相同。

原因

git的postBuffer设置小于下载仓库所需。

解决方法

在Git Bash中执行:

bash 复制代码
git config --global http.postBuffer 524288000
git config --global https.postBuffer 524288000

其中524288000的单位是字节,相当于500MB。如果修改之后还是报相同的错误可以尝试继续增大。

参考资料:

git pull 报错:git - error: RPC failed; curl 18 transfer closed with outstanding read data remaining 解决_git pull error: rpc failed; curl 18 transfer close-CSDN博客https://blog.csdn.net/LJFPHP/article/details/77702476error: RPC failed; curl 18 transfer closed with outstanding read data remaining-CSDN博客https://blog.csdn.net/weixin_38382857/article/details/88102705

相关推荐
权咚11 小时前
阿权的开发经验小集
git·ios·xcode
nightunderblackcat1 天前
新手向:Git下载全攻略
git
若无_2 天前
了解 .husky:前端项目中的 Git Hooks 工具
前端·git
想当花匠的小码农2 天前
Git 仓库“减肥”指南:从检测、清理到同步的全流程实践
git
R_.L2 天前
Git : 基本操作
git
python_1362 天前
git常见冲突场景及解决办法
git
洛小豆3 天前
Git 打标签完全指南:从本地创建到远端推送
前端·git·github
王道长服务器 | 亚马逊云3 天前
一个迁移案例:从传统 IDC 到 AWS 的真实对比
java·spring boot·git·云计算·github·dubbo·aws
嘟嘟可在哪里。3 天前
IntelliJ IDEA git凭据帮助程序
java·git·intellij-idea