Skip to content

Run bootc install failed with STORAGE_OPTS=additionalimagestore=/run/host-container-storage on FCOS #174

@HuijingHei

Description

@HuijingHei

Use bcvk to start quay.io/fedora/fedora-coreos:testing-devel libvirt VM with --bind-storage-ro, then run bootc install failed.

  • Start VM with --bind-storage-ro
sudo bcvk libvirt run --name test --filesystem xfs --disk-size 20G --bind-storage-ro --firmware uefi-secure quay.io/fedora/fedora-coreos:testing-devel
sudo bcvk libvirt ssh test
  • Run bootc install with env STORAGE_OPTS=additionalimagestore=/run/host-container-storage
podman run --rm --privileged -v /dev:/dev -v /var/lib/containers:/var/lib/containers -v /:/target \
--pid=host --security-opt label=type:unconfined_t \
localhost/bootc-integration:latest \
env BOOTC_BOOTLOADER_DEBUG=1 RUST_LOG=trace STORAGE_OPTS=additionalimagestore=/run/host-container-storage bootc install to-existing-root --skip-fetch-check --acknowledge-destructive --root-ssh-authorized-keys /target/root/.ssh/bcvk-id_rsa.pub --karg=console=ttyS0,115200n8

....
DEBUG open_image: opening image self=ImageProxy imgref="containers-storage:quay.io/curl/curl-base:latest"
TRACE open_image:impl_request_with_fds: sending request OpenImage self=ImageProxy imgref="containers-storage:quay.io/curl/curl-base:latest" self=ImageProxy method="OpenImage"
error: Installing to filesystem: resolving bound image quay.io/curl/curl-base:latest: failed to invoke method OpenImage: overlay: can't stat imageStore dir /run/host-container-storage: stat /run/host-container-storage: no such file or directory

Additionally, from the error logs can not find /run/host-container-storage, the workaround is when running podman, add -v /run/host-container-storage:/run/host-container-storage.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions