From 6dd2b9fb419966cfe23f3821993bd909b85d45a2 Mon Sep 17 00:00:00 2001 From: Pingfan Liu Date: Fri, 19 Jun 2020 11:37:02 +0800 Subject: [PATCH] man: improve description about /etc/kdump/{pre.d,post.d}interface The description is identical to the notes in kdump.conf Signed-off-by: Pingfan Liu Acked-by: Kairui Song --- kdump.conf.5 | 12 ++++++++++++ kexec-kdump-howto.txt | 8 ++++++++ 2 files changed, 20 insertions(+) diff --git a/kdump.conf.5 b/kdump.conf.5 index 5a0952b..9f2b2b6 100644 --- a/kdump.conf.5 +++ b/kdump.conf.5 @@ -109,6 +109,11 @@ status of the current dump process is fed to the kdump_post executable as its first argument($1). Executable can modify it to indicate the new exit status of succeeding dump process, .PP +If /etc/kdump/post.d directory exists, All files in +the directory are collectively sorted and executed in +lexical order, before binary or script specified +kdump_post parameter is executed. +.PP Note that scripts written for use with this directive must use the /bin/bash interpreter. .RE @@ -124,6 +129,13 @@ as follows: .PP non 0 - reboot the system .PP +If /etc/kdump/pre.d directory exists, all files in +the directory are collectively sorted and executed in +lexical order, after binary or script specified +kdump_pre parameter is executed. +Even if the binary or script in /etc/kdump/pre.d directory +returns non 0 exit status, the processing is continued. +.PP Note that scripts written for this directive must use the /bin/bash interpreter. .RE diff --git a/kexec-kdump-howto.txt b/kexec-kdump-howto.txt index 78ebf69..9b0fee2 100644 --- a/kexec-kdump-howto.txt +++ b/kexec-kdump-howto.txt @@ -543,6 +543,9 @@ It is possible to specify a custom script or binary you wish to run following an attempt to capture a vmcore. The executable is passed an exit code from the capture process, which can be used to trigger different actions from within your post-capture executable. +If /etc/kdump/post.d directory exist, All files in the directory are +collectively sorted and executed in lexical order, before binary or script +specified kdump_post parameter is executed. Kdump Pre-Capture Executable ---------------------------- @@ -551,6 +554,11 @@ It is possible to specify a custom script or binary you wish to run before capturing a vmcore. Exit status of this binary is interpreted: 0 - continue with dump process as usual non 0 - reboot the system +If /etc/kdump/pre.d directory exists, all files in the directory are collectively +sorted and executed in lexical order, after binary or script specified +kdump_pre parameter is executed. +Even if the binary or script in /etc/kdump/pre.d directory returns non 0 +exit status, the processing is continued. Extra Binaries --------------