Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bazel hangs at 'Found 1 target..' on linux machine #15373

Closed
rock626 opened this issue Apr 29, 2022 · 14 comments
Closed

Bazel hangs at 'Found 1 target..' on linux machine #15373

rock626 opened this issue Apr 29, 2022 · 14 comments
Assignees
Labels
awaiting-user-response Awaiting a response from the author team-Local-Exec Issues and PRs for the Execution (Local) team type: bug untriaged

Comments

@rock626
Copy link

rock626 commented Apr 29, 2022

Description of the bug:

I am trying to do a bazel on java project and it just gets stuck as below:

bazel build //:ProjectRunner
INFO: Analyzed target //:ProjectRunner (46 packages loaded, 769 targets configured).
INFO: Found 1 target...

^_^\
Sending SIGQUIT to JVM process 20514 (see /home/gchandu/.cache/bazel/_bazel_gchandu/b06e270b1ec15686386c634bb46c639a/server/jvm.out).

Attaching SIGQUIT file.
This stopped working after the machine was rebooted.

What's the simplest, easiest way to reproduce this bug? Please provide a minimal example if possible.

Follow the steps to run java sample tutorial from examples

Which operating system are you running Bazel on?

Ubuntu 18.04

What is the output of bazel info release?

release 5.1.0

If bazel info release returns development version or (@non-git), tell us how you built Bazel.

No response

What's the output of git remote get-url origin; git rev-parse master; git rev-parse HEAD ?

https://github.com/bazelbuild/examples.git
master
fatal: ambiguous argument 'master': unknown revision or path not in the working tree.
Use '--' to separate paths from revisions, like this:
'git <command> [<revision>...] -- [<file>...]'
0e37f1a5ddfc31a47982a300000d877fdd5e5e2e

Have you found anything relevant by searching the web?

No

Any other information, logs, or outputs that you want to share?

2022-04-29 11:45:06
Full thread dump OpenJDK 64-Bit Server VM (11.0.6+10-LTS mixed mode):

Threads class SMR info:
_java_thread_list=0x00007f25ac000b20, length=24, elements={
0x00007f26f0019000, 0x00007f26f02db000, 0x00007f26f02dd000, 0x00007f26f02f0800,
0x00007f26f02f2800, 0x00007f26f02f4800, 0x00007f26f02f6800, 0x00007f26f0363000,
0x00007f26f0367000, 0x00007f26f0b5b000, 0x00007f26f0d07800, 0x00007f26f0cff800,
0x00007f261802d000, 0x00007f260c240800, 0x00007f261802e800, 0x00007f26100e8800,
0x00007f26100e9800, 0x00007f2610026000, 0x00007f25e001a000, 0x00007f25e001c800,
0x00007f25e0021800, 0x00007f25c01b9000, 0x00007f258c006800, 0x00007f2610464800
}

"main" #1 prio=5 os_prio=0 cpu=823.02ms elapsed=541.53s tid=0x00007f26f0019000 nid=0x5023 in Object.wait() [0x00007f26f82d9000]
java.lang.Thread.State: WAITING (on object monitor)
at java.lang.Object.wait([email protected]/Native Method)
- waiting on <0x0000000413084c00> (a java.lang.Object)
at java.lang.Object.wait([email protected]/Unknown Source)
at io.grpc.internal.ServerImpl.awaitTermination(ServerImpl.java:320)
- waiting to re-lock in wait() <0x0000000413084c00> (a java.lang.Object)
at com.google.devtools.build.lib.server.GrpcServerImpl.serve(GrpcServerImpl.java:432)
at com.google.devtools.build.lib.runtime.BlazeRuntime.serverMain(BlazeRuntime.java:1064)
at com.google.devtools.build.lib.runtime.BlazeRuntime.main(BlazeRuntime.java:768)
at com.google.devtools.build.lib.bazel.Bazel.main(Bazel.java:87)

"Reference Handler" #2 daemon prio=10 os_prio=0 cpu=2.91ms elapsed=541.51s tid=0x00007f26f02db000 nid=0x502a waiting on condition [0x00007f26b435c000]
java.lang.Thread.State: RUNNABLE
at java.lang.ref.Reference.waitForReferencePendingList([email protected]/Native Method)
at java.lang.ref.Reference.processPendingReferences([email protected]/Unknown Source)
at java.lang.ref.Reference$ReferenceHandler.run([email protected]/Unknown Source)

"Finalizer" #3 daemon prio=8 os_prio=0 cpu=2.16ms elapsed=541.51s tid=0x00007f26f02dd000 nid=0x502b in Object.wait() [0x00007f26b425b000]
java.lang.Thread.State: WAITING (on object monitor)
at java.lang.Object.wait([email protected]/Native Method)
- waiting on <0x0000000412800470> (a java.lang.ref.ReferenceQueue$Lock)
at java.lang.ref.ReferenceQueue.remove([email protected]/Unknown Source)
- waiting to re-lock in wait() <0x0000000412800470> (a java.lang.ref.ReferenceQueue$Lock)
at java.lang.ref.ReferenceQueue.remove([email protected]/Unknown Source)
at java.lang.ref.Finalizer$FinalizerThread.run([email protected]/Unknown Source)

"Signal Dispatcher" #4 daemon prio=9 os_prio=0 cpu=0.25ms elapsed=541.50s tid=0x00007f26f02f0800 nid=0x502c waiting on condition [0x0000000000000000]
java.lang.Thread.State: RUNNABLE

"C2 CompilerThread0" #5 daemon prio=9 os_prio=0 cpu=3085.02ms elapsed=541.50s tid=0x00007f26f02f2800 nid=0x502d waiting on condition [0x0000000000000000]
java.lang.Thread.State: RUNNABLE
No compile task

"C1 CompilerThread0" #13 daemon prio=9 os_prio=0 cpu=1226.95ms elapsed=541.50s tid=0x00007f26f02f4800 nid=0x502e waiting on condition [0x0000000000000000]
java.lang.Thread.State: RUNNABLE
No compile task

"Sweeper thread" #17 daemon prio=9 os_prio=0 cpu=103.03ms elapsed=541.50s tid=0x00007f26f02f6800 nid=0x502f runnable [0x0000000000000000]
java.lang.Thread.State: RUNNABLE

