Skip to content

Commit

Permalink
Work around a TSAN issue with newer kernels
Browse files Browse the repository at this point in the history
The ThreadSanitizer version currently available from Fedora 39
repositories is unable to cope with very high ASLR entropy, which is the
default in some recent Linux distributions [1].  This causes all
TSAN-enabled builds to fail on the affected systems with an error like:

    FATAL: ThreadSanitizer: unexpected memory mapping 0x7d00e0772000-0x7d00e0c00000

Work around the problem by reducing ASLR entropy for all TSAN-enabled
builds until the problem is resolved upstream.

[1] google/sanitizers#1716

(cherry picked from commit 05b09f2)
  • Loading branch information
kempniu authored and pspacek committed Mar 21, 2024
1 parent 46c7aa2 commit eed3250
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -306,6 +306,7 @@ stages:
<<: *default_triggering_rules
stage: build
before_script:
- sysctl vm.mmap_rnd_bits=28 || true # https://gitlab.isc.org/isc-projects/bind9/-/issues/4649
- test -w "${CCACHE_DIR}" && export PATH="/usr/lib/ccache:${PATH}"
- test -n "${OUT_OF_TREE_WORKSPACE}" && mkdir "${OUT_OF_TREE_WORKSPACE}" && cd "${OUT_OF_TREE_WORKSPACE}"
script:
Expand Down Expand Up @@ -364,6 +365,7 @@ stages:
<<: *default_triggering_rules
stage: system
before_script:
- sysctl vm.mmap_rnd_bits=28 || true # https://gitlab.isc.org/isc-projects/bind9/-/issues/4649
- test -n "${OUT_OF_TREE_WORKSPACE}" && cp -r bin/tests/system/* "${OUT_OF_TREE_WORKSPACE}/bin/tests/system/" && cd "${OUT_OF_TREE_WORKSPACE}"
- *setup_interfaces
script:
Expand Down Expand Up @@ -440,6 +442,7 @@ stages:
<<: *default_triggering_rules
stage: unit
before_script:
- sysctl vm.mmap_rnd_bits=28 || true # https://gitlab.isc.org/isc-projects/bind9/-/issues/4649
- test -n "${OUT_OF_TREE_WORKSPACE}" && cd "${OUT_OF_TREE_WORKSPACE}"
script:
- make -j${TEST_PARALLEL_JOBS:-1} -k unit V=1
Expand Down Expand Up @@ -488,6 +491,7 @@ stages:
.respdiff: &respdiff_job
stage: system
before_script:
- sysctl vm.mmap_rnd_bits=28 || true # https://gitlab.isc.org/isc-projects/bind9/-/issues/4649
- autoreconf -fi
- *configure
- make -j${BUILD_PARALLEL_JOBS:-1} V=1
Expand Down

0 comments on commit eed3250

Please sign in to comment.