This blog is part of a series of technical blogs leading up to the release of openSUSE Leap 15. All of the blogs provide a use case regarding openSUSE Leap and the packages available in the distribution. Happy reading.
Transactional Updates is one of the exciting new features available in the upcoming release of openSUSE Leap 15, which is scheduled to be officially released May 25.
Contributed by the Kubic Project, Transactional Updates provides openSUSE systems with a method of updating the operating system and its packages in an entirely ‘atomic’ way. Updates are either applied to the system all together in a single transaction, or not at all. This happens without influencing the running system. If an update fails, or if the successful update is deemed to be incompatible or otherwise incorrect, it can be discarded to immediately return the system to its previous functioning state.
This differs from existing alternatives that already exist in the open source world. Some users use a rather exorbitant approach of maintaining multiple versions of their system in multiple partitions on disk to switch between the partitions to address a fear of tampering with a perfectly running system.
This juggling approach works, but takes an exorbitant amount of disk storage and maintenance efforts. More modern approaches like using ostree and snap attempt to address these problems and bring atomic/transactional updates to their users. However, these solutions have unintended consequence as users, developers, and partnering software vendors all learn new ways of managing their systems and existing packages cannot be re-used, which require either repackging or conversion. All of this develops to a situation where adopters need to redesign their mindsets, systems, tools and company policies to work with these clever tools. These workarounds have some key flaws that Kubic’s Transactional Updates feature strives to avoid.
Under the hood, Transactional Updates are made simple. Utilising the same btrfs, snapper, and zypper technologies that are trusted defaults in openSUSE Leap, Transactional Updates do something very similar to the traditional snapshots and rollbacks in Leap. However, Transactional Updates it never touches the running system. Instead of patching the current system, the transactional-update tool creates a new snapshot. All of the operations required by the update are carried out into a snapshot that ensures the current system is untouched with no changes impacting the running system.