kdump-load.sh: Simplify the dracut command

As per Emil (@xexaxo) suggestion, change the dracut mechanism
added in a recent commit for log pollution prevention.

It is waaay simpler to just directly use the variable that prevents
dracut to flood the output with xattr harmless complaints.
Previous approach was an unfortunate braino from myself.

Signed-off-by: Guilherme G. Piccoli <gpiccoli@igalia.com>
This commit is contained in:
Guilherme G. Piccoli
2022-08-08 19:04:25 -03:00
parent 36a73da65b
commit f1173b0ee4

View File

@ -52,16 +52,10 @@ create_initrd() {
mkdir -p "${KDUMP_FOLDER}"
rm -f "${KDUMP_FOLDER}/kdump-initrd-$(uname -r).img"
# Let's prevent journal pollution due to potential xattr issues...
DRACUT_XATTR="${DRACUT_NO_XATTR}"
export DRACUT_NO_XATTR=1
echo "Creating the kdump initramfs for kernel \"$(uname -r)\" ..."
dracut --no-early-microcode --host-only -q -m\
DRACUT_NO_XATTR=1 dracut --no-early-microcode --host-only -q -m\
"bash systemd systemd-initrd systemd-sysusers modsign dbus-daemon kdump dbus udev-rules dracut-systemd base fs-lib shutdown"\
--kver "$(uname -r)" "${KDUMP_FOLDER}/kdump-initrd-$(uname -r).img"
export DRACUT_NO_XATTR=${DRACUT_XATTR}
}
# This routine performs a clean-up by deleting the old/useless remaining