Skip to content

no_kmod/--no-kmod ignored when --kver is used #351

@nootshell

Description

@nootshell

As the title says, the no_kmod configuration value seems to be ignored when the kernel version is explicitly specified. I'm running a fully statically compiled kernel without any modules, my system therefore does not have a /lib/modules directory which makes ugrd freak out because it can't find that directory. I'm using installkernel to install the kernel and generate the initrd.

As a workaround, creating a installkernel hook that creates the /lib/modules/${kver} directory before the µgRD hook gets triggered seems to prevent µgRD from freaking out:

/lib/kernel/preinst.d/51-ugrd-fix.install
#!/usr/bin/env -S bash -CEe
readonly VERSION="${1}"; shift;
readonly IMAGE="${1}"; shift;

readonly LIBMOD_PATH="/lib/modules/${VERSION}";

if [[ -d "${LIBMOD_PATH}" ]]; then
    exit 0;
fi

mkdir -vp "${LIBMOD_PATH}";
touch "${LIBMOD_PATH}/.ugrd-fix";

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions