Jo Zzsi [Fri, 20 Sep 2024 03:10:48 +0000 (23:10 -0400)]
fix(network): call both check_module and module_check
Add back testing the module with check_module as well as module_check.
Without this PR, on some Linux distributions (e.g. Void) adding `network` meta module
no longer works as it tries and fails to install the preferred netowrking backend
(network-manager).
Jo Zzsi [Fri, 13 Sep 2024 16:45:23 +0000 (12:45 -0400)]
feat(rescue): move command line arguments to 50-rescue.conf
The benefit of this change is that even if kernel-install
is not used (e.g. direct user invocation), the correct
kernel command line options will be set for the generated
rescue image.
Jo Zzsi [Wed, 21 Aug 2024 23:20:43 +0000 (19:20 -0400)]
fix(rescue): make rescue always no-hostonly
Currently the rescue image is only set to no-hostonly if it is
generated via dracut-rescue.install. Make the rescue image
generation more predictable and consistent by setting no-hostonly
right in the rescue config.
Jo Zzsi [Wed, 18 Sep 2024 02:20:07 +0000 (22:20 -0400)]
perf(systemd-initrd): do not depend on base module
Make sure /etc/initrd exist.
Test SYSTEMD-INITRD confirms no regression as this tests
now no longer includes the base module and it still passes
the boot tests with systemd (hence the perf tag).
Jo Zzsi [Fri, 13 Sep 2024 12:22:42 +0000 (08:22 -0400)]
feat: config example for cloud provider uki vm
This is an example configuration for a 'unified kernel image'.
The key benefit of a unified kernel is that its secure boot
signature covers the initrd and cmdline contents, allowing
a trustworthy measured boot process with attestation, which
is not practical with locally generated initrds/cmdlines.
The initrd in this example only needs a very small set of
block driver modules present, in order to be usable across
KVM, Hyper-V and Xen hypervisors which will cover essentially
all common public and private clouds.
Lichen Liu [Wed, 7 Aug 2024 02:13:37 +0000 (10:13 +0800)]
feat(dracut.sh): add --add-confdir option
When generating kdump's initrd, we want to keep [omit_]dracutmodules
empty and let kdump to handle the modules. And we don't want to
affect the first kernel's initrd, so we cannot place our conf file
to /etc/dracut.conf.d or /usr/lib/dracut/dracut.conf.d.
This patch adds a new option to allow user to add an extra configuration
directory to use *.conf files from. If the dir not exists, will look for
confdir's subdir.
After that, kdump can use "--add-confdir kdump" if
/usr/lib/dracut/dracut.conf.d/kdump exists, to apply its own dracut conf.
See also:
https://github.com/rhkdump/kdump-utils/issues/11
https://github.com/rhkdump/kdump-utils/pull/31
Suggested-by: Dave Young <dyoung@redhat.com> Signed-off-by: Lichen Liu <lichliu@redhat.com>
Kernel integrity check in FIPS module is incompatible with UKIs as neither
/boot/vmlinuz-`uname-r` nor /boot/.vmlinuz-`uname-r`.hmac are present. UKI
is placed to $ESP\EFI\Linux\<install-tag>-<uname-r>.efi and if a .hmac file
is present next to it, it is possible to do similar check.
Note, UKIs have a 'one size fits all' command line and 'boot=' is not expected
to be set. Luckily, if the UKI is systemd-stub based then we can expect
'LoaderDevicePartUUID' variable containing PARTUUID of the ESP to be set. Mount
it to /boot using the existing logic.
Martin Wilck [Mon, 9 Sep 2024 07:43:01 +0000 (09:43 +0200)]
fix(nvmf): install (only) required nvmf modules
nvme_rdma was not installed, even if it was required, whereas
nvme_tcp was installed in non-TCP setups. nvme_fabrics will be
pulled in automatically by any transport module and doesn't
need to be installed explicitly.
Mike Schwarz [Tue, 10 Sep 2024 13:51:04 +0000 (15:51 +0200)]
fix(dracut): do not add all lib subdirs to `LD_LIBRARY_PATH` with `--sysroot`
On systems with too many library subdirectories, the current approach causes
`Argument list too long` errors, and the initrd also fails to build.
This patch does not fix the original issue by itself (i.e., libsystemd libs not
found), so all the dracut modules that require libraries stored in
subdirectories must explicitly install them using `inst_libdir_file`, which
already successfully handles the `--sysroot` prefix.
Ondrej Kubik [Fri, 26 Jul 2024 21:40:51 +0000 (21:40 +0000)]
fix(dracut-install): do not assume handled path starts with sysrootdir
When using --sysrootdir argument, we cannot assume fulldstpath and
fullsrcpath always start with sysrootdir. When dracut_install is
called on destination directory, this results in passing pointer which
is often beyond valid buffer.
Signed-off-by: Ondrej Kubik <ondrej.kubik@canonical.com>
Jo Zzsi [Sat, 7 Sep 2024 03:15:07 +0000 (23:15 -0400)]
test(BASIC): add support for XFS
XFS filesystem labels can be at most 12 characters long,
so move the test case for the ' rdinit=/bin/sh' label
to TEST-02 instead and keep TEST-01 simple.
Fabian Henze [Mon, 26 Aug 2024 20:05:35 +0000 (20:05 +0000)]
fix(systemd-networkd): remove basename dependency
The basename tool was not listed in the requirements and is also not needed.
Also see https://github.com/dracutdevs/dracut/commit/4c216b1db6a86373549e13b60250a7fcf94417b9
Jo Zzsi [Fri, 30 Aug 2024 00:53:30 +0000 (20:53 -0400)]
ci: add more packages to Debian and Ubuntu containers
Increase test coverage. Some of the newly added packages
are needed to to install some dracut modules and are already
installed for other CI containers.