fix: wait liveness probes through the PID-1 reaper - #14
Merged
Conversation
Cmd probes used Child::try_wait while waitpid(-1) already reaped the child, so micronet check failed with ECHILD and recycled network. Wait on the exit registry when the reaper is running, and add livenessProbe.failureThreshold so a single failed probe does not restart. Co-authored-by: Cursor <cursoragent@cursor.com>
cmd_timeout already covers run_shell_quiet_timeout expiry; the 200ms sleep check returned a code on CI instead of None. Co-authored-by: Cursor <cursoragent@cursor.com>
This file contains hidden or 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
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.
Summary
micronet check) raced the PID-1waitpid(-1)reaper and failed withECHILD(No child process (os error 10)).Child::wait.livenessProbe.failureThreshold(default 1) so a single failed probe does not restart a service.Confirmed on the hub:
microinit describe networkshowedliveness_failed (... No child process (os error 10))every ~96s, which ranmicronet teardownand dropped the LAN.Test plan
cargo test/cargo clippy --all-targets -- -D warningsmicroinit describe networkstays at 0 restarts; longping 192.168.0.5stays upMade with Cursor