kdump-load/config: Add config option to override custom kdump kernel cmdline
Also document a bit better why some parameters are added and why we remove huge pages parameters, for example. Signed-off-by: Guilherme G. Piccoli <gpiccoli@igalia.com>
This commit is contained in:
@ -35,10 +35,16 @@ MOUNT_FOLDER="/home/.steamos/offload/var/kdump"
|
||||
# If FULL_COREDUMP is !=0, we collect a full compressed vmcore, which might
|
||||
# require a lot of disk space. The MAKEDUMPFILE_*_CMD settings refer to
|
||||
# tunings on makedumpfile - we rely on zstd compression and maximum page
|
||||
# exclusion for the full vmcore, mimic'ing Debian/Ubuntu kdump.
|
||||
# exclusion for the full vmcore, mimic'ing Debian/Ubuntu kdump. We also
|
||||
# base on Debian/Ubuntu for the KDUMP_CMDLINE_APPEND option - this contains
|
||||
# the kernel parameters we append in the /proc/cmdline for the kdump kernel;
|
||||
# the most important parameters are nr_cpus=1 (to save RAM memory usage and
|
||||
# avoid some potential issues with SMP) and reset_devices (some drivers
|
||||
# rely on that for proper kdump).
|
||||
FULL_COREDUMP=0
|
||||
MAKEDUMPFILE_COREDUMP_CMD="-z -d 31"
|
||||
MAKEDUMPFILE_DMESG_CMD="--dump-dmesg"
|
||||
KDUMP_APPEND_CMDLINE="panic=-1 oops=panic fsck.mode=force fsck.repair=yes nr_cpus=1 reset_devices"
|
||||
#
|
||||
#
|
||||
# GRUB-related settings
|
||||
|
||||
@ -177,10 +177,11 @@ fi
|
||||
cleanup_unused_initrd
|
||||
grub_update kdump
|
||||
|
||||
# After some consideration, we've stolen the kdump parameters from
|
||||
# Debian/Ubuntu implementation, it makes sense for us.
|
||||
# The kdump kernel command-line has some parameters appended, check
|
||||
# the configuration files in order to change that. We also remove huge
|
||||
# pages settings here (and crashkernel reservation), to save memory on kdump.
|
||||
KDUMP_CMDLINE=$(sed -re 's/(^| )(crashkernel|hugepages|hugepagesz)=[^ ]*//g;s/"/\\\\"/' /proc/cmdline)
|
||||
KDUMP_CMDLINE="${KDUMP_CMDLINE} panic=-1 oops=panic fsck.mode=force fsck.repair=yes nr_cpus=1 reset_devices"
|
||||
KDUMP_CMDLINE="${KDUMP_CMDLINE} ${KDUMP_APPEND_CMDLINE}"
|
||||
|
||||
# To obtain the vmlinux binary path, try first using directly the command-line
|
||||
# information. If it fails, then attempt prepending /boot into that (faced
|
||||
|
||||
Reference in New Issue
Block a user