Package: apt-dater-host
Version: 1.0.1-1
Severity: normal
Tags: patch
$ ssh ubuntu_xenial_machine
# apt-dater-host kernel
ADPROTO: 0.7
KERNELINFO: 1 4.13.0-36-generic
# zgrep KERNELINFO -m 1 -A 4 -B 2 /usr/share/doc/apt-dater-host/ADP-0.7.gz
The result line has the following format:
KERNELINFO: ${Code} ${Release}
The following codes are supported:
0 - The running kernel is the latest distri kernel. No reboot required.
1 - The running kernel is an distri kernel but it's older then the
latest
So apt-dater-host is telling us, that a new kernel is available on this
machine. Let's see:
# uname -r
4.13.0-36-generic
# dpkg-query -W -f='\${Package} \${Version} \${Status;20} \${Maintainer}
\${Provides}\n' 'linux-image*'
$linux-image $ $unknown ok not-insta $ $
$linux-image-4.13.0-31-generic $4.13.0-31.34~16.04.1 $deinstall ok config-
$Ubuntu Kernel Team <[email protected]> $aufs-dkms, fuse-module,
ivtv-modules, kvm-api-4, linux-image, redhat-cluster-modules, spl-dkms,
spl-modules, virtualbox-guest-modules, zfs-dkms, zfs-modules
$linux-image-4.13.0-32-generic $4.13.0-32.35~16.04.1 $install ok installed
$Ubuntu Kernel Team <[email protected]> $aufs-dkms, fuse-module,
ivtv-modules, kvm-api-4, linux-image, redhat-cluster-modules, spl-dkms,
spl-modules, virtualbox-guest-modules, zfs-dkms, zfs-modules
$linux-image-4.13.0-36-generic $4.13.0-36.40~16.04.1 $install ok installed
$Ubuntu Kernel Team <[email protected]> $aufs-dkms, fuse-module,
ivtv-modules, kvm-api-4, linux-image, redhat-cluster-modules, spl-dkms,
spl-modules, virtualbox-guest-modules, zfs-dkms, zfs-modules
$linux-image-extra-4.13.0-31-generic $4.13.0-31.34~16.04.1 $deinstall ok
config- $Ubuntu Kernel Team <[email protected]> $
$linux-image-extra-4.13.0-32-generic $4.13.0-32.35~16.04.1 $install ok
installed $Ubuntu Kernel Team <[email protected]> $
$linux-image-extra-4.13.0-36-generic $4.13.0-36.40~16.04.1 $install ok
installed $Ubuntu Kernel Team <[email protected]> $
$linux-image-generic-hwe-16.04 $4.13.0.36.55 $install ok installed $Ubuntu
Kernel Team <[email protected]> $
So, no, in fact, there is no newer kernel image available. We do have
the latest kernel installed.
Now if we go and debug apt-dater-host, we find out, that the above
command (modulo the '\${Package}' name) is exactly what apt-dater-host
is, to retrieve the list of available kernel images.
Now why does apt-dater-host go wrong in determining whether there's a
new kernel?
It is because it iterates over that list [1] and compares the version
from `uname -r` with the version from the list. The problem here is,
that comparing the current installed kernel version with the version
from the the last line, i.e. :
# dpkg --compare-versions 4.13.0-36 lt 4.13.0.36.55
will yield
# echo $?
0
meaning, yes there indeed *is* a newer kernel available. The problem is
only, that linux-image-generic-hwe-16.04 is *not* a kernel package, but
instead is a kernel *meta* package, that depends on the latest kernel...
Current apt-dater-host versions from upsteam improve the query [2] with a:
| grep linux-image
Remember, the upstream query does not include the '\${Package}' field,
so what the grep does is to effectively filter out by the '\${Provides}'
field, which in the case of the meta package is empty. Only the "real"
kernel packages do provide a 'linux-image'.
Thus upstream's apt-dater-host works on Ubuntu, while Debian's
apt-dater-host doesn't.
If you update Debian's apt-dater-host then I think it will be pulled
into Ubuntu, and things should be fixed there. So I ask you to please
update the Debian apt-dater-host from upstream.
Thanks.
*t
[1]
https://github.com/DE-IBH/apt-dater-host/blob/master/dpkg/apt-dater-host#L383
[2]
https://github.com/DE-IBH/apt-dater-host/blob/master/dpkg/apt-dater-host#L379
-- System Information:
Debian Release: 9.3
APT prefers stable
APT policy: (500, 'stable')
Architecture: amd64 (x86_64)
Foreign Architectures: i386
Kernel: Linux 4.9.0-5-amd64 (SMP w/8 CPU cores)
Locale: LANG=de_CH.utf8, LC_CTYPE=de_CH.utf8 (charmap=UTF-8), LANGUAGE=de_CH:de
(charmap=UTF-8)
Shell: /bin/sh linked to /bin/dash
Init: systemd (via /run/systemd/system)
Versions of packages apt-dater-host depends on:
ii libapt-pkg-perl 0.1.32
ii libimvirt-perl 0.9.6-3
ii lsb-release 9.20161125
ii openssh-server 1:7.4p1-10+deb9u2
ii perl 5.24.1-3+deb9u2
Versions of packages apt-dater-host recommends:
pn imvirt <none>
pn needrestart <none>
ii sudo 1.8.19p1-2.1
apt-dater-host suggests no packages.
-- Configuration Files:
/etc/sudoers.d/apt-dater-host [Errno 13] Keine Berechtigung:
'/etc/sudoers.d/apt-dater-host'
-- no debconf information