On Thu, Nov 10, 2022 at 10:25:58AM +0800, Tao Liu wrote:
When the dump target is lvm2 thinp, if we didn't mount
the dump target first, get_fs_type_from_target will get
empty output:
Before mount:
$ get_fs_type_from_target /dev/vg00/thinlv
After mount:
$ mount /dev/vg00/thinlv /mnt
$ get_fs_type_from_target /dev/vg00/thinlv
ext4
As a result, kdumpctl start will fail with:
$ kdumpctl start
kdump: Dump target is invalid
kdump: Starting kdump: [FAILED]
This patch fix the issue by bypassing check_fs_modified
when the dump target is lvm2 thinp.
Signed-off-by: Tao Liu <ltao(a)redhat.com>
---
kdumpctl | 5 +++--
1 file changed, 3 insertions(+), 2 deletions(-)
diff --git a/kdumpctl b/kdumpctl
index 32a5458..313efd9 100755
--- a/kdumpctl
+++ b/kdumpctl
@@ -479,8 +479,9 @@ check_fs_modified()
fi
# No need to check in case of raw target.
- # Currently we do not check also if ssh/nfs/virtiofs target is specified
- if is_ssh_dump_target || is_nfs_dump_target || is_raw_dump_target ||
is_virtiofs_dump_target; then
+ # Currently we do not check also if ssh/nfs/virtiofs/thinp target is specified
+ if is_ssh_dump_target || is_nfs_dump_target || is_raw_dump_target ||
+ is_virtiofs_dump_target || is_lvm2_thinp_dump_target; then
Patch merged with a format change by shfmt, thanks!
Reviewed-by: Coiby Xu <coxu(a)redhat.com>
(The repo's commit msg has "Reviewed-by: Coiby Xu
<prudo(a)redhat.com>".
Sorry I can't revert it. Please ignore it.)
return 0
fi
--
2.33.1
--
Best regards,
Coiby