From: Sitsofe Wheeler <sitsofe@gmail.com>
To: Jeff King <peff@peff.net>
Cc: git@vger.kernel.org
Subject: Re: Periodic hang during git index-pack
Date: Thu, 20 Dec 2018 16:48:13 +0000 [thread overview]
Message-ID: <CALjAwxjyS5raGbib5KyUPZzS+9UyB1fpCN2fybYoYOctXe7iyA@mail.gmail.com> (raw)
In-Reply-To: <20181220151037.GC27361@sigill.intra.peff.net>
On Thu, 20 Dec 2018 at 15:11, Jeff King <peff@peff.net> wrote:
>
> OK, that's about what I expected. Here we have clone's sideband-demux
> thread waiting to pull more packfile data from the remote:
>
> > (gdb) thread apply all bt
> >
> > Thread 2 (Thread 0x7faafbf1c700 (LWP 36586)):
> > #0 0x00007faafc805384 in __libc_read (fd=fd@entry=5,
> > buf=buf@entry=0x7faafbf0ddec, nbytes=nbytes@entry=5)
> > at ../sysdeps/unix/sysv/linux/read.c:27
> > #1 0x000055c8ca2f5b23 in read (__nbytes=5, __buf=0x7faafbf0ddec, __fd=5)
> > at /usr/include/x86_64-linux-gnu/bits/unistd.h:44
> > [...coming from packet_read / recv_sideband / sideband_demux...]
>
> I assume fd=5 there is a pipe connected to ssh. You could double check
> with "lsof" or similar, but I don't think it would ever be reading from
> anywhere else.
I checked and in all cases git was reading from a pipe.
[snip]
> with each blocking on read() from its predecessor. So you need to find
> out why "ssh" is blocking. Unfortunately, short of a bug in ssh, the
> likely cause is either:
>
> 1. The git-upload-pack on the remote side stopped generating data for
> some reason. You may or may not have access on the remotehost to
> dig into that.
>
> It's certainly possible there's a deadlock bug between the server
> and client side of a Git conversation. But I'd find it extremely
> unlikely to find such a deadlock bug at this point in the
> conversation, because at this point the client side has nothing
> left to say to the server. The server should just be streaming out
> the packfile bytes and then closing the descriptor.
I think it's highly unlikely too given how many good runs we generally have.
> You mentioned "Phabricator sshd scripts" running on the server.
> I don't know what Phabricator might be sticking in the middle of
> the connection, but that could be the source of the stall.
I think you're right. I set up a seperate sshd on a different port on
the same machine where there were no Phabricator callouts and the
problem never manifested...
> 2. It's possible the network connection dropped but ssh did not
> notice. Maybe try turning on ssh keepalives and seeing if it
> eventually times out?
I had already done this but the problem still manifested. I went so
far as checking if the problem would happen over the loopback device
on the same machine (via localhost) and the problem continued
happening so I'm fairly sure that rules out networking issues.
--
Sitsofe | http://sucs.org/~sits/
next prev parent reply other threads:[~2018-12-20 16:48 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-12-19 22:59 Periodic hang during git index-pack Sitsofe Wheeler
2018-12-19 23:22 ` Jeff King
2018-12-20 10:03 ` Sitsofe Wheeler
2018-12-20 15:10 ` Jeff King
2018-12-20 16:48 ` Sitsofe Wheeler [this message]
2019-02-03 8:16 ` Sitsofe Wheeler
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=CALjAwxjyS5raGbib5KyUPZzS+9UyB1fpCN2fybYoYOctXe7iyA@mail.gmail.com \
--to=sitsofe@gmail.com \
--cc=git@vger.kernel.org \
--cc=peff@peff.net \
/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).