After removing "root=X" we add the root mount information
explicitly from the kdump side, so we need this change
to avoid rebuild when the dump target is root.
Signed-off-by: Xunlei Pang <xlpang(a)redhat.com>
---
kdumpctl | 15 ++++++++++-----
1 file changed, 10 insertions(+), 5 deletions(-)
diff --git a/kdumpctl b/kdumpctl
index 09901fd..db38879 100755
--- a/kdumpctl
+++ b/kdumpctl
@@ -512,11 +512,16 @@ check_dump_fs_modified()
fi
fi
- if ! findmnt $_target >/dev/null; then
- echo "Dump target $_target is probably not mounted."
- return 2
- fi
- _new_mntpoint="/kdumproot/$(get_mntpoint_from_target $_target)"
+ if ! findmnt $_target >/dev/null; then
+ echo "Dump target $_target is probably not mounted."
+ return 2
+ fi
+
+ if [[ "$_target" = "$(get_root_fs_device)" ]]; then
+ _new_mntpoint="/sysroot/$(get_mntpoint_from_target $_target)"
+ else
+ _new_mntpoint="/kdumproot/$(get_mntpoint_from_target $_target)"
+ fi
_dracut_args=$(lsinitrd $TARGET_INITRD | grep "^Arguments:" | head -1)
if [[ -z "$_dracut_args" ]];then
--
1.8.3.1