[GTALUG] Anyone else having issues with 6.9.12-1 kernel?
Michael Galea
michael at galeahome.ca
Wed Aug 7 21:50:20 EDT 2024
On 2024-08-07 18:28, Lennart Sorensen wrote:
> On Wed, Aug 07, 2024 at 06:09:28PM -0400, Michael Galea wrote:
>> I found out my problem on the laptop and its not signed vs unsigned.
>> linux-image-6.10.3-amd64 installs a 44M initrd on my desktop and a
>> 261M initrd on the laptop!
>> The desktop is ext4 on disk while the laptop is crypted data on mmc
>> flash memory. I'm guessing encryted fs doesn't compress so well.
>>
>> So far Ive tried upping the compression level in intramfs-tools.conf but to
>> no avail, the initrd always is 261M. That's a problem for me as the
>> standard debian crypt setup gave me only a 448M /boot and one kernel
>> uses 66% of it!
>
> You could change the initramfs settings from MODULES=most to MODULES=dep
> to make it only include what is needed to boot your system, rather than
> most generic systems.
>
> Setting the initramfs compression to zstd or something else modern can
> also reduce the size compared to gzip a bit.
>
> And it does seem having the nvidia drivers installed means a bunch
> more firmware files are included in the initrd than systems without the
> nvidia driver.
>
> I would not expect the encrytion to affect the initrd size, since the
> compression should be done on the file, not the encrypted disk.
>
> Now this is the sizes I see on one of my systems:
>
> -rw-r--r-- 1 root root 271K Aug 4 16:10 config-6.10.3-amd64
> -rw-r--r-- 1 root root 258K Aug 31 2023 config-6.4.0-4-amd64
> -rw-r--r-- 1 root root 270K Jul 19 12:55 config-6.9.10-amd64
> drwxr-xr-x 5 root root 12K Aug 7 18:20 grub
> -rw-r--r-- 1 root root 84M Aug 7 13:45 initrd.img-6.10.3-amd64
> -rw-r--r-- 1 root root 82M Jul 21 21:42 initrd.img-6.4.0-4-amd64
> -rw-r--r-- 1 root root 84M Jul 21 21:44 initrd.img-6.9.10-amd64
> -rw-r--r-- 1 root root 83 Aug 4 16:10 System.map-6.10.3-amd64
> -rw-r--r-- 1 root root 83 Aug 31 2023 System.map-6.4.0-4-amd64
> -rw-r--r-- 1 root root 83 Jul 19 12:55 System.map-6.9.10-amd64
> -rw-r--r-- 1 root root 9.3M Aug 4 16:10 vmlinuz-6.10.3-amd64
> -rw-r--r-- 1 root root 8.7M Aug 31 2023 vmlinuz-6.4.0-4-amd64
> -rw-r--r-- 1 root root 9.2M Jul 19 12:55 vmlinuz-6.9.10-amd64
>
> It uses zstd compression and MODULES=most for initramfs.
>
> It has nvidia-legacy-340xx-drive installed, but I think the huge firmware
> is only in the current nvidia drivers, not the legacy ones.
>
> Interestingly these are the largest files I see in my initrd:
> -rw-r--r-- 1 root root 3984265 Aug 4 16:10 usr/lib/modules/6.10.3-amd64/kernel/drivers/gpu/drm/radeon/radeon.ko
> -rw-r--r-- 1 root root 4374313 Aug 4 16:10 usr/lib/modules/6.10.3-amd64/kernel/drivers/net/ethernet/mellanox/mlx5/core/mlx5_core.ko
> -rw-r--r-- 1 root root 4696473 Aug 4 16:10 usr/lib/modules/6.10.3-amd64/kernel/fs/btrfs/btrfs.ko
> -rw-r--r-- 1 root root 5525401 Aug 4 16:10 usr/lib/modules/6.10.3-amd64/kernel/fs/xfs/xfs.ko
> -rw-r--r-- 1 root root 5772408 Aug 3 10:17 usr/lib/x86_64-linux-gnu/libcrypto.so.3
> -rw-r--r-- 1 root root 6669193 Aug 4 16:10 usr/lib/modules/6.10.3-amd64/kernel/drivers/gpu/drm/nouveau/nouveau.ko
> -rw-r--r-- 1 root root 7955456 Feb 5 2024 kernel/x86/microcode/GenuineIntel.bin
> -rw-r--r-- 1 root root 9538825 Aug 4 16:10 usr/lib/modules/6.10.3-amd64/kernel/drivers/gpu/drm/i915/i915.ko
> -rw-r--r-- 1 root root 26577969 Aug 4 16:10 usr/lib/modules/6.10.3-amd64/kernel/drivers/gpu/drm/amd/amdgpu/amdgpu.ko
>
> I got that using:
> lsinitramfs -l /boot/initrd.img-6.10.3-amd64 |sort -n -k5
>
> Maybe you can find out what is making yours so large.
>
Thanks greatly, my initrd.img-6.10.3-amd64 was full of nvidia .ko files,
but after
=dep and reinstall, I went from 231M to 26M!
I'm still confused about one thing though. My desktop uses =most for
6.10.3 but
doesn't include the same .ko files. Also, my module list is still
different from yours.
What is initramfs using to decide what to add/subtract at initrd build
time?
--
Michael Galea
More information about the talk
mailing list