From bcdcf35759833f33039a6ae46b2b0407ab80da41 Mon Sep 17 00:00:00 2001 From: Kairui Song Date: Tue, 3 Dec 2019 13:02:00 +0800 Subject: [PATCH] Fix potential ssh/nfs kdump failure of missing "ip" command For ssh/nfs dump, kdump need the 'ip' tool to get the host ip address for naming the vmcore. But kdump-module-setup.sh never installed this tool. kdump-module-setup.sh worked so far as dracut network module will help install it. After dracut changed to use 35network-manager for network setup, "ip" command won't be installed in second kernel by default. So need to ensure "ip" is installed when installing kdump dracut module. Signed-off-by: Kairui Song Acked-by: Pingfan Liu --- dracut-module-setup.sh | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/dracut-module-setup.sh b/dracut-module-setup.sh index 8e9fe42..9babae8 100755 --- a/dracut-module-setup.sh +++ b/dracut-module-setup.sh @@ -839,6 +839,11 @@ install() { # at some point of time. kdump_check_iscsi_targets + # nfs/ssh dump will need to get host ip in second kernel and need to call 'ip' tool, see get_host_ip for more detail + if is_nfs_dump_target || is_ssh_dump_target; then + inst "ip" + fi + # For the lvm type target under kdump, in /etc/lvm/lvm.conf we can # safely replace "reserved_memory=XXXX"(default value is 8192) with # "reserved_memory=1024" to lower memory pressure under kdump. We do