Skip to content

snapm: check and exit with an error when run on Image Mode / ostree deployments #998

Description

@bmr-cymru

The snapm snapset create command currently fails on Image Mode systems due to attempting to create a default boom OsProfile when /boot is read-only:

# snapm snapset create --size-policy 80%FREE stssnapset1 /mnt/thinlvmntdir'
ERROR:root:Failed to create snapset: WARNING - No boom configuration found: attempting to generate defaults in /boot
Failed to create boom directory layout in /boot: [Errno 30] Read-only file system: '/boot/boom'

This happens regardless of whether the user requested a bootable/revert boot entry (-b/-r).

It would be simple to fix the boom OsProfile initialisation to only happen if needed (boot entries requested), but for the near term it would be better to just check for the deployment type and exit early if Image Mode / ostree is found:

# snapm snapset create --size-policy 80%FREE stssnapset1 /mnt/thinlvmntdir'
ERROR: Image Mode deployments are currently unsupported 

Properly supporting Image Mode requires changes across snapm, boom-boot, and likely bootc: this is complicated (both to implement and document/explain), and the value of this is currently uncertain.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    EnhancementNew feature or requestUI/UXUser interface and experience

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions