git.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Mike Galbraith <efault@gmx.de>
To: Rolf Eike Beer <eb@emlix.com>,
	git@vger.kernel.org,
	Linus Torvalds <torvalds@linux-foundation.org>
Cc: Tobias Ulmer <tu@emlix.com>, Junio C Hamano <gitster@pobox.com>,
	linux-kernel@vger.kernel.org
Subject: Re: data loss when doing ls-remote and piped to command
Date: Thu, 16 Sep 2021 17:49:59 +0200	[thread overview]
Message-ID: <b14d79e49e3abe3fdf00cf18bb8c992b4575c5cc.camel@gmx.de> (raw)
In-Reply-To: <2677927.DK6gFqPMyL@devpool47>

On Thu, 2021-09-16 at 14:17 +0200, Rolf Eike Beer wrote:
> Am Donnerstag, 16. September 2021, 12:12:48 CEST schrieb Tobias Ulmer:
> > On 16/09/2021 08:38, Rolf Eike Beer wrote:
> > ...
> >
> > > The redirection seems to be an important part of it. I now did:
> > >
> > > git ... 2>&1 | sha256sum
> >
> > I've tried to reproduce this since yesterday, but couldn't until now:
> >
> > 2>&1 made all the difference, took less than a minute.
> >
> > Different repo, different machine, but also running Tumbleweed
> > 5.14.1-1-default, git 2.33.0
> >
> > while [ "`git --git-dir=$PWD/in/linux/.git ls-remote origin 2>&1 | tee
> > failed.out | sha1sum`" = "7fa299e589bacdc908395730beff542b0fc684eb  -"
> > ]; do echo -n .; done
> > ..........
> >
> > failed.out has multiple lines like this:
> >
> > --8<--
> > 4e77f7f1261f65cff06918bc5e66d02a418fc842        refs/tags/v3.10.18^{}
> > f7b8df0cc81cf82a4ac6834225bddbe46a340455a4a5d52f29d08d923ce8d232b0b497da674d
> > d2c refs/tags/v3.18
> > b2776bf7149bddd1f4161f14f79520f17fc1d71d        refs/tags/v3.18^{}
> > --8<--
> >
> >
> > Running the same on Archlinux (5.13.13-arch1-1, 2.33.0) doesn't show the
> > problem.
> > This may well turn out not to be git, but a kernel issue.
>
> Linus,
>
> since you have been hacking around in pipe.c recently, I fear this isn't
> entirely impossible. Have you any idea?
>
> For easier reference, the complete thread is at:
>
> https://public-inbox.org/git/85a103f6-8b3c-2f21-cc0f-04f517c0c9a1@emlix.com/T/
>

I use git-daemon (2.33) and reference clones for my local pile of
kernel trees (74), so out of curiosity, modified the above ls-remote
loop to fit one of them, and tried to reproduce with both master.today
(ff1ffd71) and SUSE's stable branch (where Tumbleweed gets source,
currently at 5.14.4).  Both kernels failed to reproduce given a few
minutes each (zzzz) to do so.  I'm running Leap-15.3 vs Tumbleweed, but
that shouldn't matter.

	-Mike

  reply	other threads:[~2021-09-16 15:50 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2021-09-15 12:43 data loss when doing ls-remote and piped to command Rolf Eike Beer
2021-09-15 18:17 ` Junio C Hamano
2021-09-16  6:38   ` Rolf Eike Beer
2021-09-16 10:12     ` Tobias Ulmer
2021-09-16 12:17       ` Rolf Eike Beer
2021-09-16 15:49         ` Mike Galbraith [this message]
2021-09-17  6:38           ` Mike Galbraith
2021-09-16 17:11         ` Linus Torvalds
2021-09-16 20:42           ` Junio C Hamano
2021-09-17  6:59             ` Rolf Eike Beer
2021-09-17 19:13               ` Jeff King
2021-09-17 19:28               ` Linus Torvalds
2021-09-18  6:33               ` Mike Galbraith

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=b14d79e49e3abe3fdf00cf18bb8c992b4575c5cc.camel@gmx.de \
    --to=efault@gmx.de \
    --cc=eb@emlix.com \
    --cc=git@vger.kernel.org \
    --cc=gitster@pobox.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=torvalds@linux-foundation.org \
    --cc=tu@emlix.com \
    /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).