Skip to content
Open
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
16 changes: 9 additions & 7 deletions zfsbootmenu/lib/zfsbootmenu-core.sh
Original file line number Diff line number Diff line change
Expand Up @@ -456,13 +456,15 @@ kexec_kernel() {

echo -e "\nBooting $( colorize yellow "${kernel}" ) for $( colorize cyan "${fs}" ) ...\n"

if ! output="$( kexec -e -i 2>&1 )"; then
zerror "kexec -e -i failed!"
zerror "${output}"
timed_prompt -d 10 \
-m "$( colorize red "kexec run of ${kernel} failed!" )"
return 1
fi
# Try to kexec twice, the first attempt can fail intermittently
output="$( kexec -e -i 2>&1 )"
output="$( kexec -e -i 2>&1 )"

# If we ever reach this, it means our kexec failed
zerror "kexec -e -i failed!"
zerror "${output}"
timed_prompt -d 10 -m "$( colorize red "kexec run of ${kernel} failed!" )"
return 1
}

# arg1: snapshot name
Expand Down