Can I Increase deployments in rpm-ostree?

fedora@fedora~$ rpm-ostree status
State: idle
Deployments:
● fedora:fedora/42/x86_64/silverblue
                  Version: 42.20250521.0 (2025-05-21T00:46:26Z)
               BaseCommit: fa8f3b7e5e25e27420d00b328c93e6856792cadaf15ed0139ec6436c480f8330
             GPGSignature: Valid signature by B0F4950458F69E1150C6C5EDC8AC4916105EF944
      RemovedBasePackages: firefox firefox-langpacks 138.0.4-1.fc42
          LayeredPackages: gnome-tweaks

  fedora:fedora/42/x86_64/silverblue
                  Version: 42.20250520.0 (2025-05-20T01:00:29Z)
               BaseCommit: d90e17d59c4182d793e62aaeff57cf39b850341819aa80518b2394cd6102c362
             GPGSignature: Valid signature by B0F4950458F69E1150C6C5EDC8AC4916105EF944
      RemovedBasePackages: firefox firefox-langpacks 138.0.3-1.fc42
          LayeredPackages: gnome-tweaks

Is it possible to increase the number of available deployments, for example, to 6? There is a problem with flatpak in the latest releases, and I have nowhere to roll back to because there are no later deployments…

You can keep additional deployments available by “pinning” the deployment you want to retain with the ostree admin pin command.

The argument for the pin command is the index number of the deployment. Pinning the deployment with index 0 would pin the currently booted deployment in your example. Pinning the deployment with index 1 would pin the roll-back deployment in your example.

Alternatively, if you wanted to roll-back to an older release, you can deploy older releases from the ostree server.

  1. Fetch the list of older commits from the fedora ostree repo with the command ostree pull --commit-metadata-only --depth=-1 fedora:fedora/42/x86_64/silverblue.
  2. List the available commits with ostree log fedora:fedora/42/x86_64/silverblue
  3. Deploy the commit with rpm-ostree deploy <commit hash>
1 Like

If the issue is with specific Flatpaks, then you could prevent them from being updated with flatpak mask.

it’s something in the system packages, applications freeze when trying to open any file, and all of them, after rolling back to the previous deployment problem has been fixed

I know that you can pin commits with your hands, but still, it’s inconvenient that you just can’t force the system save more than 2 deployments automatically…

It wouldn’t hurt to allow more deployments to stick around without needing to pin and manage all that.

1 Like

I found an upstream issue asking for support for more than 2 deployments:

Given that it is over 8 years old and has never been implemented, I am not hopeful of any progress being made.

It may be more useful to raise this RFE in the bootc community, as that is the direction that Atomic Desktops are heading in and where most of the development is currently happening.

Although it is not the topic of the post. I experienced the similar problem. You can check if xdg-desktop-portal crashes when you try to open any file in flatpak apps: journalctl --user-unit xdg-desktop-portal.service -b

If xdg-desktop-portal is the culprit, it is probably the issue in the recent version of xdg-desktop-portal (x-d-p crashes or does not allow portal operations if Flatpak app does not export APP_ID.desktop · Issue #1718 · flatpak/xdg-desktop-portal · GitHub). xdg-desktop-portal 1.20.1 requires a desktop entry for flatpak apps but org.gnome.NautilusPreviewer does not provide one.

Upgrading xdg-desktop-portal to 1.20.3 in updates-testing repo is supposed to solve the problem. Or you can write a desktop file for org.gnome.NautilusPreviewer manually.