상황 )
지인이 외주 받은 프로젝트를 zip으로 받은 소스폴더를 GitHub에 올려서 관리하고 싶어했지만, <git remote add 원격주소> 로 연결해서 Push했을 때 에러가 발생해 아예 업로드가 안되는 문제가 있었다.
(...생략)
Delta compression using up to 8 threads
Compressing objects: 100% (2088/2088), done.
error; RPC failed; HTTP 400 curl 22 The requested URL returned error: 490 send-pack: unexpected disconnect while reading sideband packet Writing objects: 100% (2192/2192), 42.10 MiB | 18.16 NiB/s, done.
Total 2192 (delta 71), reused 8 (delta 0), pack-reused ® fatal: the remote end hung up unexpectedly
문제 )
업로드할 때 메모리 초과 문제 또는 네트워크 송수신 끊김 문제인 것 같았다. 폴더를 작은 단위로 쪼개서 올리니 가능은 했는데, 폴더를 쪼개기 위해 GitHub에서 드래그 앤 드랍 방식을 했다. 하지만, 한 번에 100개 이상의 파일은 올릴 수가 없어 프로젝트 폴더를 일일이 파헤쳐야 했다..
해결 )
Git에서 업로드 요청할 때 버퍼크기를 제어할 수 있었다.
git config --global http.postBuffer 524288000
이 명령어로 프로젝트 크기(약 2.5GB)보다 버퍼를 늘렸고, 다시 git push origin 시도해보니 잘 올라갔다.
- stackoverflow
git push failure while pushing a large respository of code
I am trying to push my code from an old repository to a new repository as my old repository seems to be currupted somehow getting following error: Counting objects: 19815, done. Compressing objects...
stackoverflow.com
https://thewayeye.net/posts/fixing-the-rpc-failed-http-400-error-in-git/
Fixing the “RPC Failed; HTTP 400” Error in Git
If you’ve encountered the error: [info] error: RPC failed; HTTP 400 curl 22 The requested URL returned error: 400 Typically this occurs due to large file sizes being pushed to a remote repository, leading to an issue with the buffer size Git uses for HTT
thewayeye.net
https://sonseungha.tistory.com/525
[git] fatal: The remote end hung up unexpectedly
git을 사용하다보면 가끔 아래와 같은 에러를 만날 수 있습니다. fatal: The remote end hung up unexpectedly 이런 경우는 git의 post buffer 사이즈 문제입니다. 아래와 같이 버퍼 사이즈를 늘려줌으로써 해결할
sonseungha.tistory.com
https://itchipmunk.tistory.com/636
[트러블슈팅] Git Push 오류 (error: RPC failed; HTTP 400 curl 22 The requested URL returned error: 400)
요약해결방법 1번. http.postBuffer 설정Git Push 크기가 최대 버퍼 크기보다 크기 때문에 오류 발생합니다.최대 전송 버퍼 크기는 1.0 MiB 이므로 늘려야 합니다.# 버퍼 크기를 10 MiB (10 * 1024 * 1024) 로 설
itchipmunk.tistory.com
'Programming' 카테고리의 다른 글
[npm] 명령어와 옵션 (package.json이 뭐야?) (0) | 2023.05.09 |
---|---|
[기타, VS code] 상대 경로 오류, 실행 파일 경로, launch json (0) | 2022.09.01 |
[크롬 익스텐션] vimium, 크롬을 vim 처럼 마우스없이 사용하기 (0) | 2022.08.29 |