#977346 unattended-upgrades: Does not find packages, that can be upgraded

#977346#5
Date:
2020-12-14 09:02:15 UTC
From:
To:
Dear Debian folks,


On one user laptop with Debian sid/unstable, unattended-upgrades does
not find upgradable packages.

 From a dry run:

```
2020-12-14 09:51:17,335 INFO Checking if system is running on battery is
skipped. Please install powermgmt-base package to check power status and
skip installing updates when the system is running on battery.
2020-12-14 09:51:17,339 INFO Starting unattended upgrades script
2020-12-14 09:51:17,339 INFO Allowed origins are:
origin=Debian,codename=buster,label=Debian,
origin=Debian,codename=buster,label=Debian-Security,
origin=Debian,codename=buster-security,label=Debian-Security
2020-12-14 09:51:17,339 INFO Initial blacklist:
2020-12-14 09:51:17,339 INFO Initial whitelist (not strict):
2020-12-14 09:51:22,899 INFO No packages found that can be upgraded
unattended and no pending auto-removals
2020-12-14 09:51:22,900 INFO The list of kept packages can't be
calculated in dry-run mode.
```

But upgradable packages are there:

```
$ apt list --upgradable
Listing... Done
autoconf/unstable,unstable 2.69-12 all [upgradable from: 2.69-11.1]
dde-qt5integration/unstable 5.0.0-2.1+b2 amd64 [upgradable from:
5.0.0-2.1+b1]
fonts-font-awesome/unstable,unstable 5.0.10+really4.7.0~dfsg-4 all
[upgradable from: 5.0.10+really4.7.0~dfsg-2]
gcc-8-base/unstable 8.4.0-5 amd64 [upgradable from: 8.3.0-7]
gir1.2-gdkpixbuf-2.0/unstable 2.42.2+dfsg-1 amd64 [upgradable from:
2.40.0+dfsg-10]
gir1.2-gtk-3.0/unstable 3.24.24-1 amd64 [upgradable from: 3.24.23-3]
gir1.2-handy-0.0/unstable 0.0.13-3 amd64 [upgradable from: 0.0.13-2]
gir1.2-handy-1/unstable 1.0.2-1+b1 amd64 [upgradable from: 1.0.2-1]
gir1.2-json-1.0/unstable 1.6.0-2 amd64 [upgradable from: 1.6.0-1]
gnome-maps/unstable 3.38.2-1 amd64 [upgradable from: 3.38.1.1-1]
gtk-update-icon-cache/unstable 3.24.24-1 amd64 [upgradable from: 3.24.23-3]
htop/unstable 3.0.3-2 amd64 [upgradable from: 3.0.3-1+b1]
intel-media-va-driver/unstable 20.4.3+dfsg1-1 amd64 [upgradable from:
20.4.2+dfsg1-1]
libboost-dev/unstable 1.74.0.3 amd64 [upgradable from: 1.71.0.3]
libcmis-0.5-5v5/unstable 0.5.2-2+b2 amd64 [upgradable from: 0.5.2-2+b1]
libdtkwidget2/unstable 2.1.1-1.1+b3 amd64 [upgradable from: 2.1.1-1.1+b2]
libgail-3-0/unstable 3.24.24-1 amd64 [upgradable from: 3.24.23-3]
libgdk-pixbuf-2.0-0/unstable 2.42.2+dfsg-1 amd64 [upgradable from:
2.40.0+dfsg-10]
libgdk-pixbuf2.0-bin/unstable 2.42.2+dfsg-1 amd64 [upgradable from:
2.40.0+dfsg-10]
libgdk-pixbuf2.0-common/unstable,unstable 2.42.2+dfsg-1 all [upgradable
from: 2.40.0+dfsg-10]
libgtk-3-0/unstable 3.24.24-1 amd64 [upgradable from: 3.24.23-3]
libgtk-3-bin/unstable 3.24.24-1 amd64 [upgradable from: 3.24.23-3]
libgtk-3-common/unstable,unstable 3.24.24-1 all [upgradable from: 3.24.23-3]
libhandy-0.0-0/unstable 0.0.13-3 amd64 [upgradable from: 0.0.13-2]
libhandy-1-0/unstable 1.0.2-1+b1 amd64 [upgradable from: 1.0.2-1]
libjs-backbone/unstable,unstable 1.4.0~dfsg+~1.4.5-1 all [upgradable
from: 1.3.3~dfsg-6]
libjson-glib-1.0-0/unstable 1.6.0-2 amd64 [upgradable from: 1.6.0-1]
libjson-glib-1.0-common/unstable,unstable 1.6.0-2 all [upgradable from:
1.6.0-1]
libkf5xmlgui-bin/unstable 5.74.0-2+b2 amd64 [upgradable from: 5.74.0-2+b1]
libkf5xmlgui5/unstable 5.74.0-2+b2 amd64 [upgradable from: 5.74.0-2+b1]
libmime-types-perl/unstable,unstable 2.18-1 all [upgradable from: 2.17-1]
libnss-myhostname/unstable 247.1-4 amd64 [upgradable from: 247.1-3]
liborcus-0.16-0/unstable 0.16.1-3+b2 amd64 [upgradable from: 0.16.1-3+b1]
liborcus-parser-0.16-0/unstable 0.16.1-3+b2 amd64 [upgradable from:
0.16.1-3+b1]
libp11-kit0/unstable 0.23.22-1 amd64 [upgradable from: 0.23.21-2]
libpam-systemd/unstable 247.1-4 amd64 [upgradable from: 247.1-3]
libpcre2-16-0/unstable 10.36-2 amd64 [upgradable from: 10.35-2]
libpcre2-32-0/unstable 10.36-2 amd64 [upgradable from: 10.35-2]
libpcre2-8-0/unstable 10.36-2 amd64 [upgradable from: 10.35-2]
libpcre2-dev/unstable 10.36-2 amd64 [upgradable from: 10.35-2]
libpcre2-posix2/unstable 10.36-2 amd64 [upgradable from: 10.35-2]
libphonenumber7/unstable 7.1.0-6+b1 amd64 [upgradable from: 7.1.0-6]
libproxy-tools/unstable 0.4.16-1 amd64 [upgradable from: 0.4.15-15]
libproxy1-plugin-gsettings/unstable 0.4.16-1 amd64 [upgradable from:
0.4.15-15]
libproxy1-plugin-networkmanager/unstable 0.4.16-1 amd64 [upgradable
from: 0.4.15-15]
libproxy1-plugin-webkit/unstable 0.4.16-1 amd64 [upgradable from: 0.4.15-15]
libproxy1v5/unstable 0.4.16-1 amd64 [upgradable from: 0.4.15-15]
libqt5concurrent5/unstable 5.15.2+dfsg-2 amd64 [upgradable from:
5.15.1+dfsg-4]
libqt5core5a/unstable 5.15.2+dfsg-2 amd64 [upgradable from: 5.15.1+dfsg-4]
libqt5dbus5/unstable 5.15.2+dfsg-2 amd64 [upgradable from: 5.15.1+dfsg-4]
libqt5gui5/unstable 5.15.2+dfsg-2 amd64 [upgradable from: 5.15.1+dfsg-4]
libqt5multimedia5/unstable 5.15.2-2 amd64 [upgradable from: 5.15.1-2]
libqt5network5/unstable 5.15.2+dfsg-2 amd64 [upgradable from: 5.15.1+dfsg-4]
libqt5opengl5/unstable 5.15.2+dfsg-2 amd64 [upgradable from: 5.15.1+dfsg-4]
libqt5positioning5/unstable 5.15.2+dfsg-2 amd64 [upgradable from:
5.15.1+dfsg-2]
libqt5printsupport5/unstable 5.15.2+dfsg-2 amd64 [upgradable from:
5.15.1+dfsg-4]
libqt5qml5/unstable 5.15.2+dfsg-2 amd64 [upgradable from: 5.15.1+dfsg-3]
libqt5qmlmodels5/unstable 5.15.2+dfsg-2 amd64 [upgradable from:
5.15.1+dfsg-3]
libqt5qmlworkerscript5/unstable 5.15.2+dfsg-2 amd64 [upgradable from:
5.15.1+dfsg-3]
libqt5quick5/unstable 5.15.2+dfsg-2 amd64 [upgradable from: 5.15.1+dfsg-3]
libqt5quickcontrols2-5/unstable 5.15.2+dfsg-2 amd64 [upgradable from:
5.15.1+dfsg-2]
libqt5quickparticles5/unstable 5.15.2+dfsg-2 amd64 [upgradable from:
5.15.1+dfsg-3]
libqt5quicktemplates2-5/unstable 5.15.2+dfsg-2 amd64 [upgradable from:
5.15.1+dfsg-2]
libqt5quickwidgets5/unstable 5.15.2+dfsg-2 amd64 [upgradable from:
5.15.1+dfsg-3]
libqt5script5/unstable 5.15.2+dfsg-2 amd64 [upgradable from: 5.15.1+dfsg-2]
libqt5sensors5/unstable 5.15.2-2 amd64 [upgradable from: 5.15.1-2]
libqt5sql5-sqlite/unstable 5.15.2+dfsg-2 amd64 [upgradable from:
5.15.1+dfsg-4]
libqt5sql5/unstable 5.15.2+dfsg-2 amd64 [upgradable from: 5.15.1+dfsg-4]
libqt5svg5/unstable 5.15.2-2 amd64 [upgradable from: 5.15.1-2]
libqt5texttospeech5/unstable 5.15.2-2 amd64 [upgradable from: 5.15.1-2]
libqt5waylandclient5/unstable 5.15.2-2 amd64 [upgradable from: 5.15.1-3]
libqt5waylandcompositor5/unstable 5.15.2-2 amd64 [upgradable from: 5.15.1-3]
libqt5webchannel5/unstable 5.15.2-2 amd64 [upgradable from: 5.15.1-2]
libqt5webengine-data/unstable,unstable 5.15.2+dfsg-3 all [upgradable
from: 5.15.1+dfsg-5]
libqt5webenginecore5/unstable 5.15.2+dfsg-3 amd64 [upgradable from:
5.15.1+dfsg-5+b1]
libqt5webenginewidgets5/unstable 5.15.2+dfsg-3 amd64 [upgradable from:
5.15.1+dfsg-5+b1]
libqt5webkit5/unstable 5.212.0~alpha4-10 amd64 [upgradable from:
5.212.0~alpha4-7]
libqt5websockets5/unstable 5.15.2-2 amd64 [upgradable from: 5.15.1-2]
libqt5widgets5/unstable 5.15.2+dfsg-2 amd64 [upgradable from: 5.15.1+dfsg-4]
libqt5x11extras5/unstable 5.15.2-2 amd64 [upgradable from: 5.15.1-2]
libqt5xdg3/unstable 3.4.0-1+b3 amd64 [upgradable from: 3.4.0-1+b2]
libqt5xdgiconloader3/unstable 3.4.0-1+b3 amd64 [upgradable from: 3.4.0-1+b2]
libqt5xml5/unstable 5.15.2+dfsg-2 amd64 [upgradable from: 5.15.1+dfsg-4]
libsystemd0/unstable 247.1-4 amd64 [upgradable from: 247.1-3]
libtiff5/unstable 4.1.0+git201212-1 amd64 [upgradable from:
4.1.0+git191117-2]
libudev1/unstable 247.1-4 amd64 [upgradable from: 247.1-3]
libusb-1.0-0/unstable 2:1.0.24-2 amd64 [upgradable from: 2:1.0.24-1]
p11-kit-modules/unstable 0.23.22-1 amd64 [upgradable from: 0.23.21-2]
p11-kit/unstable 0.23.22-1 amd64 [upgradable from: 0.23.21-2]
python3-ipykernel/unstable,unstable 5.4.2-1 all [upgradable from: 5.3.4-1]
python3-soupsieve/unstable,unstable 2.1-1 all [upgradable from: 2.0.1-1]
qml-module-qt-labs-folderlistmodel/unstable 5.15.2+dfsg-2 amd64
[upgradable from: 5.15.1+dfsg-3]
qml-module-qt-labs-settings/unstable 5.15.2+dfsg-2 amd64 [upgradable
from: 5.15.1+dfsg-3]
qml-module-qtgraphicaleffects/unstable 5.15.2-2 amd64 [upgradable from:
5.15.1-2]
qml-module-qtqml-models2/unstable 5.15.2+dfsg-2 amd64 [upgradable from:
5.15.1+dfsg-3]
qml-module-qtqml/unstable 5.15.2+dfsg-2 amd64 [upgradable from:
5.15.1+dfsg-3]
qml-module-qtquick-controls2/unstable 5.15.2+dfsg-2 amd64 [upgradable
from: 5.15.1+dfsg-2]
qml-module-qtquick-controls/unstable 5.15.2-2 amd64 [upgradable from:
5.15.1-2]
qml-module-qtquick-dialogs/unstable 5.15.2-2 amd64 [upgradable from:
5.15.1-2]
qml-module-qtquick-extras/unstable 5.15.2-2 amd64 [upgradable from:
5.15.1-2]
qml-module-qtquick-layouts/unstable 5.15.2+dfsg-2 amd64 [upgradable
from: 5.15.1+dfsg-3]
qml-module-qtquick-particles2/unstable 5.15.2+dfsg-2 amd64 [upgradable
from: 5.15.1+dfsg-3]
qml-module-qtquick-privatewidgets/unstable 5.15.2-2 amd64 [upgradable
from: 5.15.1-2]
qml-module-qtquick-templates2/unstable 5.15.2+dfsg-2 amd64 [upgradable
from: 5.15.1+dfsg-2]
qml-module-qtquick-window2/unstable 5.15.2+dfsg-2 amd64 [upgradable
from: 5.15.1+dfsg-3]
qml-module-qtquick2/unstable 5.15.2+dfsg-2 amd64 [upgradable from:
5.15.1+dfsg-3]
qt5-gtk-platformtheme/unstable 5.15.2+dfsg-2 amd64 [upgradable from:
5.15.1+dfsg-4]
qt5dxcb-plugin/unstable 5.0.1-4+b1 amd64 [upgradable from: 5.0.1-4]
qtspeech5-speechd-plugin/unstable 5.15.2-2 amd64 [upgradable from: 5.15.1-2]
qtwayland5/unstable 5.15.2-2 amd64 [upgradable from: 5.15.1-3]
screen/unstable 4.8.0-3 amd64 [upgradable from: 4.8.0-2]
seahorse/unstable 3.38.0.1-1 amd64 [upgradable from: 3.36-1]
systemd-bootchart/unstable 233-3 amd64 [upgradable from: 233-2+b1]
systemd-coredump/unstable 247.1-4 amd64 [upgradable from: 247.1-3]
systemd-sysv/unstable 247.1-4 amd64 [upgradable from: 247.1-3]
systemd-timesyncd/unstable 247.1-4 amd64 [upgradable from: 247.1-3]
systemd/unstable 247.1-4 amd64 [upgradable from: 247.1-3]
udev/unstable 247.1-4 amd64 [upgradable from: 247.1-3]
$ sudo apt upgrade
Reading package lists... Done
Building dependency tree
Reading state information... Done
Calculating upgrade... Done
The following packages were automatically installed and are no longer
required:
   libboost-filesystem1.71.0 libboost-iostreams1.71.0
Use 'sudo apt autoremove' to remove them.
The following NEW packages will be installed:
   libboost-filesystem1.74.0 libboost-iostreams1.74.0
libboost-thread1.74.0 libdeflate0
The following packages have been kept back:
   gcc-8-base libboost-dev
The following packages will be upgraded:
   autoconf dde-qt5integration fonts-font-awesome gir1.2-gdkpixbuf-2.0
gir1.2-gtk-3.0 gir1.2-handy-0.0 gir1.2-handy-1 gir1.2-json-1.0 gnome-maps
   gtk-update-icon-cache htop intel-media-va-driver libcmis-0.5-5v5
libdtkwidget2 libgail-3-0 libgdk-pixbuf-2.0-0 libgdk-pixbuf2.0-bin
   libgdk-pixbuf2.0-common libgtk-3-0 libgtk-3-bin libgtk-3-common
libhandy-0.0-0 libhandy-1-0 libjs-backbone libjson-glib-1.0-0
   libjson-glib-1.0-common libkf5xmlgui-bin libkf5xmlgui5
libmime-types-perl libnss-myhostname liborcus-0.16-0
liborcus-parser-0.16-0 libp11-kit0
   libpam-systemd libpcre2-16-0 libpcre2-32-0 libpcre2-8-0 libpcre2-dev
libpcre2-posix2 libphonenumber7 libproxy-tools libproxy1-plugin-gsettings
   libproxy1-plugin-networkmanager libproxy1-plugin-webkit libproxy1v5
libqt5concurrent5 libqt5core5a libqt5dbus5 libqt5gui5 libqt5multimedia5
   libqt5network5 libqt5opengl5 libqt5positioning5 libqt5printsupport5
libqt5qml5 libqt5qmlmodels5 libqt5qmlworkerscript5 libqt5quick5
   libqt5quickcontrols2-5 libqt5quickparticles5 libqt5quicktemplates2-5
libqt5quickwidgets5 libqt5script5 libqt5sensors5 libqt5sql5
libqt5sql5-sqlite
   libqt5svg5 libqt5texttospeech5 libqt5waylandclient5
libqt5waylandcompositor5 libqt5webchannel5 libqt5webengine-data
libqt5webenginecore5
   libqt5webenginewidgets5 libqt5webkit5 libqt5websockets5
libqt5widgets5 libqt5x11extras5 libqt5xdg3 libqt5xdgiconloader3
libqt5xml5 libsystemd0
   libtiff5 libudev1 libusb-1.0-0 p11-kit p11-kit-modules
python3-ipykernel python3-soupsieve qml-module-qt-labs-folderlistmodel
   qml-module-qt-labs-settings qml-module-qtgraphicaleffects
qml-module-qtqml qml-module-qtqml-models2 qml-module-qtquick-controls
   qml-module-qtquick-controls2 qml-module-qtquick-dialogs
qml-module-qtquick-extras qml-module-qtquick-layouts
qml-module-qtquick-particles2
   qml-module-qtquick-privatewidgets qml-module-qtquick-templates2
qml-module-qtquick-window2 qml-module-qtquick2 qt5-gtk-platformtheme
   qt5dxcb-plugin qtspeech5-speechd-plugin qtwayland5 screen seahorse
systemd systemd-bootchart systemd-coredump systemd-sysv
systemd-timesyncd udev
116 upgraded, 4 newly installed, 0 to remove and 2 not upgraded.
Need to get 101 MB of archives.
After this operation, 6,711 kB of additional disk space will be used.
Do you want to continue? [Y/n]
```

Is that expected, or am I missing something?


Kind regards,

Paul

#977346#10
Date:
2020-12-14 10:58:55 UTC
From:
To:
Hi Paul,
...
...

This (or something like that) is expected in unstable due to the fix in #960966.

Please change /etc/apt/apt.conf.d/50unattended-upgrades if you want
u-u to try very hard to upgrade things:

...
// When APT fails to mark a package to be upgraded or installed try adjusting
// candidates of related packages to help APT's resolver in finding a solution
// where the package can be upgraded or installed.
// This is a workaround until APT's resolver is fixed to always find a
// solution if it exists. (See Debian bug #711128.)
// The fallback is enabled by default, except on Debian's sid release because
// uninstallable packages are frequent there.
// Disabling the fallback speeds up unattended-upgrades when there are
// uninstallable packages at the expense of rarely keeping back packages which
// could be upgraded or installed.
// Unattended-Upgrade::Allow-APT-Mark-Fallback "true";

Cheers,
Balint

#977346#17
Date:
2020-12-14 11:06:11 UTC
From:
To:
Dear Balint,


Thank you very much for the quick response.


Am 14.12.20 um 11:58 schrieb Balint Reczey:

[…]

Thank you for the hint, but I still do not understand, why it works on
other systems. Are the kept back packages a problem? Could a log message
be added to `unattended-upgrades.log`?