"Common-Cleaner" #18 daemon prio=8 os_prio=0 cpu=3.44ms elapsed=541.47s tid=0x00007f26f0363000 nid=0x5032 in Object.wait() [0x00007f26ad01b000]
java.lang.Thread.State: TIMED_WAITING (on object monitor)
at java.lang.Object.wait([email protected]/Native Method)
- waiting on <0x0000000412802c10> (a java.lang.ref.ReferenceQueue$Lock)
at java.lang.ref.ReferenceQueue.remove([email protected]/Unknown Source)
- waiting to re-lock in wait() <0x0000000412802c10> (a java.lang.ref.ReferenceQueue$Lock)
at jdk.internal.ref.CleanerImpl.run([email protected]/Unknown Source)
at java.lang.Thread.run([email protected]/Unknown Source)
at jdk.internal.misc.InnocuousThread.run([email protected]/Unknown Source)

"Service Thread" #19 daemon prio=9 os_prio=0 cpu=28.06ms elapsed=541.46s tid=0x00007f26f0367000 nid=0x5033 runnable [0x0000000000000000]
java.lang.Thread.State: RUNNABLE

"pid-file-watcher" #22 daemon prio=5 os_prio=0 cpu=24.16ms elapsed=540.78s tid=0x00007f26f0b5b000 nid=0x5048 waiting on condition [0x00007f2661b3a000]
java.lang.Thread.State: TIMED_WAITING (sleeping)
at java.lang.Thread.sleep([email protected]/Native Method)
at java.lang.Thread.sleep([email protected]/Unknown Source)
at java.util.concurrent.TimeUnit.sleep([email protected]/Unknown Source)
at com.google.common.util.concurrent.Uninterruptibles.sleepUninterruptibly(Uninterruptibles.java:393)
at com.google.devtools.build.lib.server.PidFileWatcher.run(PidFileWatcher.java:67)

"grpc-default-boss-ELG-1-1" #25 daemon prio=5 os_prio=0 cpu=25.90ms elapsed=540.70s tid=0x00007f26f0d07800 nid=0x504a runnable [0x00007f2661527000]
java.lang.Thread.State: RUNNABLE
at io.netty.channel.epoll.Native.epollWait(Native Method)
at io.netty.channel.epoll.Native.epollWait(Native.java:192)
at io.netty.channel.epoll.Native.epollWait(Native.java:185)
at io.netty.channel.epoll.EpollEventLoop.epollWaitNoTimerChange(EpollEventLoop.java:290)
at io.netty.channel.epoll.EpollEventLoop.run(EpollEventLoop.java:347)
at io.netty.util.concurrent.SingleThreadEventExecutor$4.run(SingleThreadEventExecutor.java:986)
at io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74)
at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30)
at java.lang.Thread.run([email protected]/Unknown Source)

"grpc-timeout-and-memory" #26 daemon prio=5 os_prio=0 cpu=0.69ms elapsed=540.68s tid=0x00007f26f0cff800 nid=0x504b in Object.wait() [0x00007f26ac6ed000]
java.lang.Thread.State: WAITING (on object monitor)
at java.lang.Object.wait([email protected]/Native Method)
- waiting on <0x0000000413090768> (a java.util.HashMap)
at java.lang.Object.wait([email protected]/Unknown Source)
at com.google.devtools.build.lib.server.CommandManager.waitForChange(CommandManager.java:102)
- waiting to re-lock in wait() <0x0000000413090768> (a java.util.HashMap)
at com.google.devtools.build.lib.server.ServerWatcherRunnable.run(ServerWatcherRunnable.java:202)
at java.lang.Thread.run([email protected]/Unknown Source)

"grpc-default-worker-ELG-3-1" #27 daemon prio=5 os_prio=0 cpu=79.23ms elapsed=540.64s tid=0x00007f261802d000 nid=0x504f runnable [0x00007f2661226000]
java.lang.Thread.State: RUNNABLE
at io.netty.channel.epoll.Native.epollWait0(Native Method)
at io.netty.channel.epoll.Native.epollWait(Native.java:176)
at io.netty.channel.epoll.EpollEventLoop.epollWait(EpollEventLoop.java:281)
at io.netty.channel.epoll.EpollEventLoop.run(EpollEventLoop.java:351)
at io.netty.util.concurrent.SingleThreadEventExecutor$4.run(SingleThreadEventExecutor.java:986)
at io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74)
at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30)
at java.lang.Thread.run([email protected]/Unknown Source)

