dracut-kdump.sh: name the invalid vmcore to vmcore-incomplete
When makedumpfile failed, it could still generate a invalid vmcore. It's better to suffix these invalid vmcore files with "-incomplete", as we do in RHEL6. Signed-off-by: WANG Chao <chaowang@redhat.com> Acked-by: Vivek Goyal <vgoyal@redhat.com>
This commit is contained in:
parent
1520307adf
commit
7c7cbef612
@ -70,7 +70,8 @@ dump_fs()
|
||||
save_vmcore_dmesg_fs ${DMESG_COLLECTOR} "$_mp/$KDUMP_PATH/$HOST_IP-$DATEDIR/"
|
||||
|
||||
echo "kdump: saving vmcore"
|
||||
$CORE_COLLECTOR /proc/vmcore $_mp/$KDUMP_PATH/$HOST_IP-$DATEDIR/vmcore || return 1
|
||||
$CORE_COLLECTOR /proc/vmcore $_mp/$KDUMP_PATH/$HOST_IP-$DATEDIR/vmcore-incomplete || return 1
|
||||
mv $_mp/$KDUMP_PATH/$HOST_IP-$DATEDIR/vmcore-incomplete $_mp/$KDUMP_PATH/$HOST_IP-$DATEDIR/vmcore
|
||||
|
||||
echo "kdump: saving vmcore complete"
|
||||
umount $_mp || return 1
|
||||
@ -113,7 +114,8 @@ dump_to_rootfs()
|
||||
save_vmcore_dmesg_fs ${DMESG_COLLECTOR} "$NEWROOT/$KDUMP_PATH/$HOST_IP-$DATEDIR/"
|
||||
|
||||
echo "kdump: saving vmcore"
|
||||
$CORE_COLLECTOR /proc/vmcore $NEWROOT/$KDUMP_PATH/$HOST_IP-$DATEDIR/vmcore || return 1
|
||||
$CORE_COLLECTOR /proc/vmcore $NEWROOT/$KDUMP_PATH/$HOST_IP-$DATEDIR/vmcore-incomplete || return 1
|
||||
mv $NEWROOT/$KDUMP_PATH/$HOST_IP-$DATEDIR/vmcore-incomplete $NEWROOT/$KDUMP_PATH/$HOST_IP-$DATEDIR/vmcore
|
||||
|
||||
echo "kdump: saving vmcore complete"
|
||||
sync
|
||||
|
Loading…
Reference in New Issue
Block a user