- Notifications
You must be signed in to change notification settings - Fork2.9k
libpod: fix healthchecks not executing every interval on linux#27330
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 ourterms of service andprivacy statement. We’ll occasionally send you account related emails.
Already on GitHub?Sign in to your account
base:main
Are you sure you want to change the base?
Conversation
mheon commentedOct 20, 2025
Good change, code LGTM |
[APPROVALNOTIFIER] This PR isAPPROVED This pull-request has been approved by:mheon,winterqt The full list of commands accepted by this bot can be foundhere. The pull request process is describedhere Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
mheon commentedOct 20, 2025
For testing, I would recommend doing something likehttps://github.com/containers/podman/blob/main/test/e2e/healthcheck_run_test.go#L59-L76 with a shorter interval and a runtime long enough to convince systemd to fail (or, with your patch, not fail) |
Luap99 commentedOct 20, 2025
test/e2e does never run healtchecks via systemd timers, they get disabled there via env var. |
winterqt commentedOct 20, 2025
Unfortunately having some trouble running the system tests on my work machine :( Can try to write a test and run it through CI if y'all would be fine with that? |
Cockpit tests failed for commit191bbff.@martinpitt,@jelly,@mvollmer please check. |
[NON-BLOCKING] Packit jobs failed. @containers/packit-build please check. Everyone else, feel free to ignore. |
mheon commentedOct 20, 2025
Sure, if you can't get the tests to run |
A friendly reminder that this PR had no activity for 30 days. |
By default, systemd sets a limit of how many times a service can start,which means that if you have a healthcheck that runs more often than thelimits, systemd will refuse to start it with a message like "Start requestrepeated too quickly." emitted to the journal.Signed-off-by: Winter M <winter@antithesis.com>Signed-off-by: Paul Holzinger <pholzing@redhat.com>
Luap99 commentedNov 26, 2025
I did amend the commit with a small fix to verify the systemd unit setting, actually running the test on a short interval in CI and writing something flake free seemed impossible. Also your code change didn't quite work because the argument must go before the podman binary otherwise the argument was passed to the podman command not systemd. But I did verify locally this works now. |
By default, systemd sets a limit of how many times a service can start, which means that if you have a healthcheck that runs more often than the limits, systemd will refuse to start it with a message like "Start request repeated too quickly." emitted to the journal.
I'm not familiar enough with the e2e test suite to confidently write a test for this -- hints appreciated! :)
Does this PR introduce a user-facing change?