"grpc-command-0" #29 daemon prio=5 os_prio=0 cpu=516.55ms elapsed=540.54s tid=0x00007f260c240800 nid=0x5052 in Object.wait() [0x00007f2660d23000]
java.lang.Thread.State: WAITING (on object monitor)
at java.lang.Object.wait([email protected]/Native Method)
- waiting on <0x000000043b01dbc0> (a java.lang.ProcessImpl)
at java.lang.Object.wait([email protected]/Unknown Source)
at java.lang.ProcessImpl.waitFor([email protected]/Unknown Source)
- waiting to re-lock in wait() <0x000000043b01dbc0> (a java.lang.ProcessImpl)
at com.google.devtools.build.lib.shell.JavaSubprocessFactory$JavaSubprocess.waitFor(JavaSubprocessFactory.java:91)
at com.google.devtools.build.lib.shell.FutureCommandResult.waitForProcess(FutureCommandResult.java:109)
at com.google.devtools.build.lib.shell.FutureCommandResult.get(FutureCommandResult.java:52)
at com.google.devtools.build.lib.shell.Command.execute(Command.java:263)
at com.google.devtools.build.lib.sandbox.LinuxSandboxedSpawnRunner.computeIsSupported(LinuxSandboxedSpawnRunner.java:98)
at com.google.devtools.build.lib.sandbox.LinuxSandboxedSpawnRunner.isSupported(LinuxSandboxedSpawnRunner.java:82)
- locked <0x000000043b01dda0> (a java.util.HashMap)
at com.google.devtools.build.lib.sandbox.SandboxModule.setup(SandboxModule.java:285)
at com.google.devtools.build.lib.sandbox.SandboxModule.registerSpawnStrategies(SandboxModule.java:154)
at com.google.devtools.build.lib.buildtool.ExecutionTool.(ExecutionTool.java:170)
at com.google.devtools.build.lib.buildtool.BuildTool.buildTargets(BuildTool.java:204)
at com.google.devtools.build.lib.buildtool.BuildTool.processRequest(BuildTool.java:443)
at com.google.devtools.build.lib.buildtool.BuildTool.processRequest(BuildTool.java:411)
at com.google.devtools.build.lib.runtime.commands.BuildCommand.exec(BuildCommand.java:103)
at com.google.devtools.build.lib.runtime.BlazeCommandDispatcher.execExclusively(BlazeCommandDispatcher.java:585)
at com.google.devtools.build.lib.runtime.BlazeCommandDispatcher.exec(BlazeCommandDispatcher.java:231)
at com.google.devtools.build.lib.server.GrpcServerImpl.executeCommand(GrpcServerImpl.java:550)
at com.google.devtools.build.lib.server.GrpcServerImpl.lambda$run$1(GrpcServerImpl.java:614)
at com.google.devtools.build.lib.server.GrpcServerImpl$$Lambda$253/0x000000080032e840.run(Unknown Source)
at io.grpc.Context$1.run(Context.java:579)
at java.util.concurrent.ThreadPoolExecutor.runWorker([email protected]/Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run([email protected]/Unknown Source)
at java.lang.Thread.run([email protected]/Unknown Source)

"grpc-default-worker-ELG-3-2" #32 daemon prio=5 os_prio=0 cpu=48.63ms elapsed=530.36s tid=0x00007f261802e800 nid=0x50ae runnable [0x00007f26ac8ef000]
java.lang.Thread.State: RUNNABLE
at io.netty.channel.epoll.Native.epollWait(Native Method)
at io.netty.channel.epoll.Native.epollWait(Native.java:192)
at io.netty.channel.epoll.Native.epollWait(Native.java:185)
at io.netty.channel.epoll.EpollEventLoop.epollWaitNoTimerChange(EpollEventLoop.java:290)
at io.netty.channel.epoll.EpollEventLoop.run(EpollEventLoop.java:347)
at io.netty.util.concurrent.SingleThreadEventExecutor$4.run(SingleThreadEventExecutor.java:986)
at io.netty.util.internal.ThreadExecutorMap$2.run(ThreadExecutorMap.java:74)
at io.netty.util.concurrent.FastThreadLocalRunnable.run(FastThreadLocalRunnable.java:30)
at java.lang.Thread.run([email protected]/Unknown Source)

"profile-writer-thread" #34 daemon prio=5 os_prio=0 cpu=30.36ms elapsed=530.25s tid=0x00007f26100e8800 nid=0x50b4 waiting on condition [0x00007f26ad11c000]
java.lang.Thread.State: WAITING (parking)
at jdk.internal.misc.Unsafe.park([email protected]/Native Method)
- parking to wait for <0x00000004130976f8> (a java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject)
at java.util.concurrent.locks.LockSupport.park([email protected]/Unknown Source)
at java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.await([email protected]/Unknown Source)
at java.util.concurrent.LinkedBlockingQueue.take([email protected]/Unknown Source)
at com.google.devtools.build.lib.profiler.Profiler$JsonTraceFileWriter.run(Profiler.java:1062)
at java.lang.Thread.run([email protected]/Unknown Source)

"Thread-3" #35 daemon prio=5 os_prio=0 cpu=1535.53ms elapsed=530.25s tid=0x00007f26100e9800 nid=0x50b5 waiting on condition [0x00007f26ac1d5000]
java.lang.Thread.State: TIMED_WAITING (sleeping)
at java.lang.Thread.sleep([email protected]/Native Method)
at com.google.devtools.build.lib.profiler.CollectLocalResourceUsage.run(CollectLocalResourceUsage.java:86)

"cli-update-thread" #63 daemon prio=5 os_prio=0 cpu=113.46ms elapsed=530.09s tid=0x00007f2610026000 nid=0x50d3 waiting on condition [0x00007f266021e000]
java.lang.Thread.State: TIMED_WAITING (sleeping)
at java.lang.Thread.sleep([email protected]/Native Method)
at com.google.devtools.build.lib.runtime.UiEventHandler.lambda$startUpdateThread$0(UiEventHandler.java:926)
at com.google.devtools.build.lib.runtime.UiEventHandler$$Lambda$371/0x00000008004c7c40.run(Unknown Source)
at java.lang.Thread.run([email protected]/Unknown Source)

"process reaper" #139 daemon prio=10 os_prio=0 cpu=9.83ms elapsed=529.32s tid=0x00007f25e001a000 nid=0x512f runnable [0x00007f26f4068000]
java.lang.Thread.State: RUNNABLE
at java.lang.ProcessHandleImpl.waitForProcessExit0([email protected]/Native Method)
at java.lang.ProcessHandleImpl$1.run([email protected]/Unknown Source)
at java.util.concurrent.ThreadPoolExecutor.runWorker([email protected]/Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run([email protected]/Unknown Source)
at java.lang.Thread.run([email protected]/Unknown Source)

"Command-Accumulator-Thread-0" #140 daemon prio=5 os_prio=0 cpu=8.25ms elapsed=529.32s tid=0x00007f25e001c800 nid=0x5130 runnable [0x00007f2608bcc000]
java.lang.Thread.State: RUNNABLE
at java.io.FileInputStream.readBytes([email protected]/Native Method)
at java.io.FileInputStream.read([email protected]/Unknown Source)
at java.io.BufferedInputStream.fill([email protected]/Unknown Source)
at java.io.BufferedInputStream.read1([email protected]/Unknown Source)
at java.io.BufferedInputStream.read([email protected]/Unknown Source)
- locked <0x000000043b0790d8> (a java.lang.ProcessImpl$ProcessPipeInputStream)
at java.io.FilterInputStream.read([email protected]/Unknown Source)
at com.google.devtools.build.lib.shell.InputStreamSink$CopySink.run(InputStreamSink.java:97)
at com.google.devtools.build.lib.shell.Consumers$ClosingSink.run(Consumers.java:273)
at java.util.concurrent.Executors$RunnableAdapter.call([email protected]/Unknown Source)
at java.util.concurrent.FutureTask.run([email protected]/Unknown Source)
at java.util.concurrent.ThreadPoolExecutor.runWorker([email protected]/Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run([email protected]/Unknown Source)
at java.lang.Thread.run([email protected]/Unknown Source)

"Command-Accumulator-Thread-1" #141 daemon prio=5 os_prio=0 cpu=10.23ms elapsed=529.31s tid=0x00007f25e0021800 nid=0x5131 runnable [0x00007f2608acb000]
java.lang.Thread.State: RUNNABLE
at java.io.FileInputStream.readBytes([email protected]/Native Method)
at java.io.FileInputStream.read([email protected]/Unknown Source)
at java.io.BufferedInputStream.fill([email protected]/Unknown Source)
at java.io.BufferedInputStream.read1([email protected]/Unknown Source)
at java.io.BufferedInputStream.read([email protected]/Unknown Source)
- locked <0x000000043b0b4858> (a java.lang.ProcessImpl$ProcessPipeInputStream)
at java.io.FilterInputStream.read([email protected]/Unknown Source)
at com.google.devtools.build.lib.shell.InputStreamSink$CopySink.run(InputStreamSink.java:97)
at com.google.devtools.build.lib.shell.Consumers$ClosingSink.run(Consumers.java:273)
at java.util.concurrent.Executors$RunnableAdapter.call([email protected]/Unknown Source)
at java.util.concurrent.FutureTask.run([email protected]/Unknown Source)
at java.util.concurrent.ThreadPoolExecutor.runWorker([email protected]/Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run([email protected]/Unknown Source)
at java.lang.Thread.run([email protected]/Unknown Source)

"globbing pool-5" #145 daemon prio=5 os_prio=0 cpu=3.15ms elapsed=528.92s tid=0x00007f25c01b9000 nid=0x514b waiting on condition [0x00007f260a9ee000]
java.lang.Thread.State: WAITING (parking)
at jdk.internal.misc.Unsafe.park([email protected]/Native Method)
- parking to wait for <0x00000004130850a8> (a com.google.devtools.build.lib.concurrent.NamedForkJoinPool)
at java.util.concurrent.locks.LockSupport.park([email protected]/Unknown Source)
at java.util.concurrent.ForkJoinPool.runWorker([email protected]/Unknown Source)
at java.util.concurrent.ForkJoinWorkerThread.run([email protected]/Unknown Source)

"ForkJoinPool.commonPool-worker-5" #146 daemon prio=5 os_prio=0 cpu=0.50ms elapsed=528.03s tid=0x00007f258c006800 nid=0x51b1 waiting on condition [0x00007f2660622000]
java.lang.Thread.State: WAITING (parking)
at jdk.internal.misc.Unsafe.park([email protected]/Native Method)
- parking to wait for <0x0000000412804080> (a java.util.concurrent.ForkJoinPool)
at java.util.concurrent.locks.LockSupport.park([email protected]/Unknown Source)
at java.util.concurrent.ForkJoinPool.runWorker([email protected]/Unknown Source)
at java.util.concurrent.ForkJoinWorkerThread.run([email protected]/Unknown Source)

"RxCachedWorkerPoolEvictor-1" #185 daemon prio=5 os_prio=0 cpu=1.16ms elapsed=520.33s tid=0x00007f2610464800 nid=0x51f4 waiting on condition [0x00007f26099da000]
java.lang.Thread.State: TIMED_WAITING (parking)
at jdk.internal.misc.Unsafe.park([email protected]/Native Method)
- parking to wait for <0x000000043b10bdf0> (a java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject)
at java.util.concurrent.locks.LockSupport.parkNanos([email protected]/Unknown Source)
at java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.awaitNanos([email protected]/Unknown Source)
at java.util.concurrent.ScheduledThreadPoolExecutor$DelayedWorkQueue.take([email protected]/Unknown Source)
at java.util.concurrent.ScheduledThreadPoolExecutor$DelayedWorkQueue.take([email protected]/Unknown Source)
at java.util.concurrent.ThreadPoolExecutor.getTask([email protected]/Unknown Source)
at java.util.concurrent.ThreadPoolExecutor.runWorker([email protected]/Unknown Source)
at java.util.concurrent.ThreadPoolExecutor$Worker.run([email protected]/Unknown Source)
at java.lang.Thread.run([email protected]/Unknown Source)

"VM Thread" os_prio=0 cpu=123.13ms elapsed=541.52s tid=0x00007f26f02d3000 nid=0x5029 runnable

"GC Thread#0" os_prio=0 cpu=56.19ms elapsed=541.53s tid=0x00007f26f0031800 nid=0x5024 runnable

"GC Thread#1" os_prio=0 cpu=47.96ms elapsed=540.90s tid=0x00007f26a0001000 nid=0x503a runnable

"GC Thread#2" os_prio=0 cpu=45.92ms elapsed=540.90s tid=0x00007f26a0002800 nid=0x503b runnable

"GC Thread#3" os_prio=0 cpu=58.14ms elapsed=540.90s tid=0x00007f26a0004000 nid=0x503c runnable

"GC Thread#4" os_prio=0 cpu=51.06ms elapsed=540.90s tid=0x00007f26a0005800 nid=0x503d runnable

"GC Thread#5" os_prio=0 cpu=49.18ms elapsed=540.90s tid=0x00007f26a0007000 nid=0x503e runnable

"GC Thread#6" os_prio=0 cpu=58.97ms elapsed=540.90s tid=0x00007f26a0008800 nid=0x503f runnable

"GC Thread#7" os_prio=0 cpu=49.90ms elapsed=540.90s tid=0x00007f26a000a800 nid=0x5040 runnable

"GC Thread#8" os_prio=0 cpu=53.93ms elapsed=540.90s tid=0x00007f26a000c000 nid=0x5041 runnable

"GC Thread#9" os_prio=0 cpu=49.88ms elapsed=540.90s tid=0x00007f26a000d800 nid=0x5042 runnable

"GC Thread#10" os_prio=0 cpu=62.06ms elapsed=540.90s tid=0x00007f26a000f000 nid=0x5043 runnable

"GC Thread#11" os_prio=0 cpu=47.18ms elapsed=540.90s tid=0x00007f26a0010800 nid=0x5044 runnable

"GC Thread#12" os_prio=0 cpu=47.00ms elapsed=540.90s tid=0x00007f26a0012000 nid=0x5045 runnable

"G1 Main Marker" os_prio=0 cpu=1.72ms elapsed=541.53s tid=0x00007f26f006f000 nid=0x5025 runnable

"G1 Conc#0" os_prio=0 cpu=29.22ms elapsed=541.53s tid=0x00007f26f0070800 nid=0x5026 runnable

"G1 Conc#1" os_prio=0 cpu=33.94ms elapsed=540.90s tid=0x00007f26b0001000 nid=0x5046 runnable

"G1 Conc#2" os_prio=0 cpu=31.92ms elapsed=540.89s tid=0x00007f26b0002800 nid=0x5047 runnable

"G1 Refine#0" os_prio=0 cpu=5.02ms elapsed=541.53s tid=0x00007f26f020d800 nid=0x5027 runnable

"G1 Refine#1" os_prio=0 cpu=2.13ms elapsed=529.64s tid=0x00007f26a4002800 nid=0x50fc runnable

"G1 Refine#2" os_prio=0 cpu=0.63ms elapsed=529.64s tid=0x00007f25f4003000 nid=0x50fd runnable

"G1 Refine#3" os_prio=0 cpu=0.50ms elapsed=520.38s tid=0x00007f25fc004800 nid=0x51d3 runnable

"G1 Young RemSet Sampling" os_prio=0 cpu=121.27ms elapsed=541.53s tid=0x00007f26f020f800 nid=0x5028 runnable
"VM Periodic Task Thread" os_prio=0 cpu=300.92ms elapsed=541.47s tid=0x00007f26f036a000 nid=0x5034 waiting on condition

JNI global refs: 41, weak refs: 0

Heap
garbage-first heap total 1032192K, used 83538K [0x0000000412800000, 0x0000000800000000)
region size 4096K, 16 young (65536K), 3 survivors (12288K)
Metaspace used 59768K, capacity 61146K, committed 61564K, reserved 1103872K
class space used 6568K, capacity 7110K, committed 7168K, reserved 1048576K

@CaptainCamelCase
Copy link

Have the same problem but with the Android Tutorial. Worked last week, after the weekend it doesn't. Ubuntu 18.04, Bazel 5.1.1, Java 11.

@CaptainCamelCase
Copy link

CaptainCamelCase commented May 2, 2022

Have the same problem but with the Android Tutorial. Worked last week, after the weekend it doesn't. Ubuntu 18.04, Bazel 5.1.1, Java 11.

Seems I hit issue #3494 or similar, having a lot of linux-sandbox processes stuck for some reason. Restarted the linux machine and it worked again.

@kgriepen
Copy link

kgriepen commented May 2, 2022

I'm also seeing this issue on the morning of Monday May 2. Last worked on Friday. Environment is Ubuntu 18.04.6, Bazel release 5.1.1, Java openjdk_11.0.14.1_11.54.26_x64

@meisterT
Copy link
Member

meisterT commented May 3, 2022

Interesting. From the stack trace above it looks like it is stuck in checking whether sandboxing is supported:

"grpc-command-0" https://github.com/bazelbuild/bazel/issues/29 daemon prio=5 os_prio=0 cpu=516.55ms elapsed=540.54s tid=0x00007f260c240800 nid=0x5052 in Object.wait() [0x00007f2660d23000]
java.lang.Thread.State: WAITING (on object monitor)
at java.lang.Object.wait([email protected]/Native Method)
- waiting on <0x000000043b01dbc0> (a java.lang.ProcessImpl)
at java.lang.Object.wait([email protected]/Unknown Source)
at java.lang.ProcessImpl.waitFor([email protected]/Unknown Source)
- waiting to re-lock in wait() <0x000000043b01dbc0> (a java.lang.ProcessImpl)
at com.google.devtools.build.lib.shell.JavaSubprocessFactory$JavaSubprocess.waitFor(JavaSubprocessFactory.java:91)
at com.google.devtools.build.lib.shell.FutureCommandResult.waitForProcess(FutureCommandResult.java:109)
at com.google.devtools.build.lib.shell.FutureCommandResult.get(FutureCommandResult.java:52)
at com.google.devtools.build.lib.shell.Command.execute(Command.java:263)
at com.google.devtools.build.lib.sandbox.LinuxSandboxedSpawnRunner.computeIsSupported(LinuxSandboxedSpawnRunner.java:98)
at com.google.devtools.build.lib.sandbox.LinuxSandboxedSpawnRunner.isSupported(LinuxSandboxedSpawnRunner.java:82)
- locked <0x000000043b01dda0> (a java.util.HashMap)
at com.google.devtools.build.lib.sandbox.SandboxModule.setup(SandboxModule.java:285)
at com.google.devtools.build.lib.sandbox.SandboxModule.registerSpawnStrategies(SandboxModule.java:154)

which is basically just running /bin/true in the sandbox (https://cs.opensource.google/bazel/bazel/+/master:src/main/java/com/google/devtools/build/lib/sandbox/LinuxSandboxedSpawnRunner.java;l=88;drc=11f7d8040fadc595589ee264561606dc2a83685d).

Can you please try running this and see if it hangs as well?

 $(bazel info install_base)/linux-sandbox /bin/true

I still wonder why this would be the case, but we could run it with a timeout to avoid hangs.

@meisterT meisterT added team-Local-Exec Issues and PRs for the Execution (Local) team awaiting-user-response Awaiting a response from the author and removed team-Local-Exec Issues and PRs for the Execution (Local) team team-Rules-Java Issues for Java rules labels May 3, 2022
@kgriepen
Copy link

kgriepen commented May 3, 2022

I work with rock626 so have a similar environment.

I ran the sandbox command and it does indeed hang.

@meisterT
Copy link
Member

meisterT commented May 3, 2022

if it hangs can you please try running under strace to see if that gives any clues?

@kgriepen
Copy link

kgriepen commented May 3, 2022

$ strace -c $(bazel info install_base)/linux-sandbox -- /bin/true
^Cstrace: Process 22586 detached

% time seconds usecs/call calls errors syscall
26.38 0.000460 7 66 rt_sigaction
19.04 0.000332 332 1 clone
11.18 0.000195 10 20 mmap
10.72 0.000187 13 14 mprotect
5.33 0.000093 12 8 openat
4.76 0.000083 8 10 close
4.64 0.000081 41 2 munmap
2.75 0.000048 7 7 read
2.01 0.000035 18 2 getdents
1.95 0.000034 4 8 fstat
1.72 0.000030 30 1 1 wait4
1.61 0.000028 4 8 8 access
1.03 0.000018 6 3 brk
1.03 0.000018 9 2 futex
0.86 0.000015 8 2 rt_sigprocmask
0.75 0.000013 13 1 pipe
0.69 0.000012 12 1 getcwd
0.69 0.000012 12 1 getuid
0.63 0.000011 11 1 getgid
0.46 0.000008 8 1 prctl
0.46 0.000008 8 1 arch_prctl
0.46 0.000008 8 1 set_tid_address
0.46 0.000008 8 1 prlimit64
0.40 0.000007 7 1 set_robust_list
0.00 0.000000 0 1 execve
------ ----------- ----------- --------- --------- ----------------
100.00 0.001744 164 9 total

@meisterT
Copy link
Member

meisterT commented May 3, 2022

Please run it again without -c so that we see in which syscall it hangs.

@kgriepen
Copy link

kgriepen commented May 3, 2022

$ strace $(bazel info install_base)/linux-sandbox -- /bin/true execve("/home/kgriepentrog/.cache/bazel/_bazel_kgriepentrog/install/79570a41fb8272e4808f43403af3b38c/linux-sandbox", ["/home/kgriepentrog/.cache/bazel/"..., "--", "/bin/true"], 0x7ffca0b22280 /* 81 vars */) = 0 brk(NULL) = 0xaf1000 access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory) access("/etc/ld.so.preload", R_OK) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/etc/ld.so.cache", O_RDONLY|O_CLOEXEC) = 3 fstat(3, {st_mode=S_IFREG|0644, st_size=127187, ...}) = 0 mmap(NULL, 127187, PROT_READ, MAP_PRIVATE, 3, 0) = 0x7f0e8840b000 close(3) = 0 access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/lib/x86_64-linux-gnu/libm.so.6", O_RDONLY|O_CLOEXEC) = 3 read(3, "\177ELF\2\1\1\3\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\200\272\0\0\0\0\0\0"..., 832) = 832 fstat(3, {st_mode=S_IFREG|0644, st_size=1700792, ...}) = 0 mmap(NULL, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f0e88409000 mmap(NULL, 3789144, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f0e87e64000 mprotect(0x7f0e88001000, 2093056, PROT_NONE) = 0 mmap(0x7f0e88200000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x19c000) = 0x7f0e88200000 close(3) = 0 access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/lib/x86_64-linux-gnu/librt.so.1", O_RDONLY|O_CLOEXEC) = 3 read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\0\"\0\0\0\0\0\0"..., 832) = 832 fstat(3, {st_mode=S_IFREG|0644, st_size=31680, ...}) = 0 mmap(NULL, 2128864, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f0e87c5c000 mprotect(0x7f0e87c63000, 2093056, PROT_NONE) = 0 mmap(0x7f0e87e62000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x6000) = 0x7f0e87e62000 close(3) = 0 access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/lib/x86_64-linux-gnu/libpthread.so.0", O_RDONLY|O_CLOEXEC) = 3 read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0000b\0\0\0\0\0\0"..., 832) = 832 fstat(3, {st_mode=S_IFREG|0755, st_size=144976, ...}) = 0 mmap(NULL, 2221184, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f0e87a3d000 mprotect(0x7f0e87a57000, 2093056, PROT_NONE) = 0 mmap(0x7f0e87c56000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x19000) = 0x7f0e87c56000 mmap(0x7f0e87c58000, 13440, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x7f0e87c58000 close(3) = 0 access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/usr/lib/x86_64-linux-gnu/libstdc++.so.6", O_RDONLY|O_CLOEXEC) = 3 read(3, "\177ELF\2\1\1\3\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\220\304\10\0\0\0\0\0"..., 832) = 832 fstat(3, {st_mode=S_IFREG|0644, st_size=1594864, ...}) = 0 mmap(NULL, 3702848, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f0e876b4000 mprotect(0x7f0e8782d000, 2097152, PROT_NONE) = 0 mmap(0x7f0e87a2d000, 49152, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x179000) = 0x7f0e87a2d000 mmap(0x7f0e87a39000, 12352, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x7f0e87a39000 close(3) = 0 access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/lib/x86_64-linux-gnu/libgcc_s.so.1", O_RDONLY|O_CLOEXEC) = 3 read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\300*\0\0\0\0\0\0"..., 832) = 832 fstat(3, {st_mode=S_IFREG|0644, st_size=96616, ...}) = 0 mmap(NULL, 2192432, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f0e8749c000 mprotect(0x7f0e874b3000, 2093056, PROT_NONE) = 0 mmap(0x7f0e876b2000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x16000) = 0x7f0e876b2000 close(3) = 0 access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory) openat(AT_FDCWD, "/lib/x86_64-linux-gnu/libc.so.6", O_RDONLY|O_CLOEXEC) = 3 read(3, "\177ELF\2\1\1\3\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\240\35\2\0\0\0\0\0"..., 832) = 832 fstat(3, {st_mode=S_IFREG|0755, st_size=2030928, ...}) = 0 mmap(NULL, 4131552, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f0e870ab000 mprotect(0x7f0e87292000, 2097152, PROT_NONE) = 0 mmap(0x7f0e87492000, 24576, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x1e7000) = 0x7f0e87492000 mmap(0x7f0e87498000, 15072, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x7f0e87498000 close(3) = 0 mmap(NULL, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f0e88407000 mmap(NULL, 12288, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f0e88404000 arch_prctl(ARCH_SET_FS, 0x7f0e88404740) = 0 mprotect(0x7f0e87492000, 16384, PROT_READ) = 0 mprotect(0x7f0e876b2000, 4096, PROT_READ) = 0 mprotect(0x7f0e88200000, 4096, PROT_READ) = 0 mprotect(0x7f0e87a2d000, 40960, PROT_READ) = 0 mprotect(0x7f0e87c56000, 4096, PROT_READ) = 0 mprotect(0x7f0e87e62000, 4096, PROT_READ) = 0 mprotect(0x417000, 4096, PROT_READ) = 0 mprotect(0x7f0e8842b000, 4096, PROT_READ) = 0 munmap(0x7f0e8840b000, 127187) = 0 set_tid_address(0x7f0e88404a10) = 12311 set_robust_list(0x7f0e88404a20, 24) = 0 rt_sigaction(SIGRTMIN, {sa_handler=0x7f0e87a42cb0, sa_mask=[], sa_flags=SA_RESTORER|SA_SIGINFO, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGRT_1, {sa_handler=0x7f0e87a42d50, sa_mask=[], sa_flags=SA_RESTORER|SA_RESTART|SA_SIGINFO, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigprocmask(SIG_UNBLOCK, [RTMIN RT_1], NULL, 8) = 0 prlimit64(0, RLIMIT_STACK, NULL, {rlim_cur=8192*1024, rlim_max=RLIM64_INFINITY}) = 0 brk(NULL) = 0xaf1000 brk(0xb12000) = 0xb12000 futex(0x7f0e87a3a09c, FUTEX_WAKE_PRIVATE, 2147483647) = 0 futex(0x7f0e87a3a0a8, FUTEX_WAKE_PRIVATE, 2147483647) = 0 prctl(PR_SET_PDEATHSIG, SIGKILL) = 0 rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0 rt_sigaction(SIGHUP, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGINT, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGQUIT, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGILL, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGTRAP, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGABRT, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGBUS, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGFPE, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGUSR1, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGSEGV, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGUSR2, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGPIPE, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGALRM, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGTERM, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGSTKFLT, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGCHLD, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGCONT, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGTSTP, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGTTIN, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGTTOU, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGURG, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGXCPU, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGXFSZ, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGVTALRM, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGPROF, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGWINCH, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGIO, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGPWR, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGSYS, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGRT_2, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGRT_3, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGRT_4, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGRT_5, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGRT_6, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGRT_7, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGRT_8, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGRT_9, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGRT_10, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGRT_11, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGRT_12, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGRT_13, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGRT_14, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGRT_15, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGRT_16, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGRT_17, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGRT_18, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGRT_19, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGRT_20, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGRT_21, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGRT_22, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGRT_23, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGRT_24, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGRT_25, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGRT_26, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGRT_27, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGRT_28, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGRT_29, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGRT_30, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGRT_31, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGRT_32, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGTTIN, {sa_handler=SIG_IGN, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGTTOU, {sa_handler=SIG_IGN, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 getcwd("/home/kgriepentrog/blt/app/main/core", 4096) = 37 getuid() = 1267266372 getgid() = 1267266372 openat(AT_FDCWD, "/proc/self/fd", O_RDONLY|O_NONBLOCK|O_CLOEXEC|O_DIRECTORY) = 3 fstat(3, {st_mode=S_IFDIR|0500, st_size=0, ...}) = 0 getdents(3, /* 6 entries */, 32768) = 144 getdents(3, /* 0 entries */, 32768) = 0 close(3) = 0 mmap(NULL, 1052672, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f0e88303000 pipe([3, 4]) = 0 clone(child_stack=0x7f0e88403000, flags=CLONE_NEWNS|CLONE_NEWIPC|CLONE_NEWUSER|CLONE_NEWPID|SIGCHLD) = 12314 close(4) = 0 read(3, "\0", 1) = 1 close(3) = 0 munmap(0x7f0e88303000, 1052672) = 0 rt_sigaction(SIGALRM, {sa_handler=0x4052a0, sa_mask=~[RTMIN RT_1], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 rt_sigaction(SIGTERM, {sa_handler=0x4052a0, sa_mask=~[RTMIN RT_1], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0 wait4(12314, 0x7fffcf65e76c, 0, 0x7fffcf65e780) = ? ERESTARTSYS (To be restarted if SA_RESTART is set) --- SIGWINCH {si_signo=SIGWINCH, si_code=SI_KERNEL} --- wait4(12314,

@kgriepen
Copy link

kgriepen commented May 3, 2022

Maybe unformatted makes it clearer.

$ strace $(bazel info install_base)/linux-sandbox -- /bin/true
execve("/home/kgriepentrog/.cache/bazel/_bazel_kgriepentrog/install/79570a41fb8272e4808f43403af3b38c/linux-sandbox", ["/home/kgriepentrog/.cache/bazel/"..., "--", "/bin/true"], 0x7ffca0b22280 /* 81 vars /) = 0
brk(NULL) = 0xaf1000
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
access("/etc/ld.so.preload", R_OK) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/etc/ld.so.cache", O_RDONLY|O_CLOEXEC) = 3
fstat(3, {st_mode=S_IFREG|0644, st_size=127187, ...}) = 0
mmap(NULL, 127187, PROT_READ, MAP_PRIVATE, 3, 0) = 0x7f0e8840b000
close(3) = 0
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/lib/x86_64-linux-gnu/libm.so.6", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\2\1\1\3\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\200\272\0\0\0\0\0\0"..., 832) = 832
fstat(3, {st_mode=S_IFREG|0644, st_size=1700792, ...}) = 0
mmap(NULL, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f0e88409000
mmap(NULL, 3789144, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f0e87e64000
mprotect(0x7f0e88001000, 2093056, PROT_NONE) = 0
mmap(0x7f0e88200000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x19c000) = 0x7f0e88200000
close(3) = 0
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/lib/x86_64-linux-gnu/librt.so.1", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\0"\0\0\0\0\0\0"..., 832) = 832
fstat(3, {st_mode=S_IFREG|0644, st_size=31680, ...}) = 0
mmap(NULL, 2128864, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f0e87c5c000
mprotect(0x7f0e87c63000, 2093056, PROT_NONE) = 0
mmap(0x7f0e87e62000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x6000) = 0x7f0e87e62000
close(3) = 0
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/lib/x86_64-linux-gnu/libpthread.so.0", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0000b\0\0\0\0\0\0"..., 832) = 832
fstat(3, {st_mode=S_IFREG|0755, st_size=144976, ...}) = 0
mmap(NULL, 2221184, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f0e87a3d000
mprotect(0x7f0e87a57000, 2093056, PROT_NONE) = 0
mmap(0x7f0e87c56000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x19000) = 0x7f0e87c56000
mmap(0x7f0e87c58000, 13440, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x7f0e87c58000
close(3) = 0
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/usr/lib/x86_64-linux-gnu/libstdc++.so.6", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\2\1\1\3\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\220\304\10\0\0\0\0\0"..., 832) = 832
fstat(3, {st_mode=S_IFREG|0644, st_size=1594864, ...}) = 0
mmap(NULL, 3702848, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f0e876b4000
mprotect(0x7f0e8782d000, 2097152, PROT_NONE) = 0
mmap(0x7f0e87a2d000, 49152, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x179000) = 0x7f0e87a2d000
mmap(0x7f0e87a39000, 12352, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x7f0e87a39000
close(3) = 0
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/lib/x86_64-linux-gnu/libgcc_s.so.1", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\300
\0\0\0\0\0\0"..., 832) = 832
fstat(3, {st_mode=S_IFREG|0644, st_size=96616, ...}) = 0
mmap(NULL, 2192432, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f0e8749c000
mprotect(0x7f0e874b3000, 2093056, PROT_NONE) = 0
mmap(0x7f0e876b2000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x16000) = 0x7f0e876b2000
close(3) = 0
access("/etc/ld.so.nohwcap", F_OK) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/lib/x86_64-linux-gnu/libc.so.6", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\2\1\1\3\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\240\35\2\0\0\0\0\0"..., 832) = 832
fstat(3, {st_mode=S_IFREG|0755, st_size=2030928, ...}) = 0
mmap(NULL, 4131552, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7f0e870ab000
mprotect(0x7f0e87292000, 2097152, PROT_NONE) = 0
mmap(0x7f0e87492000, 24576, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x1e7000) = 0x7f0e87492000
mmap(0x7f0e87498000, 15072, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x7f0e87498000
close(3) = 0
mmap(NULL, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f0e88407000
mmap(NULL, 12288, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f0e88404000
arch_prctl(ARCH_SET_FS, 0x7f0e88404740) = 0
mprotect(0x7f0e87492000, 16384, PROT_READ) = 0
mprotect(0x7f0e876b2000, 4096, PROT_READ) = 0
mprotect(0x7f0e88200000, 4096, PROT_READ) = 0
mprotect(0x7f0e87a2d000, 40960, PROT_READ) = 0
mprotect(0x7f0e87c56000, 4096, PROT_READ) = 0
mprotect(0x7f0e87e62000, 4096, PROT_READ) = 0
mprotect(0x417000, 4096, PROT_READ) = 0
mprotect(0x7f0e8842b000, 4096, PROT_READ) = 0
munmap(0x7f0e8840b000, 127187) = 0
set_tid_address(0x7f0e88404a10) = 12311
set_robust_list(0x7f0e88404a20, 24) = 0
rt_sigaction(SIGRTMIN, {sa_handler=0x7f0e87a42cb0, sa_mask=[], sa_flags=SA_RESTORER|SA_SIGINFO, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGRT_1, {sa_handler=0x7f0e87a42d50, sa_mask=[], sa_flags=SA_RESTORER|SA_RESTART|SA_SIGINFO, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigprocmask(SIG_UNBLOCK, [RTMIN RT_1], NULL, 8) = 0
prlimit64(0, RLIMIT_STACK, NULL, {rlim_cur=81921024, rlim_max=RLIM64_INFINITY}) = 0
brk(NULL) = 0xaf1000
brk(0xb12000) = 0xb12000
futex(0x7f0e87a3a09c, FUTEX_WAKE_PRIVATE, 2147483647) = 0
futex(0x7f0e87a3a0a8, FUTEX_WAKE_PRIVATE, 2147483647) = 0
prctl(PR_SET_PDEATHSIG, SIGKILL) = 0
rt_sigprocmask(SIG_SETMASK, [], NULL, 8) = 0
rt_sigaction(SIGHUP, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGINT, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGQUIT, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGILL, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGTRAP, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGABRT, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGBUS, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGFPE, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGUSR1, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGSEGV, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGUSR2, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGPIPE, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGALRM, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGTERM, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGSTKFLT, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGCHLD, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGCONT, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGTSTP, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGTTIN, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGTTOU, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGURG, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGXCPU, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGXFSZ, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGVTALRM, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGPROF, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGWINCH, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGIO, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGPWR, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGSYS, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGRT_2, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGRT_3, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGRT_4, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGRT_5, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGRT_6, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGRT_7, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGRT_8, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGRT_9, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGRT_10, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGRT_11, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGRT_12, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGRT_13, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGRT_14, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGRT_15, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGRT_16, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGRT_17, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGRT_18, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGRT_19, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGRT_20, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGRT_21, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGRT_22, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGRT_23, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGRT_24, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGRT_25, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGRT_26, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGRT_27, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGRT_28, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGRT_29, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGRT_30, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGRT_31, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGRT_32, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGTTIN, {sa_handler=SIG_IGN, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGTTOU, {sa_handler=SIG_IGN, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
getcwd("/home/kgriepentrog/blt/app/main/core", 4096) = 37
getuid() = 1267266372
getgid() = 1267266372
openat(AT_FDCWD, "/proc/self/fd", O_RDONLY|O_NONBLOCK|O_CLOEXEC|O_DIRECTORY) = 3
fstat(3, {st_mode=S_IFDIR|0500, st_size=0, ...}) = 0
getdents(3, /
6 entries /, 32768) = 144
getdents(3, /
0 entries */, 32768) = 0
close(3) = 0
mmap(NULL, 1052672, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7f0e88303000
pipe([3, 4]) = 0
clone(child_stack=0x7f0e88403000, flags=CLONE_NEWNS|CLONE_NEWIPC|CLONE_NEWUSER|CLONE_NEWPID|SIGCHLD) = 12314
close(4) = 0
read(3, "\0", 1) = 1
close(3) = 0
munmap(0x7f0e88303000, 1052672) = 0
rt_sigaction(SIGALRM, {sa_handler=0x4052a0, sa_mask=[RTMIN RT_1], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
rt_sigaction(SIGTERM, {sa_handler=0x4052a0, sa_mask=
[RTMIN RT_1], sa_flags=SA_RESTORER, sa_restorer=0x7f0e87a4f980}, NULL, 8) = 0
wait4(12314, 0x7fffcf65e76c, 0, 0x7fffcf65e780) = ? ERESTARTSYS (To be restarted if SA_RESTART is set)
--- SIGWINCH {si_signo=SIGWINCH, si_code=SI_KERNEL} ---
wait4(12314, 0x7fffcf65e76c, 0, 0x7fffcf65e780) = ? ERESTARTSYS (To be restarted if SA_RESTART is set)
--- SIGWINCH {si_signo=SIGWINCH, si_code=SI_KERNEL} ---
wait4(12314, ^Cstrace: Process 12311 detached
<detached ...>

@kgriepen
Copy link

kgriepen commented May 4, 2022

I verified that if I kill the hanging linux-sandbox command that Bazel continues on to build correctly. Good for a temporary workaround at least.

@meisterT
Copy link
Member

meisterT commented May 4, 2022

@kgriepen Can you please run this and upload the files (straceout*) somewhere?

strace -o straceout -ff $(bazel info install_base)/linux-sandbox -- /bin/true

@comius comius assigned meisterT and unassigned comius May 5, 2022
@kgriepen
Copy link

kgriepen commented May 5, 2022

The issue looks like it was caused by an update to the endpoint security that our org uses. Other symptoms were df and lsof hanging. The quick workaround was to pkill fusermount, but the update has been disabled and I no longer see Bazel hanging. I've contacted @rock626 to see if they still have the issue after updating and comment here.

Thanks so much @meisterT for your time in helping to debug!

meisterT added a commit to meisterT/bazel that referenced this issue May 6, 2022
This is to avoid hanging there forever in case the system is set up
incorrectly.
1s should be plenty to run `/bin/true`.

Fixes bazelbuild#15373.
meisterT added a commit to meisterT/bazel that referenced this issue May 6, 2022
This is to avoid hanging there forever in case the system is set up
incorrectly.
1s should be plenty to run `/bin/true`.

Fixes bazelbuild#15373.
@rock626
Copy link
Author

rock626 commented May 9, 2022

I am able to run bazel now after installing security updates and rebooting the machine.
Thanks @kgriepen for letting me know the issue and the fix.

@meisterT Thanks for the help and i am no longer seeing this issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
awaiting-user-response Awaiting a response from the author team-Local-Exec Issues and PRs for the Execution (Local) team type: bug untriaged
Projects
None yet
Development

Successfully merging a pull request may close this issue.

6 participants