git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: "Johan Sørensen" <johan@johansorensen.com>
To: Jeff King <peff@peff.net>
Cc: Aloisio <aloisiojr@gmail.com>,
	git@vger.kernel.org, support@gitorious.org
Subject: Re: Cannot clone redirecting stdout
Date: Fri, 11 Sep 2009 17:46:23 +0200	[thread overview]
Message-ID: <9e0f31700909110846h54959ae6u466ceda40799ba37@mail.gmail.com> (raw)
In-Reply-To: <20090911135110.GA30860@coredump.intra.peff.net>

On Fri, Sep 11, 2009 at 3:51 PM, Jeff King <peff@peff.net> wrote:
> On Fri, Sep 11, 2009 at 06:23:29AM -0400, Jeff King wrote:
>
>> > I faced a problem when trying to clone git://gitorious.org/qt/qt.git
>> >
>> > this works:
>> > git clone -n git://gitorious.org/qt/qt.git repo
>> >
>> > this doesn't:
>> > git clone -n git://gitorious.org/qt/qt.git repo >log
>> > fatal: The remote end hung up unexpectedly
>> > fatal: early EOF
>> > fatal: index-pack failed
>>
>> I can reproduce the problem here. But after staring at the strace for a
>> long time, I don't think the problem is on the client side. The remote
>> end _does_ hang up unexpectedly.
>>
>> Looking at what we send, the only difference between the redirected and
>> unredirected case I could find is that we send the "no-progress" flag to
>> the server, which then hangs up on us instead of sending us the pack.
>> Which makes no sense.
>
> I did a little more testing, and I can't reproduce the problem against a
> local git-daemon. I tried using several versions for the server, going
> all the way back to v1.5.0, which pre-dates no-progress, and all of them
> worked just fine.
>
> So I am inclined to think there is something non-standard or broken at
> gitorious.org. I'm cc'ing support@gitorious to see if they have any
> comment.

Some quick tests seem to indicate it's related to the fact that our
wonderful little fork+exec git-daemon[1] (which is different from the
one distributed with git) exec's to "git-upload-pack --strict
--timeout=30 /path/to/repo". Now, why exactly that'll trigger when the
no-progress flag is given I'm not sure of. The daemon itself execs as
soon as it figures out what repo the client requested, so apart from
the timeout the only thing it reacts to is the header (the
"${headersize}git-upload-pack project/repo.git\0host=gitorious.org\0"
part).

We also do redirect stderr to /dev/null for reasons I cannot remember
(so probably not good ones), that may be related as well. Well run
some more tests...

[1]: http://gitorious.org/gitorious/mainline/blobs/master/script/git-daemon

>
> -Peff
> --
> To unsubscribe from this list: send the line "unsubscribe git" in
> the body of a message to majordomo@vger.kernel.org
> More majordomo info at  http://vger.kernel.org/majordomo-info.html
>

  reply	other threads:[~2009-09-11 15:46 UTC|newest]

Thread overview: 10+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2009-09-10 22:33 Cannot clone redirecting stdout Aloisio
2009-09-11  6:39 ` Stefan Naewe
2009-09-11  7:27   ` Stefan Naewe
2009-09-11  8:15 ` Jean-Luc Herren
2009-09-11 10:23 ` Jeff King
2009-09-11 13:51   ` Jeff King
2009-09-11 15:46     ` Johan Sørensen [this message]
2009-09-11 16:05       ` Jeff King
2009-09-11 16:20         ` Jeff King
2009-09-11 22:47           ` Daniel Barkalow

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=9e0f31700909110846h54959ae6u466ceda40799ba37@mail.gmail.com \
    --to=johan@johansorensen.com \
    --cc=aloisiojr@gmail.com \
    --cc=git@vger.kernel.org \
    --cc=peff@peff.net \
    --cc=support@gitorious.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).