Bug 52974 - Update to UCS 5.0 fails if libvirtd is installed and not autoremoved
Update to UCS 5.0 fails if libvirtd is installed and not autoremoved
Status: CLOSED FIXED
Product: UCS
Classification: Unclassified
Component: Virtualization - KVM
UCS 5.0
Other Linux
: P5 normal (vote)
: UCS 5.0
Assigned To: Sönke Schwardt-Krummrich
Jürn Brodersen
:
Depends on:
Blocks:
  Show dependency treegraph
 
Reported: 2021-03-22 21:27 CET by Sönke Schwardt-Krummrich
Modified: 2021-05-25 16:00 CEST (History)
0 users

See Also:
What kind of report is it?: Development Internal
What type of bug is this?: ---
Who will be affected by this bug?: ---
How will those affected feel about the bug?: ---
User Pain:
Enterprise Customer affected?:
School Customer affected?:
ISV affected?:
Waiting Support:
Flags outvoted (downgraded) after PO Review:
Ticket number:
Bug group (optional):
Max CVSS v3 score:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Sönke Schwardt-Krummrich univentionstaff 2021-03-22 21:27:40 CET
The update to UCS 5.0 fails if libvirt-daemon is installed and not automatically removed in preup.sh because libvirt-daemon is kept as a dependency or marked as manually installed.

invoke-rc.d: initscript virtlogd, action "start" failed.
ESC[0;1;32m●ESC[0m virtlogd.service - Virtual machine log manager
   Loaded: loaded (ESC]8;;file://ucs-9961/lib/systemd/system/virtlogd.service^G/lib/systemd/system/virtlogd.serviceESC]8;;^G; indirect; vendor preset: enabl
ed)
   Active: ESC[0;1;32mactive (running)ESC[0m since Fri 2021-02-26 10:39:41 CET; 4h 32min ago
     Docs: ESC]8;;man:virtlogd(8)^Gman:virtlogd(8)ESC]8;;^G
           ESC]8;;https://libvirt.org^Ghttps://libvirt.orgESC]8;;^G
 Main PID: 8210 (virtlogd)
    Tasks: 2 (limit: 4915)
   Memory: 1.6M
   CGroup: /system.slice/virtlogd.service
           └─8210 /usr/sbin/virtlogd

Feb 26 10:39:41 ucs-9961 systemd[1]: Started Virtual machine log manager.
Feb 26 15:12:11 ucs-9961 systemd[1]: Reloading Virtual machine log manager.
Feb 26 15:12:11 ucs-9961 systemd[1]: Reloaded Virtual machine log manager.
Feb 26 15:12:14 ucs-9961 systemd[1]: ESC[0;1;39mESC[0;1;31mESC[0;1;39mDependency failed for Virtual machine log manager.ESC[0m
Feb 26 15:12:14 ucs-9961 systemd[1]: ESC[0;1;39mESC[0;1;31mESC[0;1;39mvirtlogd.service: Job virtlogd.service/start failed with result 'dependency'.ESC[0m
dpkg: Fehler beim Bearbeiten des Paketes libvirt-daemon-system (--configure):
 »installiertes libvirt-daemon-system-Skript des Paketes post-installation«-Unterprozess gab den Fehlerwert 1 zurück

This is a known upstream bug:
bugs.debian.org/cgi-bin/bugreport.cgi?bug=905772

And can be reproduced on a 4.4-7 system:
- univention-app install uvmm
- apt-mark manual libvirt-daemon to keep libvirt
- Remove uvmm packages
- univention-upgrade to UCS 5.0
Comment 1 Sönke Schwardt-Krummrich univentionstaff 2021-03-22 21:44:20 CET
Solution:
stop and mask service prior to the update:
- systemctl stop libvirtd.service
- systemctl mask libvirtd.service
- systemctl stop virtlogd.service
- systemctl mask virtlogd.service
Comment 2 Sönke Schwardt-Krummrich univentionstaff 2021-03-25 17:42:45 CET
The services are libvirtd and virtlogd are now stopped and masked in preup.sh. The old state in saved in a UCRV (update/service/libvirt/${service}) and restored in postup.sh.

[5.0-0] f365e26055 Bug #52974: bump version
[5.0-0] c26b098b59 Bug #52974: add changelog entry
[5.0-0] a824ac1e4a Bug #52974: disable libvirtd during update to prevent aborting update
Comment 3 Sönke Schwardt-Krummrich univentionstaff 2021-03-25 17:49:40 CET
Package: univention-updater
Version: 15.0.3-33A~5.0.0.202103251739
Branch: ucs_5.0-0
Comment 4 Sönke Schwardt-Krummrich univentionstaff 2021-03-31 12:54:15 CEST
[5.0-0] 26aca1ecc8 Bug #52974: small fixes in postup.sh for restarting libvirt et al

Package: univention-updater
Version: 15.0.3-35A~5.0.0.202103311251
Branch: ucs_5.0-0
Comment 5 Jürn Brodersen univentionstaff 2021-04-07 17:56:48 CEST
Changes are looking good

Update with running libvirtd.service -> OK
Changelog -> OK
Comment 6 Florian Best univentionstaff 2021-05-25 16:00:35 CEST
UCS 5.0 has been released:
 https://docs.software-univention.de/release-notes-5.0-0-en.html
 https://docs.software-univention.de/release-notes-5.0-0-de.html

If this error occurs again, please use "Clone This Bug".