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

The issue is caused by incompatibility between llvm 14 provided in ubuntu-22.04 image and the much newer kernel configured with high-entropy ASLR. #3481

Open
Ucg2c3 opened this issue Oct 1, 2024 · 0 comments

Comments

@Ucg2c3
Copy link

Ucg2c3 commented Oct 1, 2024

          The issue is caused by incompatibility between llvm 14 provided in ubuntu-22.04 image and the much newer kernel configured with high-entropy ASLR.

In 20240304.1.0:

$ sudo sysctl -a | grep vm.mmap.rnd
vm.mmap_rnd_bits = 28
vm.mmap_rnd_compat_bits = 8

In 20240310.1.0:

$ sudo sysctl -a | grep vm.mmap.rnd
vm.mmap_rnd_bits = 32
vm.mmap_rnd_compat_bits = 16

The isue was fixed in newer versions of llvm:
llvm/llvm-project@fb77ca0
https://reviews.llvm.org/D148280

So, we either need:

  1. an updated version of llvm/clang that will be compatible with a new kernel.
  2. or a kernel config change to reduce the entropy.
  3. or a global sysctl change to set vm.mmap_rnd_bits = 28.

As a workaround the following addition to the workflow makes builds to work with a new image:

    - name: Fix kernel mmap rnd bits
      # Asan in llvm 14 provided in ubuntu 22.04 is incompatible with
      # high-entropy ASLR in much newer kernels that GitHub runners are
      # using leading to random crashes: https://reviews.llvm.org/D148280
      run: sudo sysctl vm.mmap_rnd_bits=28

Originally posted by @igsilya in actions/runner-images#9491 (comment)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant