An user can pass "nowdt 1" in kdump.conf if watchdog driver for active
watchdog is not needed in kdump initramfs.
Signed-off-by: Pratyush Anand <panand(a)redhat.com>
---
kdump.conf | 14 ++++++++++++++
kdump.conf.5 | 11 +++++++++++
kdumpctl | 2 +-
mkdumprd | 8 +++++++-
4 files changed, 33 insertions(+), 2 deletions(-)
diff --git a/kdump.conf b/kdump.conf
index 54b581daf93b..29d3e50aec63 100644
--- a/kdump.conf
+++ b/kdump.conf
@@ -141,6 +141,19 @@
# - List of cluster node(s) separated by space to send fence_kdump
# notification to (this option is mandatory to enable fence_kdump).
#
+# nowdt <0 | 1>
+# - If a watchdog is active in first kernel then, we
+# must have it's module loaded in crash kernel, so
+# that either watchdog is deactivated or started
+# being kicked in second kernel. Otherwise, we might
+# face watchdog reboot when vmcore was being saved.
+# By default, nowdt is false and kdump initrd will
+# contain modules for active watchdog. If a watchdog
+# module (such as hp_wdt) has not been written using
+# watchdog-core framework then this option will not
+# have any effect and module will not be added.
+# Please note that only systemd watchdog daemon is
+# supported as watchdog kick application.
#raw /dev/vg/lv_kdump
#ext4 /dev/vg/lv_kdump
@@ -158,6 +171,7 @@ core_collector makedumpfile -l --message-level 1 -d 31
#extra_modules gfs2
#default shell
#force_rebuild 1
+#nowdt 1
#dracut_args --omit-drivers "cfg80211 snd" --add-drivers "ext2 ext3"
#fence_kdump_args -p 7410 -f auto -c 0 -i 10
#fence_kdump_nodes node1 node2
diff --git a/kdump.conf.5 b/kdump.conf.5
index f1c2a2c1d24e..b01566df8aff 100644
--- a/kdump.conf.5
+++ b/kdump.conf.5
@@ -199,6 +199,17 @@ List of cluster node(s) separated by space to send fence_kdump
notification
to (this option is mandatory to enable fence_kdump).
.RE
+.B nowdt <0 | 1>
+.RS
+If a watchdog is active in first kernel then, we must have it's module
+loaded in crash kernel, so that either watchdog is deactivated or started
+being kicked in second kernel. Otherwise, we might face watchdog reboot
+when vmcore was being saved. By default, nowdt is false and kdump initrd
+will contain modules for active watchdog. If a watchdog module (such as
+hp_wdt) has not been written using watchdog-core framework then this option
+will not have any effect and module will not be added. Please note that
+only systemd watchdog daemon is supported as watchdog kick application.
+.RE
.SH DEPRECATED OPTIONS
diff --git a/kdumpctl b/kdumpctl
index 12e7aa005c5d..06eb8d6af798 100755
--- a/kdumpctl
+++ b/kdumpctl
@@ -248,7 +248,7 @@ check_config()
case "$config_opt" in
\#* | "")
;;
- raw|ext2|ext3|ext4|minix|btrfs|xfs|nfs|ssh|sshkey|path|core_collector|kdump_post|kdump_pre|extra_bins|extra_modules|default|force_rebuild|dracut_args|fence_kdump_args|fence_kdump_nodes)
+ raw|ext2|ext3|ext4|minix|btrfs|xfs|nfs|ssh|sshkey|path|core_collector|kdump_post|kdump_pre|extra_bins|extra_modules|default|force_rebuild|dracut_args|fence_kdump_args|fence_kdump_nodes|nowdt)
[ -z "$config_val" ] && {
echo "Invalid kdump config value for option $config_opt."
return 1;
diff --git a/mkdumprd b/mkdumprd
index eb0d5e06fac9..f79733c3fd7e 100644
--- a/mkdumprd
+++ b/mkdumprd
@@ -15,9 +15,15 @@ SAVE_PATH=$(grep ^path $conf_file| cut -d' ' -f2)
[ -z "$SAVE_PATH" ] && SAVE_PATH=$DEFAULT_PATH
# strip the duplicated "/"
SAVE_PATH=$(echo $SAVE_PATH | tr -s /)
+NOWDT=$(grep ^nowdt $conf_file| cut -d' ' -f2)
+if [ -z $NOWDT ];then
+ NOWDT="-a watchdog"
+else
+ NOWDT="-o watchdog"
+fi
extra_modules=""
-dracut_args=("--hostonly" "-o" "plymouth dash resume
ifcfg")
+dracut_args=("--hostonly" "-o" "plymouth dash resume ifcfg"
$NOWDT)
OVERRIDE_RESETTABLE=0
add_dracut_arg() {
--
2.5.5