Kind regards,

Paul

Your signature delimiter is missing a space at the end [1]. ;-)


[1]: https://en.wikipedia.org/wiki/Signature_block#Standard_delimiter

#977346#22
Date:
2020-12-14 11:22:17 UTC
From:
To:
Hi Paul,

APT found the upgrades on those, probably because different packages
are installed.

Yes, kept back packages are the ones making APT's work harder in
finding the upgradable ones.

When running without --dry-mode u-u already prints out more
information about held back packages.

More explanation _could_ be added, but this workaround is on by
default only in Sid and people using Sid are expected to figure out
things on their own thus I don't plan working on that part. Patches
are still welcome.

Cheers,
Balint

#977346#27
Date:
2021-06-25 07:44:01 UTC
From:
To:
Dear Balint,


I am sorry for the late reply.


Am 14.12.20 um 12:22 schrieb Balint Reczey:

I also ran into the problem with no held back packages involved. Could
the problem be that the allowed origins for some reason do not match *sid*?

     2020-12-14 09:51:17,339 INFO Allowed origins are:
origin=Debian,codename=buster,label=Debian,
origin=Debian,codename=buster,label=Debian-Security,
origin=Debian,codename=buster-security,label=Debian-Security

or

     2021-06-18 11:22:11,763 INFO Erlaubte Ursprünge sind:
origin=Debian,codename=bullseye,label=Debian,
origin=Debian,codename=bullseye,label=Debian-Security,
origin=Debian,codename=bullseye-security,label=Debian-Security

`apt-cache policy show` contains:

      500 http://mirror.netzwerge.de/debian sid/main amd64 Packages
          release o=Debian,a=unstable,n=sid,l=Debian,c=main,b=amd64
          origin mirror.netzwerge.de

and `/etc/apt/apt.conf.d/50unattended-upgrades` contains:

             "origin=Debian,codename=${distro_codename},label=Debian";

"origin=Debian,codename=${distro_codename},label=Debian-Security";

"origin=Debian,codename=${distro_codename}-security,label=Debian-Security";

`debian_version` is also mentioned in the configuration file comment.

     $ more /etc/debian_version
     11.0

So, is the wrong codename derived on the suite sid/unstable?


Kind regards,

Paul

#977346#32
Date:
2021-11-25 08:14:20 UTC
From:
To:
The same error here since Oct 11, 2021

distribution: testing/bookworm

/etc/debian_version:

bookworm/sid

50unattended-upgrades:

....
Unattended-Upgrade:rigins-Pattern {
         "origin=Debian,codename=${distro_codename}-updates";
         "origin=Debian,codename=${distro_codename}-proposed-updates";
         "origin=Debian,codename=${distro_codename},label=Debian";

"origin=Debian,codename=${distro_codename},label=Debian-Security";

"origin=Debian,codename=${distro_codename}-security,label=Debian-Security";
};
....

sources.list:

deb http://ftp.debian.org/debian/ testing main contrib non-free
deb http://security.debian.org/ testing-security main contrib non-free
deb http://ftp.debian.org/debian/ testing-updates main contrib non-free

All works OK and in unattended-upgrades.log I get:

....INFO Allowed origins are: origin=Debian,codename=bookworm-updates,
origin=Debian,codename=bookworm-proposed-updates,
origin=Debian,codename=bookworm,label=Debian,
origin=Debian,codename=bookworm,label=Debian-Security,
origin=Debian,codename=bookworm-security,label=Debian-Security


When I add to sources.list line:

deb http://ftp.debian.org/debian/ testing-proposed-updates main contrib
non-free

upgrades are not found and unattended-upgrades.log changes to

....INFO Allowed origins are: origin=Debian,codename=sid-updates,
origin=Debian,codename=sid-proposed-updates,
origin=Debian,codename=sid,label=Debian,
origin=Debian,codename=sid,label=Debian-Security,
origin=Debian,codename=sid-security,label=Debian-Security

bookworm was changed to sid. Why????