Git 推送错误:RPC 失败:curl 52
声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow
原文地址: http://stackoverflow.com/questions/37085184/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me):
StackOverFlow
Git push error: RPC failed: curl 52
提问by sulimo
git push fails with following error
git push 失败并出现以下错误
fatal: RPC failed: curl 52: Empty reply from server
The upload succeeds in case only one file was modified, added or deleted.
如果只有一个文件被修改、添加或删除,则上传成功。
The following settings to don't work reliably
以下设置不能可靠地工作
git config --global --add core.compression -1
The git version is 2.8.2 running on ubuntu 14.04, and I have tried with both openssl and gnutls compilations.
git 版本是在 ubuntu 14.04 上运行的 2.8.2,我已经尝试过 openssl 和 gnutls 编译。
ssh remotes also fail.
ssh 遥控器也失败。
The problem is encountered with repositories of
问题是在存储库中遇到的
bitbucket
github
gitlab
Fail safe answers appreciated
故障安全答案赞赏
回答by Eduardo Oliveros
In terminal use sudo to clone, or type:
在终端中使用 sudo 进行克隆,或输入:
git config --global http.postBuffer 157286400
its worked for me
它对我有用
回答by f-society
Following worked for me.
以下对我来说有效。
git config --global core.compression 0
git clone --depth 1 <repo> // partial clone to truncate the amount of info coming down
#cd repo // go into the new directory and
git fetch --unshallow //retrieve the rest of the clone
git pull --all //final pull
Hope, this could be helpful for someone having the same issue.
希望,这对有同样问题的人有帮助。
回答by Dado
I had a chat with Gideon @ atlassian he suggested to use SSH over HTTPS to fix the "curl 52" error.
我与 Gideon @ atlassian 聊天,他建议通过 HTTPS 使用 SSH 来修复“curl 52”错误。
For me switching to SSH fixed the problem. Here's the complete answer:
对我来说,切换到 SSH 解决了这个问题。这是完整的答案:
This is a HTTP/HTTPS timeout issue involving either some large commit size, or a weak network. If you're cloning, can you try to see if you can clone the repository using this method:
https://stackoverflow.com/a/22317479
Can you try to see if running this command before any git operations help as well:
git config --global http.postBuffer 524288000
Also, this issue usually won't occur in SSH; so maybe it is worth trying to set up SSH and then do the operation through SSH:
https://confluence.atlassian.com/bitbucket/set-up-ssh-for-git-728138079.html
这是一个 HTTP/HTTPS 超时问题,涉及一些大的提交大小或弱网络。如果你在克隆,你可以尝试看看你是否可以使用这种方法克隆存储库:
https://stackoverflow.com/a/22317479
您能否尝试在任何 git 操作之前运行此命令也有帮助:
git config --global http.postBuffer 524288000
此外,这个问题通常不会在 SSH 中发生;所以也许值得尝试设置 SSH,然后通过 SSH 进行操作:
https://confluence.atlassian.com/bitbucket/set-up-ssh-for-git-728138079.html
回答by user8415640
Following worked for me. stop WIFI and use the Network cable to connect the NetWork
以下对我来说有效。停止WIFI并使用网线连接网络
Maybe it is a problem about network
可能是网络问题
回答by Fares Ben Hamouda
Appearently it's a problem with HTTPS problem. Switching to SSH fix the problem with all repositories.
显然这是HTTPS问题的问题。切换到 SSH 可以解决所有存储库的问题。
回答by Usern4me
I have the same problem on arch linux, git version 2.8.2, can't push to bitbucket repo. Cloning and pull works.
我在 arch linux 上遇到了同样的问题,git 版本 2.8.2,无法推送到 bitbucket 存储库。克隆和拉动作品。