git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Elijah Newren" <newren@gmail.com>
To: git@vger.kernel.org
Subject: Unable to clone an ssh repository (with ugly installation-specific workaround)
Date: Mon, 11 Feb 2008 19:22:48 -0700	[thread overview]
Message-ID: <51419b2c0802111822k4600e06bp4167a09b30bf947a@mail.gmail.com> (raw)

[-- Attachment #1: Type: text/plain, Size: 977 bytes --]

Hi,

I'm pretty sure this worked before, but with git-1.5.4, when trying to
clone a repository via ssh from a machine that does not have git
installed in a standard system path, I get the following:

$ git clone -u /home/enewren/software/install/linux/git/bin/git-upload-pack
ssh://enewren@remote/var/scratch/enewren/votd
Initialized empty Git repository in /home/newren/devel/votd/.git/
remote: fatal: exec pack-objects failed.
remote: aborting due to possible repository corruption on the remote side.
fatal: early EOF
fatal: index-pack failed
fetch-pack from 'ssh://enewren@remote/var/scratch/enewren/votd' failed.

I tried doing a local clone of the same repository (worked fine), a
'git fsck -full' on the relevant repository (reported no errors), and
a few other things.  After a bit of digging, I found a really ugly
hack that works around my problem.  After recompiling git on the
remote machine with the attached patch, the clone operation succeeded.


Thanks,
Elijah

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: ugly-hack.patch --]
[-- Type: text/x-patch; name=ugly-hack.patch, Size: 375 bytes --]

--- git-1.5.4/exec_cmd.c~	2008-02-01 21:09:01.000000000 -0700
+++ git-1.5.4/exec_cmd.c	2008-02-11 17:35:11.092796000 -0700
@@ -69,7 +69,7 @@
 	const char *tmp;
 
 	strbuf_init(&cmd, 0);
-	strbuf_addf(&cmd, "git-%s", argv[0]);
+	strbuf_addf(&cmd, "/home/enewren/software/install/linux/git/bin/git-%s", argv[0]);
 
 	/*
 	 * argv[0] must be the git command, but the argv array

             reply	other threads:[~2008-02-12  2:23 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-02-12  2:22 Elijah Newren [this message]
2008-02-12  7:04 ` Unable to clone an ssh repository (with ugly installation-specific workaround) David Symonds
2008-02-12  8:16 ` Jakub Narebski
2008-02-12  8:37   ` Johannes Sixt
2008-02-12 10:30     ` Johannes Schindelin
2008-02-12 11:28       ` [PATCH] upload-pack: Initialize the exec-path Johannes Sixt
2008-02-12 11:49         ` Johannes Schindelin
2008-02-12 12:45           ` Johannes Schindelin
2008-02-13 13:00             ` Elijah Newren
2008-02-13 12:57       ` Unable to clone an ssh repository (with ugly installation-specific workaround) Elijah Newren
2008-02-13 14:17         ` Stephen Sinclair

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=51419b2c0802111822k4600e06bp4167a09b30bf947a@mail.gmail.com \
    --to=newren@gmail.com \
    --cc=git@vger.kernel.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).