systemd: serialize generated initrd fsck device probes - #18640
Draft
Pawel Winogrodzki (PawelWMS) wants to merge 1 commit into
Draft
systemd: serialize generated initrd fsck device probes#18640Pawel Winogrodzki (PawelWMS) wants to merge 1 commit into
Pawel Winogrodzki (PawelWMS) wants to merge 1 commit into
Conversation
Wrap generated initrd root and /usr filesystem checks with udevadm lock so udev probing cannot overlap metadata updates. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com> Copilot-Session: bb0e6716-4886-4e95-9efe-71dcde8687d6
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.
What
systemd-fstab-generatorso generated initrd root and/usrfilesystem checks run throughudevadm lock.systemd-fsck./usrfilesystem checks.Why
systemd-udevdcan probe filesystem metadata whilefsckis still updating it. Serializing the writer against udev's shared whole-disk lock prevents udev from observing transient metadata and removing filesystem identity links before the mount begins.Scope
This option targets only generator-synthesized initrd
systemd-fsck-root.serviceandsystemd-fsck-usr.serviceunits. Static root and instantiated post-switch-root checks remain unchanged. Draft #18639 explores the complementary static drop-in option.Risk
fsckfrom starting and fails the generated unit./usrpartitions on one physical disk serialize instead of checking concurrently.Verification
test-fstab-generatorfixtures and added generated/usrcoverage.git diff --check.