dracut-kdump.sh: recursively umount fs and its submounts
Certain dracut module will mount fs under real root(/sysroot/ or $NEWROOT/). Thus root fs can not be umounted by `umount /sysroot/`. We should use `umount -R /sysroot/` to recursively umount root and its submounts. v2: do the same for dump_fs() from Baoquan Signed-off-by: WANG Chao <chaowang@redhat.com> Signed-off-by: Baoquan He <bhe@redhat.com> Acked-by: Vivek Goyal <vgoyal@redhat.com>
This commit is contained in:
parent
fa0ec28b26
commit
7f59604e41
|
@ -74,7 +74,7 @@ dump_fs()
|
||||||
mv $_mp/$KDUMP_PATH/$HOST_IP-$DATEDIR/vmcore-incomplete $_mp/$KDUMP_PATH/$HOST_IP-$DATEDIR/vmcore
|
mv $_mp/$KDUMP_PATH/$HOST_IP-$DATEDIR/vmcore-incomplete $_mp/$KDUMP_PATH/$HOST_IP-$DATEDIR/vmcore
|
||||||
|
|
||||||
echo "kdump: saving vmcore complete"
|
echo "kdump: saving vmcore complete"
|
||||||
umount $_mp || return 1
|
umount -R $_mp || return 1
|
||||||
return 0
|
return 0
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -121,7 +121,7 @@ dump_to_rootfs()
|
||||||
|
|
||||||
echo "kdump: saving vmcore complete"
|
echo "kdump: saving vmcore complete"
|
||||||
sync
|
sync
|
||||||
umount $NEWROOT || return 1
|
umount -R $NEWROOT || return 1
|
||||||
return 0
|
return 0
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Reference in New Issue