Skip to content

test/e2e: inject synthetic ext4 kmsg lines instead of a real fault#1305

Open
DigitalVeer wants to merge 1 commit into
kubernetes:masterfrom
DigitalVeer:fix/970-ext4-kmsg-injection
Open

test/e2e: inject synthetic ext4 kmsg lines instead of a real fault#1305
DigitalVeer wants to merge 1 commit into
kubernetes:masterfrom
DigitalVeer:fix/970-ext4-kmsg-injection

Conversation

@DigitalVeer

@DigitalVeer DigitalVeer commented Jul 8, 2026

Copy link
Copy Markdown
Contributor

The ext4 e2e test got skipped in #970. problem-maker triggered a real ext4 error on the boot disk, and on kernel 6.5+ this shut down the whole filesystem instead of just remounting it read-only. This caused sshd to die, making the test lose its ssh connection.

Since NPD only reads /dev/kmsg, it does not need a real fault, and the other existing problem makers do not attempt to emulate a real fault (they inject into kmsg). This reenables the test, drops a stale "stays healthy" check, and updates the problem-maker README to reflect the synthetic injection.

fixes #970

NONE

@kubernetes-prow kubernetes-prow Bot added the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Jul 8, 2026
@kubernetes-prow

Copy link
Copy Markdown
Contributor

[APPROVALNOTIFIER] This PR is NOT APPROVED

This pull-request has been approved by: DigitalVeer
Once this PR has been reviewed and has the lgtm label, please assign klueska for approval. For more information see the Code Review Process.

The full list of commands accepted by this bot can be found here.

Details Needs approval from an approver in each of these files:

Approvers can indicate their approval by writing /approve in a comment
Approvers can cancel approval by writing /approve cancel in a comment

@kubernetes-prow kubernetes-prow Bot added the cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. label Jul 8, 2026
@kubernetes-prow kubernetes-prow Bot requested a review from klueska July 8, 2026 20:57
@kubernetes-prow kubernetes-prow Bot added the needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. label Jul 8, 2026
@kubernetes-prow kubernetes-prow Bot requested a review from yujuhong July 8, 2026 20:57
@kubernetes-prow

Copy link
Copy Markdown
Contributor

Hi @DigitalVeer. Thanks for your PR.

I'm waiting for a kubernetes member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work.

Tip

We noticed you've done this a few times! Consider joining the org to skip this step and gain /lgtm and other bot rights. We recommend asking approvers on your previous PRs to sponsor you.

Once the patch is verified, the new status will be reflected by the ok-to-test label.

I understand the commands that are listed here.

Details

Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes-sigs/prow repository.

@kubernetes-prow kubernetes-prow Bot added the size/M Denotes a PR that changes 30-99 lines, ignoring generated files. label Jul 8, 2026
@DigitalVeer DigitalVeer force-pushed the fix/970-ext4-kmsg-injection branch from d6454d7 to 5ae5fc6 Compare July 8, 2026 21:33
@kubernetes-prow kubernetes-prow Bot added size/L Denotes a PR that changes 100-499 lines, ignoring generated files. and removed size/M Denotes a PR that changes 30-99 lines, ignoring generated files. labels Jul 8, 2026
@DigitalVeer DigitalVeer force-pushed the fix/970-ext4-kmsg-injection branch from 5ae5fc6 to 97d816b Compare July 8, 2026 22:12
@kubernetes-prow kubernetes-prow Bot added the do-not-merge/invalid-commit-message Indicates that a PR should not merge because it has an invalid commit message. label Jul 8, 2026
@DigitalVeer DigitalVeer force-pushed the fix/970-ext4-kmsg-injection branch from 97d816b to 839319b Compare July 8, 2026 22:13
@kubernetes-prow kubernetes-prow Bot removed the do-not-merge/invalid-commit-message Indicates that a PR should not merge because it has an invalid commit message. label Jul 8, 2026
@DigitalVeer DigitalVeer force-pushed the fix/970-ext4-kmsg-injection branch 2 times, most recently from 637fe50 to 02b5e71 Compare July 8, 2026 22:30
The Ext4FilesystemError problem-maker wrote to
/sys/fs/ext4/sda1/trigger_fs_error, a real fault on the boot disk. On kernel
6.5+ a real ext4 error shuts down the whole filesystem instead of remounting
it read-only, so sshd dies and the e2e test loses its ssh connection. The
ext4 metric assertions have been skipped because of this (issue 970).

NPD only reads /dev/kmsg, so it does not need a real fault. OOMKill and
DockerHung already inject their log lines into kmsg. Do the same for ext4.

- write the two ext4 error lines to /dev/kmsg instead of triggering a fault
- un-skip the ext4 metrics test; drop the "stays healthy" check (with no
  real fault there is nothing to survive, and the metric scrape already
  proves NPD is alive)
- update the problem-maker README

Signed-off-by: Veer Singh <8453348+digitalveer@users.noreply.github.com>
@DigitalVeer DigitalVeer force-pushed the fix/970-ext4-kmsg-injection branch from 02b5e71 to ea78733 Compare July 8, 2026 22:44
@kubernetes-prow kubernetes-prow Bot added size/S Denotes a PR that changes 10-29 lines, ignoring generated files. and removed size/L Denotes a PR that changes 100-499 lines, ignoring generated files. labels Jul 8, 2026
@DigitalVeer DigitalVeer marked this pull request as ready for review July 9, 2026 08:44
@kubernetes-prow kubernetes-prow Bot removed the do-not-merge/work-in-progress Indicates that a PR should not merge because it is a work in progress. label Jul 9, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

cncf-cla: yes Indicates the PR's author has signed the CNCF CLA. needs-ok-to-test Indicates a PR that requires an org member to verify it is safe to test. size/S Denotes a PR that changes 10-29 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

pull-npd-e2e-test failing ssh handshake

1 participant