summaryrefslogtreecommitdiff
path: root/man/systemd-pstore.service.xml
diff options
context:
space:
mode:
authorEric DeVolder <eric.devolder@oracle.com>2020-04-13 16:22:04 -0500
committerLennart Poettering <lennart@poettering.net>2020-05-15 23:15:26 +0200
commitf00c36641a253f4ea659ec3def5d87ba1336eb3b (patch)
tree76f09c69c3be43f569107a128e5330a8d7864582 /man/systemd-pstore.service.xml
parentb4e1563ffb12c50ff89c063e721b76bfc89407b7 (diff)
downloadsystemd-f00c36641a253f4ea659ec3def5d87ba1336eb3b.tar.gz
pstore: introduce tmpfiles.d/systemd-pstore.conf
The systemd pstore service archives the contents of /sys/fs/pstore upon boot so that there is room for a subsequent dump. The issue is that while the service is present, the kernel still needs to be configured to write data into the pstore. The kernel has two parameters, crash_kexec_post_notifiers and printk.always_kmsg_dump, that control writes into pstore. The crash_kexec_post_notifiers parameter enables the kernel to write dmesg (including stack trace) into pstore upon a panic, and printk.always_kmsg_dump parameter enables the kernel to write dmesg upon a shutdown (shutdown, reboot, halt). As it stands today, these parameters are not managed/manipulated by the systemd pstore service, and are solely reliant upon the user [to have the foresight] to set them on the kernel command line at boot, or post boot via sysfs. Furthermore, the user would need to set these parameters in a persistent fashion so that that they are enabled on subsequent reboots. This patch introduces the setting of these two kernel parameters via the systemd tmpfiles technique.
Diffstat (limited to 'man/systemd-pstore.service.xml')
-rw-r--r--man/systemd-pstore.service.xml18
1 files changed, 18 insertions, 0 deletions
diff --git a/man/systemd-pstore.service.xml b/man/systemd-pstore.service.xml
index 47916da521..335a3b3d18 100644
--- a/man/systemd-pstore.service.xml
+++ b/man/systemd-pstore.service.xml
@@ -81,6 +81,24 @@
<citerefentry><refentrytitle>pstore.conf</refentrytitle><manvolnum>5</manvolnum></citerefentry>.
</para>
</refsect2>
+
+ <refsect2>
+ <title>Controlling kernel parameters</title>
+
+ <para> The kernel has two parameters,
+ <filename>/sys/module/kernel/parameters/crash_kexec_post_notifiers</filename> and
+ <filename>/sys/module/printk/parameters/always_kmsg_dump</filename>,
+ that control writes into pstore.
+ The crash_kexec_post_notifiers parameter enables the kernel to write
+ dmesg (including stack trace) into pstore upon a panic or crash, and
+ printk.always_kmsg_dump parameter enables the kernel to write dmesg
+ upon a normal shutdown (shutdown, reboot, halt). These kernel
+ parameters are managed via the
+ <citerefentry><refentrytitle>tmpfiles.d</refentrytitle><manvolnum>5</manvolnum></citerefentry>
+ mechanism, specifically the file <filename>/usr/lib/tmpfiles/systemd-pstore.conf</filename>.
+ </para>
+ </refsect2>
+
</refsect1>
<refsect1>