Skip to content

Bazel hangs indefinitely when OOMing #2946

Closed

Description

@damienmg

The machine it was running was running out of memory and the result from the test log was just stalling

cat ~/Downloads/test_killed_bazel_server.log 
exec ${PAGER:-/usr/bin/less} "$0" || exit 1
-----------------------------------------------------------------------------
bazel binary is at /home/ci/.cache/bazel/_bazel_ci/29502e488c6c26e35c2694f6f4eb1ffe/bazel-sandbox/5999971806873713228/execroot/linux-x86_64/bazel-out/local-fastbuild/bin/src/test/shell/integration/experimental_ui_test.runfiles/io_bazel/src/test/shell/bin
INFO: Reading 'startup' options from /home/ci/.cache/bazel/_bazel_ci/29502e488c6c26e35c2694f6f4eb1ffe/bazel-sandbox/5999971806873713228/execroot/linux-x86_64/_tmp/5dc9cbb6bafa5b9915cc309242565800/bazelrc: --output_user_root=/home/ci/.cache/bazel/_bazel_ci/29502e488c6c26e35c2694f6f4eb1ffe/bazel-sandbox/5999971806873713228/execroot/linux-x86_64/_tmp/5dc9cbb6bafa5b9915cc309242565800/root --host_javabase=/home/ci/.cache/bazel/_bazel_ci/29502e488c6c26e35c2694f6f4eb1ffe/bazel-sandbox/5999971806873713228/execroot/linux-x86_64/bazel-out/local-fastbuild/bin/src/test/shell/integration/experimental_ui_test.runfiles/local_jdk
INFO: $TEST_TMPDIR defined: output root default is '/home/ci/.cache/bazel/_bazel_ci/29502e488c6c26e35c2694f6f4eb1ffe/bazel-sandbox/5999971806873713228/execroot/linux-x86_64/_tmp/5dc9cbb6bafa5b9915cc309242565800'.
Extracting Bazel installation...
.............................................
INFO: Reading 'startup' options from /home/ci/.cache/bazel/_bazel_ci/29502e488c6c26e35c2694f6f4eb1ffe/bazel-sandbox/5999971806873713228/execroot/linux-x86_64/_tmp/5dc9cbb6bafa5b9915cc309242565800/bazelrc: --output_user_root=/home/ci/.cache/bazel/_bazel_ci/29502e488c6c26e35c2694f6f4eb1ffe/bazel-sandbox/5999971806873713228/execroot/linux-x86_64/_tmp/5dc9cbb6bafa5b9915cc309242565800/root --host_javabase=/home/ci/.cache/bazel/_bazel_ci/29502e488c6c26e35c2694f6f4eb1ffe/bazel-sandbox/5999971806873713228/execroot/linux-x86_64/bazel-out/local-fastbuild/bin/src/test/shell/integration/experimental_ui_test.runfiles/local_jdk
INFO: $TEST_TMPDIR defined: output root default is '/home/ci/.cache/bazel/_bazel_ci/29502e488c6c26e35c2694f6f4eb1ffe/bazel-sandbox/5999971806873713228/execroot/linux-x86_64/_tmp/5dc9cbb6bafa5b9915cc309242565800'.
____Loading package: @bazel_tools//tools/jdk
____Loading package: @bazel_tools//tools/cpp
____Loading package: @local_config_xcode//
____Loading package: @local_jdk//
____Loading package: @local_config_cc//
INFO: Reading 'startup' options from /home/ci/.cache/bazel/_bazel_ci/29502e488c6c26e35c2694f6f4eb1ffe/bazel-sandbox/5999971806873713228/execroot/linux-x86_64/_tmp/5dc9cbb6bafa5b9915cc309242565800/bazelrc: --output_user_root=/home/ci/.cache/bazel/_bazel_ci/29502e488c6c26e35c2694f6f4eb1ffe/bazel-sandbox/5999971806873713228/execroot/linux-x86_64/_tmp/5dc9cbb6bafa5b9915cc309242565800/root --host_javabase=/home/ci/.cache/bazel/_bazel_ci/29502e488c6c26e35c2694f6f4eb1ffe/bazel-sandbox/5999971806873713228/execroot/linux-x86_64/bazel-out/local-fastbuild/bin/src/test/shell/integration/experimental_ui_test.runfiles/local_jdk
INFO: $TEST_TMPDIR defined: output root default is '/home/ci/.cache/bazel/_bazel_ci/29502e488c6c26e35c2694f6f4eb1ffe/bazel-sandbox/5999971806873713228/execroot/linux-x86_64/_tmp/5dc9cbb6bafa5b9915cc309242565800'.
INFO: Reading 'startup' options from /home/ci/.cache/bazel/_bazel_ci/29502e488c6c26e35c2694f6f4eb1ffe/bazel-sandbox/5999971806873713228/execroot/linux-x86_64/_tmp/5dc9cbb6bafa5b9915cc309242565800/bazelrc: --output_user_root=/home/ci/.cache/bazel/_bazel_ci/29502e488c6c26e35c2694f6f4eb1ffe/bazel-sandbox/5999971806873713228/execroot/linux-x86_64/_tmp/5dc9cbb6bafa5b9915cc309242565800/root --host_javabase=/home/ci/.cache/bazel/_bazel_ci/29502e488c6c26e35c2694f6f4eb1ffe/bazel-sandbox/5999971806873713228/execroot/linux-x86_64/bazel-out/local-fastbuild/bin/src/test/shell/integration/experimental_ui_test.runfiles/local_jdk
INFO: $TEST_TMPDIR defined: output root default is '/home/ci/.cache/bazel/_bazel_ci/29502e488c6c26e35c2694f6f4eb1ffe/bazel-sandbox/5999971806873713228/execroot/linux-x86_64/_tmp/5dc9cbb6bafa5b9915cc309242565800'.
.
INFO: Reading 'startup' options from /home/ci/.cache/bazel/_bazel_ci/29502e488c6c26e35c2694f6f4eb1ffe/bazel-sandbox/5999971806873713228/execroot/linux-x86_64/_tmp/5dc9cbb6bafa5b9915cc309242565800/bazelrc: --output_user_root=/home/ci/.cache/bazel/_bazel_ci/29502e488c6c26e35c2694f6f4eb1ffe/bazel-sandbox/5999971806873713228/execroot/linux-x86_64/_tmp/5dc9cbb6bafa5b9915cc309242565800/root --host_javabase=/home/ci/.cache/bazel/_bazel_ci/29502e488c6c26e35c2694f6f4eb1ffe/bazel-sandbox/5999971806873713228/execroot/linux-x86_64/bazel-out/local-fastbuild/bin/src/test/shell/integration/experimental_ui_test.runfiles/local_jdk
INFO: $TEST_TMPDIR defined: output root default is '/home/ci/.cache/bazel/_bazel_ci/29502e488c6c26e35c2694f6f4eb1ffe/bazel-sandbox/5999971806873713228/execroot/linux-x86_64/_tmp/5dc9cbb6bafa5b9915cc309242565800'.
____Loading package: @bazel_tools//tools/cpp
____Loading package: @bazel_tools//tools/jdk
____Loading package: @local_config_xcode//
____Loading package: @local_config_cc//
____Loading package: @local_jdk//
INFO: Reading 'startup' options from /home/ci/.cache/bazel/_bazel_ci/29502e488c6c26e35c2694f6f4eb1ffe/bazel-sandbox/5999971806873713228/execroot/linux-x86_64/_tmp/5dc9cbb6bafa5b9915cc309242565800/bazelrc: --output_user_root=/home/ci/.cache/bazel/_bazel_ci/29502e488c6c26e35c2694f6f4eb1ffe/bazel-sandbox/5999971806873713228/execroot/linux-x86_64/_tmp/5dc9cbb6bafa5b9915cc309242565800/root --host_javabase=/home/ci/.cache/bazel/_bazel_ci/29502e488c6c26e35c2694f6f4eb1ffe/bazel-sandbox/5999971806873713228/execroot/linux-x86_64/bazel-out/local-fastbuild/bin/src/test/shell/integration/experimental_ui_test.runfiles/local_jdk
INFO: $TEST_TMPDIR defined: output root default is '/home/ci/.cache/bazel/_bazel_ci/29502e488c6c26e35c2694f6f4eb1ffe/bazel-sandbox/5999971806873713228/execroot/linux-x86_64/_tmp/5dc9cbb6bafa5b9915cc309242565800'.

Integration tests for bazel's experimental UI

** test_help_color_nobuild *****************************************************
                                                     [bazel development version]
Usage: bazel <command> <options> ...

Available commands:
  analyze-profile     Analyzes build profile data.
  build               Builds the specified targets.
  canonicalize-flags  Canonicalizes a list of bazel options.
  clean               Removes output files and optionally stops the server.
  coverage            Generates code coverage report for specified test targets.
  dump                Dumps the internal state of the bazel server process.
  fetch               Fetches external repositories that are prerequisites to the targets.
  help                Prints help for commands, or the index.
  info                Displays runtime info about the bazel server.
  license             Prints the license of this software.
  mobile-install      Installs targets to mobile devices.
  query               Executes a dependency graph query.
  run                 Runs the specified target.
  shutdown            Stops the bazel server.
  test                Builds and runs the specified test targets.
  version             Prints version information for bazel.

Getting more help:
  bazel help <command>
                   Prints help and options for <command>.
  bazel help startup_options
                   Options for the JVM hosting bazel.
  bazel help target-syntax
                   Explains the syntax for specifying targets.
  bazel help info-keys
                   Displays a list of keys used by the info command.
PASSED: test_help_color_nobuild

** test_terminal_title *********************************************************
Use --strategy=TestRunner=standalone to disable sandboxing for the failing actions.

We should at least notice something is wrong.

Activity

  1. added
    P2
    on May 5, 2017
  2. added this to the 0.7 milestone on May 5, 2017
  3. damienmg commented on May 5, 2017

    @damienmg
    ContributorAuthor
  4. djudd-stripe commented on Nov 29, 2017

    @djudd-stripe

    I have attached a thread dump for what I suspect is the same issue (simultaneously #3645 since we are running in a Docker container and I believe that's why we are OOMing). At a glance it looks like maybe a deadlock.

    bazel-threads.dump.txt

  5. djudd-stripe commented on Nov 30, 2017

    @djudd-stripe

    Nevermind, I think that thread dump was a hang due to something else (calling Bazel from a script inside Bazel). Sorry!

  6. added a commit that references this issue on Oct 7, 2018
  7. meisterT commented on May 11, 2020

    @meisterT
    Member

    The old CI doesn't exist anymore, this is no longer reproducible.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    P2category: misc > misctype: bug

    Type

    No type

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions