Hi Eric, I confirm that this behaviour can only be reproduced in 'uu' context and only in 'shutdown mode'.
I can also confirm that the upgrade process is now OK in Bionic with your test package : - unattended-upgrades version after the test package installation : ii unattended-upgrades 1.1ubuntu1.18.04.6+testpkgb1 all automatic installation of security upgrades - dpkg status for linux-cloud-tools-common after reboot + 'uu' in 'shutdown mode' : ii linux-cloud-tools-common 4.15.0-36.39 all Linux kernel version specific cloud tools for version 4.15.0 - APT logs for linux-cloud-tools-common : Start-Date: 2018-11-02 16:28:56 Commandline: /usr/bin/unattended-upgrade Upgrade: linux-cloud-tools-common:amd64 (4.15.0-34.37, 4.15.0-36.39) End-Date: 2018-11-02 16:29:01 Would it also be possible to backport the fix in Xenial, as this version is also impacted ? Thanks a lot for your help. -- You received this bug notification because you are a member of Kernel Packages, which is subscribed to linux in Ubuntu. https://bugs.launchpad.net/bugs/1796376 Title: Bug #1739107 fix causes linux-cloud-tools-common not to be upgradable with unattended-upgrades on shutdown mode Status in linux package in Ubuntu: Invalid Status in unattended-upgrades package in Ubuntu: Fix Released Status in linux source package in Bionic: Invalid Status in unattended-upgrades source package in Bionic: Confirmed Status in linux source package in Cosmic: Invalid Status in unattended-upgrades source package in Cosmic: Fix Released Status in linux source package in Disco: Invalid Status in unattended-upgrades source package in Disco: Fix Released Bug description: Since the following linux-cloud-tools-common package versions : Xenial : 4.4.0-135.161 Bionic : 4.15.0-34.37 the Systemd service unit file for hv-kvp-daemon has been modified with new dependencies that make the package unable to be upgraded with unattended-upgrades on shutdown mode. Unattended-upgrades hangs with the linux-cloud-tools-common package during "Preparing to unpack". The server restarts after the unattended-upgrades service timeout expires. - Package state after reboot : iFR linux-cloud-tools-common 4.15.0-34.37 all Linux kernel version specific cloud tools for version 4.15.0 - Unattended-upgrades dpkg logs : Log started: 2018-10-05 17:59:04 (Reading database ... 52043 files and directories currently installed.) Preparing to unpack .../linux-cloud-tools-common_4.15.0-36.39_all.deb ... Log ended: 2018-10-05 18:00:54 - Impact : The current impact is very important as all security updates are blocked until you manually fix each server with : dpkg --configure -a apt install --only-upgrade linux-cloud-tools-common - Workaround/Fix : As a simple straightforward fix, replacing : Before=shutdown.target cloud-init-local.service walinuxagent.service with : Before=shutdown.target walinuxagent.service makes the package upgradable during shutdown. To manage notifications about this bug go to: https://bugs.launchpad.net/ubuntu/+source/linux/+bug/1796376/+subscriptions -- Mailing list: https://launchpad.net/~kernel-packages Post to : kernel-packages@lists.launchpad.net Unsubscribe : https://launchpad.net/~kernel-packages More help : https://help.launchpad.net/ListHelp