Hi!
I wanted to use PackageKit’s support for systemd’s offline updates mechanism, to be able to install updates while the full system is not running, for stability purposes. It is also much more user friendly than running commands, especially for those folks who are coming from windows, and for those who were never really proficient in managing computers.
Since PackageKit talks with zypper, it shows changelogs, and as I understand PK’s zypper backend is prepared to not do dumb things (it even knows to update with "dup"on thumbleweed), theres nothing to lose, and everything to gain.
But, it does not seem to work. It just “fails” silently, without any system logs.
What can we do to put PackageKit’s offline updates functionality in working order?
In the rest of the post I’ll describe my findings.
I already replaced plasma5-pk-update
with discover-notifier
a few months ago, and so the update settings appeared in the KDE System Settings tool.
Currently it seems that KDE Discover is already able to prepare the updates, by talking to zypper to download all the updated packages.
/system-update
is also created, it points to /var/lib/PackageKit/prepared-update
, which contains the list of packages I requested to update.
But, despite that systemd then correctly starts the system for the system-update.target
, that quickly ends, because there is no service defined to install the updates.
I was puzzled, what is exactly missing, and why? This works on AlmaLinux (and as I understand all Fedora-like systems) and Linux Mint without much manual setup.
I have digged up the internet, and according to PK’s documentation, an executable called /usr/libexec/pk-offline-update
should be doing the update. On my Mint test system, this is executed by the packagekit-offline-update.service
unit.
But I cannot find official packages for my Leap system that provides these files.
On Mint, they are provided by the main packagekit
package, so I suppose they are intended to be part of the main package by the PK developers.
Beyond pk-offline-update
and the service unit, I also wonder whether the necessary Plymouth components are there to show the install progress indication.
I have looked up earlier discussions about the packagekit topic. There the topic either did not go into offline updates, or it was suggested that everyone should roll their own update scripts.
But why should we roll our own, possibly faulty update scripts, if theres a solution published by packagekit devs, that is actually being maintained by people who already know the pitfalls?