-
Notifications
You must be signed in to change notification settings - Fork 22
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
test: skip the symlink part of test_touch_file() in GH Actions #436
Merged
jamacku
merged 2 commits into
redhat-plumbers:rhel-8.10.0
from
mrc0mmand:test-touch-file-symlink
Jun 25, 2024
Merged
test: skip the symlink part of test_touch_file() in GH Actions #436
jamacku
merged 2 commits into
redhat-plumbers:rhel-8.10.0
from
mrc0mmand:test-touch-file-symlink
Jun 25, 2024
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
github-actions
bot
added
tracker/missing
Formerly needs-bz
pr/needs-ci
Formerly needs-ci
pr/needs-review
Formerly needs-review
labels
Mar 13, 2024
Commit validationTracker - Missing issue tracker ✋ The following commits need an inspection
Tracker validation🔴 Missing tracker or Unknown tracker type; type: 'unknown' Pull Request validationSuccess🟢 CI - All checks have passed |
mrc0mmand
force-pushed
the
test-touch-file-symlink
branch
3 times, most recently
from
March 13, 2024 11:01
2f166d9
to
e578600
Compare
The latest GH Action runners started using 32-bit entropy for ASLR, which makes it incompatible with llvm-14. This was fixed in later llvm releases, but these aren't available on Ubuntu Jammy (22.04). Let's reduce the ASLR entropy to 28-bit, which should make llvm happy again, until the issue is resolved. See: actions/runner-images#9491
mrc0mmand
force-pushed
the
test-touch-file-symlink
branch
3 times, most recently
from
March 13, 2024 11:41
4658efa
to
6d3afdf
Compare
The first commit should be needed only for the next couple of days, until the GH Actions runners are fixed. |
Our (RHEL 8) touch_file() is not clever enough and does chmod() on a symlink, which fails with EOPNOTSUPP on newer kernels. This is not an issue on the RHEL 8 kernel, where doing chmod() on a symlink works (albeit only on tmpfs) but in GH Actions we run in a container, and with the underlying kernel doing chmod() on a symlink fails even on tmpfs: RHEL 8: ~# mount -t tmpfs tmpfs /tmp ~# (cd /tmp; ln -s symlink dangling; ln -s /etc/os-release symlink) ~# (cd /var/tmp; ln -s symlink dangling; ln -s /etc/os-release symlink) ~# gcc -o main main.c -D_GNU_SOURCE ~# ./main /tmp/dangling chmod(/proc/self/fd/3)=0 (0) ~# ./main /tmp/symlink chmod(/proc/self/fd/3)=0 (0) ~# ./main /var/tmp/dangling chmod(/proc/self/fd/3)=-1 (95) ~# ./main /var/tmp/symlink chmod(/proc/self/fd/3)=-1 (95) Newer kernel: ~# uname -r 6.7.4-200.fc39.x86_64 ~# ./main /tmp/dangling chmod(/proc/self/fd/3)=-1 (95) ~# ./main /tmp/symlink chmod(/proc/self/fd/3)=-1 (95) ~# ./main /var/tmp/dangling chmod(/proc/self/fd/3)=-1 (95) ~# ./main /var/tmp/symlink chmod(/proc/self/fd/3)=-1 (95) Backporting the necessary patches would be way too risky so late in the RHEL 8 cycle, so let's just skip the offending test when running in GH Actions. To do that we have to jump through a couple of hoops, since RHEL 8 systemd can't detect docker. Oh well. See: redhat-plumbers#434 RHEL-only
mrc0mmand
force-pushed
the
test-touch-file-symlink
branch
from
March 13, 2024 11:59
6d3afdf
to
d5867f6
Compare
mrc0mmand
changed the title
test: skip the symlink part of test_touch_file() in containers
test: skip the symlink part of test_touch_file() in GH Actions
Mar 13, 2024
msekletar
approved these changes
Jun 11, 2024
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Our (RHEL 8) touch_file() is not clever enough and does chmod() on a symlink, which fails with EOPNOTSUPP on newer kernels. This is not an issue on the RHEL 8 kernel, where doing chmod() on a symlink works (albeit only on tmpfs) but in GH Actions we run in a container, and with the underlying kernel doing chmod() on a symlink fails even on tmpfs:
RHEL 8:
Newer kernel:
Backporting the necessary patches would be way too risky so late in the RHEL 8 cycle, so let's just skip the offending test when running in a container. This should work around this issue in GH Actions, but still run the test on C8S/RHEL8 machines.
See: #434
RHEL-only
Opening this without any tracker, since there might not be a next minor release, but we still might need the "fix" for z-streams.