#1039073 wrong output from /usr/lib/xymon/client/ext/kern

#1039073#5
Date:
2023-06-25 12:58:40 UTC
From:
To:
Dear Maintainer

The command similar to: cat vmlinuz-6.1.0-9-arm64 |strings |grep "Linux
version"
in the kern check fails on Debian 12. The report claims:

Machine should be rebooted. Running not the newest installed kernel:

   Running kernel:          6.1.0-9-arm64, version #1 SMP Debian 6.1.27-1
(2023-05-08)
   Newest installed kernel: 6.1.0-9-arm64, version (gcc-12 (Debian
12.2.0-14) 12.2.0, GNU ld (GNU Binutils for Debian) 2.40) # SMP Debian
6.1.27-1 (2023-05-08)

Thank you for fixing this.

Best,

#1039073#12
Date:
2023-09-10 17:52:08 UTC
From:
To:
Dear maintainer,

I'd like to submit another report concerning this bug and confirm the
'kern' plugin mis-reports the version string of the 'newest installed
kernel' on disk, resulting in a Yellow warning in the Xymon dasjboard.

As the previous reported, I note this behaviour on a Debian 12 (stable)
Arm64 platform.

I can confirm that manually testing the current vmlinuz disk image does
result in some extra cruft. I believe the characters delimited below
between >> << need to be ignored.

Linux version 6.1.50-current-rockchip64 >>(armbian@next)
(aarch64-linux-gnu-gcc (Ubuntu 11.4.0-1ubuntu1~22.04) 11.4.0, GNU ld
(GNU Binutils for Ubuntu) 2.38)<< #3 SMP PREEMPT Wed Aug 30 14:11:13 UTC
2023

Additionally, there are two matches within the vmlinuz file - the
*second* match is to be preferred as the first match which is the one
used in the plugin is missing the number following the hash (3 in this
example) in '#3 SMP PREEMPT Wed Aug 30 14:11:13 UTC 2023'

If helpful, I'm happy to test any patches that may be created as
otherwise the test is not useful since it permanently creates a Yellow
warning.

Kind regards,

Steve