Bug#1050586: kmod: Updating to kmod to 30+20230601-1 results in a non booting system modules cannot be decompressed

2023-08-27 Thread Jon Westgate

Dear Marco and others,

I will do a test build using ZSTD and see if that works. - I think the 
first thing I did was to switch back to XZ when this first happened 
Yesterday.


I've been using XZ for module compression since it was available, I just 
select it using make menuconfig I'm not using anything other than a 
slight tweek to the debian build.
I don't use signing as my UEFI allows me not to, the only other thing I 
do different to Debian is to build in USB support, filesystem support 
for ext4 and BTRFS and build in SCSI, LIBATA so that should my initrd 
fail for any reason I'm not left high and dry with no keyboard support 
and no access to a filesystem. I used to build in networking support, 
but I only do that systems that I use for firewalling as systemd won't 
allow networking unless everything else is mostly perfect.


I started using module compression for net boot thin clients as it made 
the resulting initrd way quicker to load over TFTP. Later on I switched 
to using it on all my systems as it made the boot process much quicker.


Finally I found that on recent 6.x kernels it was required due to a size 
limit that seemed to appear initrd. I'm not sure what makes this limit, 
it's there in grub and refind.


If what you say is true then kmod might have been masking a kernel bug 
for the last year.


I'm not doing anything clever here, I just get my source from 
cdn.kernel.org, use make menuconfig or vim to edit the .config and make 
-j8 && make -j8 modules_install && make install then reboot.

I'm not applying any patches, I do used the NVIDIA drivers on some boxes.

Jon


On 27/08/2023 02:10, Marco d'Itri wrote:

On Aug 26, Jon Westgate <0...@fsck.tv> wrote:


The error message it gave was "decompresson failed with status 6"

Status 6 is XZ_OPTIONS_ERROR, which means "Input was encoded with
settings that are not supported by this XZ decoder".
So it looks like you have compressed the modules (how?) with XZ settings
which are supported by the userspace loader but not by the kernel one.





OpenPGP_0x420652A8C309A3B2.asc
Description: OpenPGP public key


OpenPGP_signature.asc
Description: OpenPGP digital signature


Bug#1050586: kmod: Updating to kmod to 30+20230601-1 results in a non booting system modules cannot be decompressed

2023-08-27 Thread Marco d'Itri
Control: retitle -1 kmod does not work with XZ in-kernel module decompression

On Aug 27, Jon Westgate  wrote:

> Note that I already had "Support in-kernel module decompression" selected
> when the compression method was XZ.
> 
> Would you like me to try without it?
No need to: we know that everything works fine without in-kernel 
decompression, because this is how the Debian kernel is configured.

-- 
ciao,
Marco


signature.asc
Description: PGP signature


Bug#1050586: kmod: Updating to kmod to 30+20230601-1 results in a non booting system modules cannot be decompressed

2023-08-27 Thread Jon Westgate

All,
To confirm that switching to ZSTD works.

I ran make menuconfig,
   [*] Enable loadable module support  --->

        Module compression mode (ZSTD) --->
        [*]   Support in-kernel module decompression
Note that I already had "Support in-kernel module decompression" 
selected when the compression method was XZ.


Would you like me to try without it?

On a side note switching module compression mode did not require a full 
recompile.
I presume it just linked in a different module decompressor, then 
compressed the modules using ZSTD on the fly when I ran make modules_install


Jon

On 27/08/2023 11:24, Jon Westgate wrote:

Dear Marco and others,

I will do a test build using ZSTD and see if that works. - I think the 
first thing I did was to switch back to XZ when this first happened 
Yesterday.


I've been using XZ for module compression since it was available, I 
just select it using make menuconfig I'm not using anything other than 
a slight tweek to the debian build.
I don't use signing as my UEFI allows me not to, the only other thing 
I do different to Debian is to build in USB support, filesystem 
support for ext4 and BTRFS and build in SCSI, LIBATA so that should my 
initrd fail for any reason I'm not left high and dry with no keyboard 
support and no access to a filesystem. I used to build in networking 
support, but I only do that systems that I use for firewalling as 
systemd won't allow networking unless everything else is mostly perfect.


I started using module compression for net boot thin clients as it 
made the resulting initrd way quicker to load over TFTP. Later on I 
switched to using it on all my systems as it made the boot process 
much quicker.


Finally I found that on recent 6.x kernels it was required due to a 
size limit that seemed to appear initrd. I'm not sure what makes this 
limit, it's there in grub and refind.


If what you say is true then kmod might have been masking a kernel bug 
for the last year.


I'm not doing anything clever here, I just get my source from 
cdn.kernel.org, use make menuconfig or vim to edit the .config and 
make -j8 && make -j8 modules_install && make install then reboot.

I'm not applying any patches, I do used the NVIDIA drivers on some boxes.

Jon


On 27/08/2023 02:10, Marco d'Itri wrote:

On Aug 26, Jon Westgate <0...@fsck.tv> wrote:


The error message it gave was "decompresson failed with status 6"

Status 6 is XZ_OPTIONS_ERROR, which means "Input was encoded with
settings that are not supported by this XZ decoder".
So it looks like you have compressed the modules (how?) with XZ settings
which are supported by the userspace loader but not by the kernel one.







OpenPGP_0x420652A8C309A3B2.asc
Description: OpenPGP public key


OpenPGP_signature.asc
Description: OpenPGP digital signature


Bug#1050586: kmod: Updating to kmod to 30+20230601-1 results in a non booting system modules cannot be decompressed

2023-08-27 Thread Antonio

ticket:

https://techpatterns.com/forums/about3040.html



