【问题标题】:Gitlab Push Failed errorGitlab推送失败错误
【发布时间】:2016-08-24 17:42:55
【问题描述】:

当我尝试将任何内容推送到我自己的 gitlab 服务器时,我不断收到此错误:

Push failed
Failed with error:
fatal: The remote end hung up unexpectedly
fatal: The remote end hung up unexpectedly
error: RPC failed;
curl 56 Recv failure: Connection was reset

我不知道为什么我不断收到此错误。我一直在尝试推动,然后它突然成功地推动了它。但在那之后我试图推动的一切都给了我同样的错误。

这是更详细的日志:

16:21:39.932: [gallery] git -c core.quotepath=false push --progress --porcelain origin refs/heads/master:master
Counting objects: 12, done.
Delta compression using up to 8 threads.
Compressing objects: 100% (12/12), done.
Writing objects: 100% (12/12), 1.88 MiB | 25.00 KiB/s, done.
Total 12 (delta 3), reused 0 (delta 0)
fatal: The remote end hung up unexpectedly
fatal: The remote end hung up unexpectedly
Done
error: RPC failed; curl 56 Recv failure: Connection was reset

【问题讨论】:

  • 看看这个 SO 问题:stackoverflow.com/questions/10285700/…
  • 我也有同样的问题。为了解决这个问题,我正在做以下事情:git reset --hard HEAD~1 之后。我再次将我的项目文件添加到同一个文件夹中,因为一切都已恢复到上一阶段。所以然后执行以下命令。 git add * - git commit -m 'again' - git push。然后推送成功。
  • 这通常是由于网络干扰或远程服务或远程操作系统关闭连接而发生的。一个原因可能是远程内存不足。 @jketting 你能提供来自服务器的日志吗? @lightsouls 在没有其他命令的情况下尝试 git push 几次也有帮助吗?

标签: git push gitlab


【解决方案1】:

当主机从http://gitlab.company.com/group/myproject/' 更改为http://gitlab.company.net/group/myproject/ 时,我收到此错误。要更新远程头,我们可以从 IDE 执行此步骤(我使用的是 Intellij IDE)

IntelliJ -> VCS -> Git -> 遥控器(编辑、删除或添加新遥控器)

【讨论】:

    【解决方案2】:

    请尝试以下方法之一:

    方法一

    git config --global http.postBuffer 157286400
    

    方法二
    增加 Gitlab 服务器中 Nginx 配置的“client_max_body_size”。

    查看此链接以获取更多信息: https://confluence.atlassian.com/stashkb/git-push-fails-client-intended-to-send-too-large-chunked-body-590251250.html

    希望它们有用!祝你好运!!!

    【讨论】:

    • 我有一个稍微不同的错误,但这也解决了它:error: RPC failed; curl 55 TCP connection reset by peer
    猜你喜欢
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    • 2018-02-24
    • 2013-03-17
    • 2019-03-25
    • 1970-01-01
    • 1970-01-01
    • 1970-01-01
    相关资源
    最近更新 更多