kdump-steamos: Move configuration file out of /etc

This patch main goal is to "un-Debianize" the configuration file
for kdump-steamos - thanks Emil (@xexaxo) for the discussions; it
is with a bit of a heavy heart I do that, but let's comply with the
modern distros ;-)

We hereby put the config file in a more standard path: /usr/share.
Usually users could override that with /etc/ file, but not in this
case, or at least, not for now. Kdump/pstore is expected to work
quietly, with no users' interference. Advanced users might want to
play with the configs though; and those can just go ahead and edit
the /usr/share/kdump/kdump.conf - it's all documented in the README.

In the future we can improve that by having the override mechanism
with the /etc file, let's see if we have a demand for that.

Signed-off-by: Guilherme G. Piccoli <gpiccoli@igalia.com>
This commit is contained in:
Guilherme G. Piccoli
2022-02-23 18:33:38 -03:00
parent 6ae626f17c
commit 5c1cc98502
7 changed files with 19 additions and 19 deletions

View File

@ -46,12 +46,12 @@ grub_update() {
fi
}
if [ ! -s "/etc/default/kdump" ]; then
logger "kdump-steamos: /etc/default/kdump not present - aborting..."
if [ ! -s "/usr/share/kdump/kdump.conf" ]; then
logger "kdump-steamos: /usr/share/kdump/kdump.conf is missing, aborting."
exit 0
fi
. /etc/default/kdump
. /usr/share/kdump/kdump.conf
# Find the proper mount point for /home:
DEVN_MOUNTED="$(findmnt "${MOUNT_DEVNODE}" -fno TARGET)"
@ -77,7 +77,7 @@ if [ "$1" = "clear" ]; then
exit 0
fi
# Pstore-RAM load; if it is configured via /etc/default/kdump and fails
# Pstore-RAM load; if it is configured via /usr/share/kdump/kdump.conf and fails
# to configure pstore, we still try to load the kdump. We try to reserve
# here a 5MiB memory region.
# Notice that we assume ramoops is a module here - if built-in, we should