I keep getting this error when I try to push anything to my own gitlab server:
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
I have no idea why I keep getting this error. I kept trying to push and then out of nowhere it pushed it successfully. But everything I tried to push after that just gave me the same error.
Here is a more detailed log:
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
failed to push some refs to errors are often caused when changes are not committed before pushing, issues with Git pre-push hook, incorrect branch name, or the local repository not being in sync with the Git repository.
It may be possible that push permission is not provided to the user pushing the code changes. I suggest checking the user permissions. If the push permission is present, then it may be possible that there is a pre-push git hook in the repo and your push isn't in accordance with it.
Sometimes, Git can't make your change to a remote repository without losing commits. When this happens, your push is refused. If another person has pushed to the same branch as you, Git won't be able to push your changes: $ git push origin main > To https://github.com/USERNAME/REPOSITORY.git > !
It happens if you change your login or password of git service account (Git). You need to change it in Windows Credentials Manager too. type "Credential Manager" in Windows Search menu open it. Windows Credentials Manager->Windows Credential and under Generic Credentials edit your git password.
Please try one of these methods below:
Method 1:
git config --global http.postBuffer 157286400
Method 2:
Increase "client_max_body_size" of your Nginx configuration in your Gitlab server.
Checkout this link to get more information: https://confluence.atlassian.com/stashkb/git-push-fails-client-intended-to-send-too-large-chunked-body-590251250.html
Hope they will be useful! Good luck!!!
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With