Bug#1050586: kmod: Updating to kmod to 30+20230601-1 results in a non booting system modules cannot be decompressed

2023-08-27 Thread Antonio
I don't build kernel from source, I use binary packages installed from 
liquorix repositories https://liquorix.net/.


I opened a ticket to their forum, maybe a recompilation of the kernel is 
enough.


We await your reply...


Il 27/08/23 03:10, Marco d'Itri ha scritto:

On Aug 26, Jon Westgate <0...@fsck.tv> wrote:


The error message it gave was "decompresson failed with status 6"

Status 6 is XZ_OPTIONS_ERROR, which means "Input was encoded with
settings that are not supported by this XZ decoder".
So it looks like you have compressed the modules (how?) with XZ settings
which are supported by the userspace loader but not by the kernel one.





Bug#1050586: kmod: Updating to kmod to 30+20230601-1 results in a non booting system modules cannot be decompressed

2023-08-26 Thread Marco d'Itri
On Aug 26, Jon Westgate <0...@fsck.tv> wrote:

> The error message it gave was "decompresson failed with status 6"
Status 6 is XZ_OPTIONS_ERROR, which means "Input was encoded with 
settings that are not supported by this XZ decoder".
So it looks like you have compressed the modules (how?) with XZ settings 
which are supported by the userspace loader but not by the kernel one.

-- 
ciao,
Marco


signature.asc
Description: PGP signature


Bug#1050586: kmod: Updating to kmod to 30+20230601-1 results in a non booting system modules cannot be decompressed

2023-08-26 Thread Jon Westgate

Dear Marco,
I'm using XZ if I turn off compression my initrd fails it's too big.

Jon

On 26/08/2023 22:25, Marco d'Itri wrote:

On Aug 26, Jon Westgate  wrote:


Yes I am using compressed modules

And are these modules compressed with xz or something else?

This new code was introduced in the latest snapshot, and apparently it
fails when used with kernels with compressed modules support enabled
(which so far is not the default for Debian kenrels).





OpenPGP_0x420652A8C309A3B2.asc
Description: OpenPGP public key


OpenPGP_signature.asc
Description: OpenPGP digital signature


Bug#1050586: kmod: Updating to kmod to 30+20230601-1 results in a non booting system modules cannot be decompressed

2023-08-26 Thread Marco d'Itri
On Aug 26, Jon Westgate  wrote:

> Yes I am using compressed modules
And are these modules compressed with xz or something else?

This new code was introduced in the latest snapshot, and apparently it 
fails when used with kernels with compressed modules support enabled 
(which so far is not the default for Debian kenrels).

-- 
ciao,
Marco


signature.asc
Description: PGP signature


Bug#1050586: kmod: Updating to kmod to 30+20230601-1 results in a non booting system modules cannot be decompressed

2023-08-26 Thread Marco d'Itri
On Aug 26, Jon Westgate <0...@fsck.tv> wrote:

> Kernel: Linux 6.4.11 (SMP w/12 CPU threads; PREEMPT)
I see that you are using a custom kernel. What is the status of the
CONFIG_MODULE_COMPRESS_* kernel configuration options?

-- 
ciao,
Marco


signature.asc
Description: PGP signature


Bug#1050586: kmod: Updating to kmod to 30+20230601-1 results in a non booting system modules cannot be decompressed

2023-08-26 Thread Marco d'Itri
On Aug 26, Jon Westgate <0...@fsck.tv> wrote:

> The system partially booted but systemd then prevented boot due to missing
> modules,
> The error message it gave was "decompresson failed with status 6"
Are you using compressed modules?

-- 
ciao,
Marco


signature.asc
Description: PGP signature


Bug#1050586: kmod: Updating to kmod to 30+20230601-1 results in a non booting system modules cannot be decompressed

2023-08-26 Thread Jon Westgate
Package: kmod
Version: 30+20230601-1
Severity: grave
Justification: renders system unusable

Dear Maintainer,

I just did a normal apt upgrade and the following packages were upgraded:
kmod 30+20230519-1 to 30-2.230601-1
libkmod2 30+20230519-1 to 30-2.230601-1

The system partially booted but systemd then prevented boot due to missing
modules,
The error message it gave was "decompresson failed with status 6"

I had to boot from a rescue usb stick, set a root password, then I was able to
interact with systemd's idea of a diagnotic console - I'm not systemd's biggest
fan
I used another system to download the older versions of kmod and libkmod2 and
as able to use dpkg to downgrade them.

I installed both on another system and it does the same.
I'm not sure if this effects other system's with sysvinit or non efi.

Regards
Jon Westgate


-- System Information:
Debian Release: trixie/sid
  APT prefers unstable
  APT policy: (500, 'unstable')
Architecture: amd64 (x86_64)
Foreign Architectures: i386

Kernel: Linux 6.4.11 (SMP w/12 CPU threads; PREEMPT)
Kernel taint flags: TAINT_PROPRIETARY_MODULE, TAINT_FIRMWARE_WORKAROUND, 
TAINT_OOT_MODULE, TAINT_UNSIGNED_MODULE
Locale: LANG=en_GB.UTF-8, LC_CTYPE=en_GB.UTF-8 (charmap=UTF-8), LANGUAGE not set
Shell: /bin/sh linked to /usr/bin/dash
Init: systemd (via /run/systemd/system)

Versions of packages kmod depends on:
ii  libc6 2.37-7
ii  libkmod2  30+20230601-1
ii  liblzma5  5.4.1-0.2
ii  libssl3   3.0.10-1
ii  libzstd1  1.5.5+dfsg2-1

kmod recommends no packages.

kmod suggests no packages.

-- no debconf information