What `apt` configuration file should the Never-Include-Phased-Updates flag be placed in?
Many older references on the internet say that one can opt out of 'phased updates' for Software Updater
by adding ‘Update-Manager::Never-Include-Phased-Updates “True”;’ to the configuration file “/etc/apt/apt.conf”.
My systems do not have that configuration file. To engage this option, should I create the file or add this line to one of the many other config files in /etc/apt
? And is this the correct syntax still?
After digging into the code...
Phased Updates is implemented by the file /usr/lib/python3/dist-packages/UpdateManager/Core/UpdateList.py
, which is provided by the package python3-update-manager
. Look around lines 185 and 360. The actual python code is apt.apt_pkg.config.find_b()
, which searches among all apt configs.
-
The string should simply say:
Update-Manager::Always-Include-Phased-Updates;
orUpdate-Manager::Never-Include-Phased-Updates;
. A True/False boolean is not needed or checked.You should be able to add that line to any config file in /etc/apt/apt.conf.d/. Or create your own:
/etc/apt/apt.conf.d/99-Phased-Updates
. -
The presence of phased updates, or the presence of Never-Include-Phased-Updates should both be logged in your /var/log/apt/ logs when Update Manager (also known as Software Updater) runs.
-
Other apt-based package managers (Apt, Synaptic, Ubuntu Software, Unattended Upgrades) don't use Update Manager code, do not use phased updates, and ignore the presence of the config string (it won't be logged)..Apt began using Phased Updates starting with 21.04.
The apt settings are slightly different than the Update Manager settings:
Update-Manager::Always-Include-Phased-Updates;
APT::Get::Always-Include-Phased-Updates: True;
Update-Manager::Never-Include-Phased-Updates;
APT::Get::Never-Include-Phased-Updates: True;
- We're talking about spreading updates (usually) across a few days -- for most users that will make no difference. You can get updates early by disabling Phased Updates (
Update-Manager::Never-Include-Phased-Updates;
) There is no way to game Phased Updates so that you get updates later than everybody else.
For fun: The current status of phased-update packages in the repositories is at https://people.canonical.com/~ubuntu-archive/phased-updates.html
Advice for New Users: The purpose of Phased Updates is to protect you from an occasional buggy update. Let it do that. Advanced users who want to disable this feature know how to recover from those.