How exit to Unlocked: hotfix

Hi guys, i needed to edit /usr/share/containers/containers.conf so for some reason i have done
sudo ostree admin unlock --hotfix, now how if i check the status i get:

fedora:fedora/41/x86_64/silverblue
                  Version: 41.20250306.0 (2025-03-06T01:54:36Z)
               BaseCommit: aea39d2145d6689ca7527fb1f05065fa94360df557f8cdd92ea4b1d38423f9d1
             GPGSignature: Valid signature by 466CF2D8B60BC3057AA9453ED0622462E99D6AD1
          LayeredPackages: akmod-nvidia distrobox gnome-session-xsession gnome-tweaks podman-gvproxy podman-machine qemu qemu-img
                           xorg-x11-drv-nvidia xorg-x11-drv-nvidia-cuda xorg-x11-xinit
                 Unlocked: hotfix

how can i “exit” the hotfix mode without rollback?

You unlocked it … can you not just lock it?

Please try sudo ostree admin --help to see what options you have? Mostly it explains what you will achieve with the instructions in the help modus.

I have done sudo ostree admin --help and it give me:

Builtin "admin" Commands:
  cleanup            Delete untagged deployments and repository objects
  config-diff        Diff current /etc configuration versus default
  deploy             Checkout revision REFSPEC as the new default deployment
  lock-finalization  Change the finalization locking state of the staged deployment
  init-fs            Initialize a root filesystem
  os-init            Initialize empty state for given operating system
  stateroot-init     Initialize empty state for given operating system
  pin                Change the "pinning" state of a deployment, INDEX can be >= 0 or one of booted, pending or rollback strings
  post-copy          Update the repo and deployments as needed after a copy
  set-origin         Set Origin and create a new origin file
  status             List deployments
  switch             Construct new tree from REFSPEC and deploy it
  undeploy           Delete deployment INDEX
  set-default        Make deployment INDEX the default
  unlock             Make the current deployment mutable (as a hotfix or development)
  upgrade            Construct new tree from current origin and deploy it, if it changed
  kargs              Change kernel arguments

I think is the lock-finalization that i should do? I have tryed with that byt i get
error: No staged deployment

Would using, /etc/containers.conf or /etc/containers.conf.d/*.conf be easier?

You could also look into systemd-sysext but I think that would be overkill if you can use etc.

Doing an update or a rollback to a previous deployment should do it. As others said, you should copy the file in /etc and edit it there instead of modifying files in /usr.

1 Like

Yeah, i’m a idiot, thank you guys, i have made a rebase (rollback not possible, last one was broken) and make a copy in /etc

1 Like