Software Updater phased updates ignores APT::Machine-ID

Bug #1979238 reported by halogen2
12
This bug affects 2 people
Affects Status Importance Assigned to Milestone
update-manager (Ubuntu)
Triaged
Undecided
Unassigned
Impish
Confirmed
Undecided
Unassigned
Jammy
Confirmed
Undecided
Unassigned
Kinetic
Triaged
Undecided
Unassigned

Bug Description

Environment:

$ lsb_release -rd
Description: Ubuntu 22.04 LTS
Release: 22.04
$ apt-cache policy update-manager
update-manager:
  Installed: 1:22.04.9
  Candidate: 1:22.04.9
  Version table:
 *** 1:22.04.9 500
        500 http://us.archive.ubuntu.com/ubuntu jammy/main amd64 Packages
        500 http://us.archive.ubuntu.com/ubuntu jammy/main i386 Packages
        100 /var/lib/dpkg/status

Steps to reproduce:

1) On an Ubuntu 22.04 system with all non-phased updates installed, check output of `apt list --upgradable` and `apt -o='Apt::Get::Always-Include-Phased-Updates=true' list --upgradable`. Make sure these outputs differ: there should be some phased updates, and some should not yet be phased in for this system.

2) create a file "/etc/apt/apt.conf.d/01aaa-synced-machineid" with the following contents -

APT {
  Machine-ID "0aac969489d35d412431192762b0beff";
}

(That UUID was chosen by running `dbus-uuidgen` until it produced a UUID that, when placed there, changed the output of `apt list --upgradable`.)

3) Verify with `apt list --upgradable` that the list of available phased upates is now different.

4) Run Software Updater and look at the list of available updates it offers.

Expected results:

At (4), Software Updater should offer the same set of updates that `apt list --upgradable` shows at (3).

Actual results:

At (4), Software Updater offers the set of updates that were offered at (1). It seems to completely ignore APT::Machine-ID, despite that being the official recommended way to synchronize phased updates across multiple machines - https://discourse.ubuntu.com/t/phased-updates-in-apt-in-21-04/20345

ProblemType: Bug
DistroRelease: Ubuntu 22.04
Package: update-manager 1:22.04.9
ProcVersionSignature: Ubuntu 5.15.0-39.42-generic 5.15.35
Uname: Linux 5.15.0-39-generic x86_64
ApportVersion: 2.20.11-0ubuntu82.1
Architecture: amd64
CasperMD5CheckResult: pass
CurrentDesktop: ubuntu:GNOME
Date: Mon Jun 20 14:43:08 2022
ExecutablePath: /usr/bin/update-manager
GsettingsChanges:
 b'com.ubuntu.update-manager' b'first-run' b'false'
 b'com.ubuntu.update-manager' b'launch-count' b'3'
 b'com.ubuntu.update-manager' b'launch-time' b'int64 1655750563'
 b'com.ubuntu.update-manager' b'show-details' b'true'
 b'com.ubuntu.update-manager' b'window-width' b'593'
InstallationDate: Installed on 2022-06-20 (0 days ago)
InstallationMedia: Ubuntu 22.04 LTS "Jammy Jellyfish" - Release amd64 (20220419)
InterpreterPath: /usr/bin/python3.10
PackageArchitecture: all
ProcEnviron:
 PATH=(custom, no user)
 XDG_RUNTIME_DIR=<set>
 LANG=en_US.UTF-8
 SHELL=/bin/bash
Python3Details: /usr/bin/python3.10, Python 3.10.4, python3-minimal, 3.10.4-0ubuntu2
PythonDetails: N/A
SourcePackage: update-manager
UpgradeStatus: No upgrade log present (probably fresh install)

Revision history for this message
halogen2 (halogen2) wrote :
Revision history for this message
Julian Andres Klode (juliank) wrote :

That's correct yes, update-managers implementation predates the apt one and was not removed, so it does not respect that setting (well it does on the apt layer, but will then disable updates based on real machine ID again).

Changed in update-manager (Ubuntu):
status: New → Triaged
tags: added: fr-2487
Revision history for this message
halogen2 (halogen2) wrote :

The steps to reproduce as written are no longer optimal on fully updated Ubuntu 22.04: seems `apt list --upgradable` no longer takes phased updates into account. Using `apt-get -s dist-upgrade` to obtain lists of updates from apt should still work.

Revision history for this message
Launchpad Janitor (janitor) wrote :

Status changed to 'Confirmed' because the bug affects multiple users.

Changed in update-manager (Ubuntu Impish):
status: New → Confirmed
Changed in update-manager (Ubuntu Jammy):
status: New → Confirmed
Revision history for this message
halogen2 (halogen2) wrote :

I found a workaround: create a file /etc/apt/apt.conf.d/90update-manager-use-apt-phasing with the following contents -

Update-Manager {
  Always-Include-Phased-Updates true;
}
APT {
  Get {
    Always-Include-Phased-Updates false;
  }
}

As discussed in this ubuntuforums thread: https://ubuntuforums.org/showthread.php?t=2478639&p=14116259&viewfull=1#post14116259

In case someone who wants to always install all available updates regardless of phasing is reading this: in your case, use the following instead -

Update-Manager {
  Always-Include-Phased-Updates true;
}
APT {
  Get {
    Always-Include-Phased-Updates true;
  }
}

To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.