Skip to content

crash-recover: Allow local override #143

Merged
merged 1 commit into from
Dec 6, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 5 additions & 0 deletions crashkernel/crash-recovery.sh
Original file line number Diff line number Diff line change
Expand Up @@ -55,6 +55,11 @@ core_size=$(stat -c %s /proc/vmcore)

mount -o remount,rw / /

if test -x /etc/local/crash-recovery.sh; then
. /etc/local/crash-recovery.sh
reboot "/etc/local/crash-recovery.sh has finished"
fi

if mount -L CRASHDUMP /mnt; then
test -e /mnt/crash.vmcore && rm /mnt/crash.vmcore
if (( $(free_space /mnt) - $core_size > 1024*1024*1024 )); then
Expand Down