You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
0.14 sometimes hangs before running any actions #5336
It appears that we unconditionally run docker info on every build, and if that hangs, we also hang. There is a fix at HEAD (4b80f24) but that doesn't help 0.14 by itself.
I'm happy to help debug this further. Can you let me know what additional info I can provide? I suspect it's something like in certain cases the docker process is waiting to read from stdin or something like that?
Common reasons for hanging commands that do network requests are a wrongly configured hostname / DNS setup. I notice that your "Name" output in docker info gives "localhost", which is at least a bit weird. It should instead return the actual hostname of your machine.
Can you still reproduce the docker info hang with Bazel and/or without Bazel on your machine?
Delay initialization of the Docker module so that users who aren't actually using the Docker sandbox are not affected by any delays.
Run docker info with a timeout of 10 seconds (or so) and if it still didn't finish by then, abort and print an error (and possibly whatever docker info printed to stdout/stderr, if anything).
There's nothing Bazel can do to fix or workaround the hang itself, though.
Given the age of this report... and that things might have changed... I'll have to close due to the apparent difficulty in reproducing this. Please let me know if think this is still a problem.
Activity
mattklein123 commentedon Jun 7, 2018
Hi,
I'm happy to help debug this further. Can you let me know what additional info I can provide? I suspect it's something like in certain cases the docker process is waiting to read from stdin or something like that?
mattklein123 commentedon Jun 7, 2018
For reference.
lfpino commentedon Jun 7, 2018
Assigning back to @lberki and @aehlig (Bazel sheriff) to further debug this if needed.
Release 0.14.1 (2018-06-08)
Release 0.14.1 (2018-06-08)
hlopko commentedon Jun 25, 2018
Since the 0.14.1 release is out, can this be closed?
mattklein123 commentedon Jun 25, 2018
If you want? Though don't you have to figure out why it hangs?
hlopko commentedon Jun 25, 2018
I believe the fix was to hide docker sandbox behind a flag (c909639)
@lberki @dslomov is that correct?
2 remaining items
lberki commentedon Jun 25, 2018
It'll be taken care of by @philwo when he's back at work.
ittaiz commentedon Jun 25, 2018
philwo commentedon Jul 4, 2018
@mattklein123 @ittaiz If
docker infohangs, this sounds more like a Docker issue.I checked the code and I don't think it ever waits for stdin. The "info" command makes a single API request to the Docker daemon, decodes the result and prints it (https://github.com/moby/moby/blob/master/client/info.go).
Common reasons for hanging commands that do network requests are a wrongly configured hostname / DNS setup. I notice that your "Name" output in
docker infogives "localhost", which is at least a bit weird. It should instead return the actual hostname of your machine.Can you still reproduce the
docker infohang with Bazel and/or without Bazel on your machine?philwo commentedon Jul 4, 2018
There are two things we can do on Bazel's side:
docker infowith a timeout of 10 seconds (or so) and if it still didn't finish by then, abort and print an error (and possibly whateverdocker infoprinted to stdout/stderr, if anything).There's nothing Bazel can do to fix or workaround the hang itself, though.
mattklein123 commentedon Jul 4, 2018
docker inforuns just fine on my machine. It was something with how Bazel was calling it through Java. That's all I can offer you.Release 0.14.1 (2018-06-08)
jmmv commentedon May 11, 2020
Given the age of this report... and that things might have changed... I'll have to close due to the apparent difficulty in reproducing this. Please let me know if think this is still a problem.