很抱歉打扰您,我遇到了一个常见的问题。虽然在Stack Overflow上有很多解决方案,但这些解决方案都不适用于我。所以最后我别无选择,只能再次向您这个天才求助。
- 我在服务器上克隆了一个存储库。
- 当我在开发机器上更改了一些代码并将其推送到远程Git存储库时,一切都很顺利。
- 错误始于我从服务器拉取数据时。在服务器上,我输入命令
git pull
,出现以下错误:
remote: Counting objects: 66, done.
remote: Compressing objects: 100% (65/65), done.
Connection to bitbucket.org closed by remote host.
fatal: The remote end hung up unexpectedly
fatal: early EOF
fatal: unpack-objects failed
- 我尝试了这个解决方案:fatal: early EOF fatal: index-pack failed,但是在第2步
git clone --depth 1 <repo_URI>
时出现错误。
错误信息如下:
Cloning into 'sinolife'...
remote: Counting objects: 2783, done.
remote: Compressing objects: 100% (2199/2199), done.
Connection to bitbucket.org closed by remote host.00 KiB/s
fatal: The remote end hung up unexpectedly
fatal: early EOF
fatal: index-pack failed
I also get a solution that there isn't enough swap memory. so i create a swap memory. At the beginning the swap is 0...After i config the swap, the
free -m
result is:total used free shared buffers cached
内存:993 MB已使用,930 MB可用,已使用63 MB,空闲0 MB,缓存21 MB,已缓存57 MB。
除去缓冲区和高速缓存后:已使用851 MB,可用142 MB。
交换空间:499 MB已使用,16 MB可用,已使用483 MB。
但我也遇到了一些错误。
$git pull
remote: Counting objects: 66, done.
remote: Compressing objects: 100% (65/65), done.
Connection to bitbucket.org closed by remote host.
fatal: The remote end hung up unexpectedly
fatal: early EOF
fatal: unpack-objects failed
$git clone
Cloning into 'sinolife'...
remote: Counting objects: 2783, done.
remote: Compressing objects: 100% (2199/2199), done.
Connection to bitbucket.org closed by remote host.00 KiB/s
fatal: The remote end hung up unexpectedly
fatal: early EOF
fatal: index-pack failed
- 还有git克隆时遇到"The remote end hung up unexpectedly"错误,按照步骤操作后仍然出现错误。以下是我的git配置文件
$git config -l
http.postbuffer=524288000
user.email= myemail@myemail.com
core.compression=0
core.compression=-1
core.compression=-1
core.repositoryformatversion=0
core.filemode=true
core.bare=false
core.logallrefupdates=true
core.compression=-1
core.packedgitlimit=512m
core.packedgitwindowsize=512m
remote.origin.url= my repository
remote.origin.fetch=+refs/heads/*:refs/remotes/origin/*
branch.master.remote=origin
branch.master.merge=refs/heads/master
pack.deltacachesize=2047m
pack.packsizelimit=2047m
pack.windowmemory=2047m
我的环境:
uname -a
Linux VM-87-192-ubuntu 3.13.0-86-generic #131-Ubuntu SMP Thu May 12 23:33:13 UTC 2016 x86_64 x86_64 x86_64 GNU/Linux
git --version
git 版本为 2.11.0
8. 希望有人能给我一些提示。
9. 问题概述
我有一个 git 仓库,并已在服务器上克隆,但当运行 git pull
命令时,出现错误:
remote: Counting objects: 66, done.
remote: Compressing objects: 100% (65/65), done.
Connection to bitbucket.org closed by remote host.
fatal: The remote end hung up unexpectedly
fatal: early EOF
fatal: unpack-objects failed
当开始一个新的克隆时 git clone
Cloning into 'sinolife'...
remote: Counting objects: 2057, done.
remote: Compressing objects: 100% (1740/1740), done.
Connection to bitbucket.org closed by remote host.00 KiB/s
fatal: The remote end hung up unexpectedly
fatal: early EOF
fatal: index-pack failed
fatal: unpack-objects failed
)。之前,通过将更改拉到全新分支以完成操作可以解决此问题。但是这一次我无法摆脱它(( - valijongit pull origin your_branch
。git checkout your_branch
然后再次拉取。我不知道为什么,但这解决了问题。 - valijon