git push initial to gitolite仓库失败,并带有index-pack而不是git命令 [英] git push initial to gitolite repository fails with index-pack not a git command

查看:105
本文介绍了git push initial to gitolite仓库失败,并带有index-pack而不是git命令的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我在gitolite-admin conf中添加了一个回购协议,并成功将其推送

I added a repo to gitolite-admin conf and pushing it successful

现在我想导入一个现有的存储库

Now I wanted to import an exiting repository

当我调用一个 git push --all git @ gitserver:mybeerrepo

when I invoke a git push --all git@gitserver:mybeerrepo

我明白了 git:"index-pack"不是git命令. 错误:打包对象因奇怪的错误而死亡 错误:无法将某些参照推送到...

I get git: 'index-pack' is not a git-command. error: pack-objects died with strange error error: failed to push some refs to ...

我检查了该用户的.bashrc文件,路径看起来还可以

I checked the .bashrc file for that user and the path looks okay

git gc似乎也能很好地工作

git gc in that repository seems to work well too

不知道下一步该怎么做:-7

no idea what to do next now :-7

推荐答案

问题是由git的旧版本引起的.

运行gitolite的服务器上安装的git版本1.6.x.x中似乎存在一个错误.

The problem was caused by an old version of git

There seems to be a bug in the git version 1.6.x.x which had been installed on the Server where gitolite is running.

客户端在1.7.9.5上,服务器在1.6.x.x上. 即使从服务器进行推送也失败了.

The Client was on 1.7.9.5 the server on 1.6.x.x. Even doing the push from the server did fail.

由于git gc运作良好,仅当索引打包程序通过push ssh和gitolite运行并且回购中有一些特定文件(可能是种类,大小)时,问题似乎仍然存在. 要摆脱这个...

As a git gc is working well the problem seems to exist only when the index-packer is run through push ssh and gitolite and there are some specific files in the repo, maybe kind, size. To get rid of this ...

我在SLES 10盒子上从源代码安装了一个新版本的git,因为没有兼容的suse版本的rpm.

I installed a new version of git from source on the SLES 10 box as there are no compatible rpms for older suse releases.

cd /root  
wget git-core.googlecode.com/files/git-1.7.8.4.tar.gz  
tar -xvpzf git-1.7.8.4.tar.gz  
cd git-1.7.8.4 
./configure --without-python  
make  
make install  

创建符号链接(如果需要,请在此之前删除旧的git引用)

create symlinks (if needed remove old git references before)

cd /usr/bin  
ln -s /usr/local/libexec/git-core/git  
ln -s /usr/local/libexec/git-core/git-receive-pack   
ln -s /usr/local/libexec/git-core/git-shell  
ln -s /usr/local/libexec/git-core/git-upload-archive  
ln -s /usr/local/libexec/git-core/git-upload-pack`  

这篇关于git push initial to gitolite仓库失败,并带有index-pack而不是git命令的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