Skip to content

Conversation

@HuijingHei
Copy link
Contributor

On rawhide, the /boot is subvol instead of separate partition, we need to use the same option in the created deployment.

Fixes #1849

Copy link
Contributor

@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request enhances the install to-filesystem command to correctly handle systems where /boot is a subvolume, such as on Fedora Rawhide. It achieves this by reading the /boot entry from the target filesystem's /etc/fstab to preserve its mount options. The implementation is clean, using or_else to fall back to the previous logic of using the boot partition's UUID if an fstab entry isn't found. This change is consistent with similar logic in install_reset. The code is correct and well-implemented.

bootc deployment

On rawhide, the /boot is subvol instead of separate partition, we
need to use the same option in the created deployment.

Fixes bootc-dev#1849

Signed-off-by: Huijing Hei <hhei@redhat.com>
Copy link
Collaborator

@cgwalters cgwalters left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks so much for digging into this! It looks like there's a backup in the testing farm queue but we can merge after seeing the rawhide branch be green.

boot_uuid
.as_deref()
.map(|boot_uuid| MountSpec::new_uuid_src(boot_uuid, "/boot"))
// Read /etc/fstab to get boot entry, but only use it if it's UUID-based
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hum...I think we can unconditionally propagate this; I don't think we need to filter to UUID only.

Copy link
Contributor Author

@HuijingHei HuijingHei Dec 17, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes, I tried without condition firstly, but the install test failed with

$ sudo podman run --rm --privileged --pid=host -v /:/target -v /tmp/xshell-tmp-dir-1/test_authorized_keys:/test_authorized_keys localhost/bootc-integration-install bootc install to-filesystem --acknowledge-destructive --karg=foo=bar --replace=alongside --root-ssh-authorized-keys=/test_authorized_keys /target
test replace=alongside with ssh keys and a karg, and SELinux disabled ... Installing image: docker://localhost/bootc-integration-install:latest
Digest: sha256:f718c825e84eb8f5f3854b815a282ef80773a5f2320e5effe0c885a3146a5e83
error: Installing to filesystem: /boot is not specified via UUID= (this is currently required)

See https://github.com/bootc-dev/bootc/actions/runs/20265544961/job/58187786591

@henrywang henrywang merged commit f6b7ec8 into bootc-dev:main Dec 17, 2025
46 checks passed
@HuijingHei HuijingHei deleted the fix-rawhide branch December 17, 2025 08:25
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area/install Issues related to `bootc install`

Projects

None yet

Development

Successfully merging this pull request may close these issues.

rawhide tests "failing with error: Status: loading sysroot: Unexpected state: /run/ostree-booted found, but no /boot/loader directory"

3 participants