Fedora Account System
Red Hat Associate
Red Hat Customer
Running Fedora 44 Gnome 50 I've had an issue that I was prompted (via checkbox) to "Install pending software updates" that has persisted despite numerous restarts into offline transactions. While troubleshooting this it led me to an issue regarding dnf and the GsDnf5-plugin What I found: - dnf update found no outstanding packages to update - There were nothing in PackageKit explaining the "missing updates" - pkcon refresh force and get-updates found nothing - I stopped the gnome-software user service and restarted with --verbose to see what was happening: 09:41:24:049 GsDnf5 Creating new session 09:41:24:087 Gs running GetOfflineUpdateState job, elapsed time since creation 37ms - Exploring the /var/lib/dnf folder i found the ./offline folder, with a subfolder packages filed with rpms from the last week. - Testing some installed versions against the rpms I found that they all matched - rpm version == installed version. - running dnf offline status it returned a message containing “The system has been modified since the offline transaction was prepared.” - running dnf offline clean caused all of the rpms (indeed the entire /var/lib/dnf/offline folder) to be deleted - This resolved the issue with the persisting "Install pending software updates" Probable cause: - gnome-softwares automatic install of new software (or is it dnf-automatic ?) schedules an offline update. - This causes rpms to be downloaded to /var/lib/dnf/offline for offline install - Before rebooting I instead manually ran dnf update, to update my systemThe rpms in /var/lib/dnf/offline were however NOT cleaned, but left in place. See https://github.com/rpm-software-management/dnf5/issues/2831 - On entering "offline install" mode installing the packages probably then failed the install as all the rpm were already installed, this did however NOT lead to them being cleaned up - After logging in to fedora anew gnome-software still thinks there are uninstalled updates - The "Install pending software updates" checkbox persists... Possible fix? I am not familiar with your codebase, nor with how GsDnf5 determines if there are pending updates, but based on the behaviour above it seems to check /var/lib/dnf/offline. This will give a false positive when dnf does not clean up the offline packages when user does a manual dnf update. Maybe either checking dnf offline status and if it gives a warning about "system changes" calling dnf offline clean before proceeding with checking for pending updates?The problem will probably reoccur and will make sure to dump everything to logs then to share in this issue. PS: I tried posting this to the gnome-software gitlab project, but was told that this issue is upstream and to file the issue here at bugzilla.redhat.com Reproducible: Sometimes Steps to Reproduce: 1.Wait for automatic updates to notify you that there are pending/available updates 2.Instead of installing during Shutdown via "Install pending software updates" instead run dnf update manually Actual Results: See a persistent "Install pending software updates" in the Shutdown/Reboot dialog despite there being no updates to install Expected Results: Manual install of packages via dnf update should clear those packages from being marked as "Pending software updates", removing the checkbox from the Shutdown/Reboot dialogs
I think should be fixed by https://github.com/rpm-software-management/dnf5/pull/2736 can you still reproduce it with dnf5 >= 5.4.3.0? It was released to Fedoras only about a week ago.
I will check next time the situation with "Install pending software updates" arises again. Checked my version and I'm on 5.4.3.0 as of now. Will return and post here then!
Still an issue on dnf 5.4.3.0: ``` ╰─❮ dnf --version dnf5 version 5.4.3.0 dnf5 plugin API version 2.0 libdnf5 version 5.4.3.0 libdnf5 plugin API version 2.2 Loaded dnf5 plugins: name: builddep version: 1.0.0 API version: 2.0 name: changelog version: 1.0.0 API version: 2.0 name: config-manager version: 0.1.0 API version: 2.0 name: copr version: 0.1.0 API version: 2.0 name: needs_restarting version: 1.0.0 API version: 2.0 name: repoclosure version: 1.0.0 API version: 2.0 name: repomanage version: 1.0.0 API version: 2.0 name: reposync version: 1.0.0 API version: 2.0 Loaded libdnf5 plugins: name: appstream version: 1.0.0 API version: 2.0 name: expired-pgp-keys version: 1.0.0 API version: 2.1 ``` I waited until I got a GNOME notification that updates need to be installed. Immediately ran: ``` ╰─❮ sudo dnf offline status [sudo] password for torep: The system has been modified since the offline transaction was prepared. The offline transaction initiated by the following command is no longer valid: dnf5daemon-server To reschedule, run the command above. To clean up, run `dnf5 offline clean`. ``` I ran shutdown with the "Install pending software updates" checked TWICE, it did not appear that anything happened in "offline transaction"-mode. 1) dnf offline status gives the exact same output 2) There are rpms pending in /var/lib/dnf/offline/packages matches the packages listed by running dnf update (did not yet run this) ``` ╭─ /var/lib/dnf/offline/packages 12:25:50 ╰─❮ ll .rw-r--r--@ 136M root root 7 Sep 11:53 chromium-152.0.7977.82-1.fc44.x86_64.rpm .rw-r--r--@ 15M root root 7 Sep 11:53 chromium-common-152.0.7977.82-1.fc44.x86_64.rpm .rw-r--r--@ 183M root root 7 Sep 11:54 claude-desktop-unofficial-1.46388.2-3.2.4-1.x86_64.rpm .rw-r--r--@ 3.1M root root 7 Sep 11:53 gegl04-0.4.70-5.fc44.x86_64.rpm .rw-r--r--@ 28k root root 7 Sep 11:53 gegl04-matting-levin-0.4.70-5.fc44.x86_64.rpm .rw-r--r--@ 200M root root 7 Sep 11:53 joplin-3.7.16-1.rp.fc44.taw.x86_64.rpm .rw-r--r--@ 104k root root 7 Sep 11:53 librepo-1.21.0-2.fc44.x86_64.rpm .rw-r--r--@ 121k root root 7 Sep 11:53 libwmf-0.2.16-1.fc44.x86_64.rpm .rw-r--r--@ 79k root root 7 Sep 11:53 libwmf-lite-0.2.16-1.fc44.x86_64.rpm ╰─❮ sudo dnf update Updating and loading repositories: Repositories loaded. Package Arch Version Repository Size Upgrading: chromium x86_64 0:152.0.7977.82-1.fc44 updates 345.3 MiB replacing chromium x86_64 0:152.0.7977.75-1.fc44 updates 345.3 MiB chromium-common x86_64 0:152.0.7977.82-1.fc44 updates 65.5 MiB replacing chromium-common x86_64 0:152.0.7977.75-1.fc44 updates 65.5 MiB claude-desktop-unofficial x86_64 0:1.46388.2-3.2.4.fc42 claude-desktop-unofficial 583.0 MiB replacing claude-desktop-unofficial x86_64 0:1.40609.1-3.2.3.fc42 claude-desktop-unofficial 574.2 MiB gegl04 x86_64 0:0.4.70-5.fc44 updates 13.8 MiB replacing gegl04 x86_64 0:0.4.70-2.fc44 fedora 13.8 MiB gegl04-matting-levin x86_64 0:0.4.70-5.fc44 updates 39.4 KiB replacing gegl04-matting-levin x86_64 0:0.4.70-2.fc44 fedora 39.4 KiB joplin x86_64 0:3.7.16-1.rp.fc44.taw copr:copr.fedorainfracloud.o 196.5 MiB replacing joplin x86_64 0:3.6.16-1.rp.fc44.taw copr:copr.fedorainfracloud.o 156.9 MiB librepo x86_64 0:1.21.0-2.fc44 updates 253.1 KiB replacing librepo x86_64 0:1.21.0-1.fc44 updates 253.1 KiB libwmf x86_64 0:0.2.16-1.fc44 updates 420.7 KiB replacing libwmf x86_64 0:0.2.13-9.fc44 fedora 420.7 KiB libwmf-lite x86_64 0:0.2.16-1.fc44 updates 167.9 KiB replacing libwmf-lite x86_64 0:0.2.13-9.fc44 19278be6a81040f5b6cbc7bacea5 159.4 KiB ``` 3) Now I run dnf update and confirm. Output ends with: ``` Warning: Pending offline transaction has been invalidated. To reschedule, run: dnf5daemon-server Complete! ``` 4) Running dnf offline status it is NOT reset: ``` ╰─❮ sudo dnf offline status The system has been modified since the offline transaction was prepared. The offline transaction initiated by the following command is no longer valid: dnf5daemon-server To reschedule, run the command above. To clean up, run `dnf5 offline clean`. ``` 5) The "Install pending software updates" is still there...
6) Rebooting with "Install..." checked again takes me to "offline transaction"-mode where nothing appears to happen 7) On rebooting the "Install..." checkbox is still there and dnf offline status shows the exact same output: ``` ╰─❮ sudo dnf offline status [sudo] password for torep: The system has been modified since the offline transaction was prepared. The offline transaction initiated by the following command is no longer valid: dnf5daemon-server To reschedule, run the command above. To clean up, run `dnf5 offline clean`. ``` A side-observation that may (or may not?) be insignificant is that when I run the Shutdown option with the "Install..." box checked it does not turn off the machine, rather it just restarts it.
Note that PackageKit is not used at all anymore since Fedora 44.
*** This bug has been marked as a duplicate of bug 2529146 ***