diff --git a/linux/evocheck.sh b/linux/evocheck.sh index 685bf1c..92cf81e 100755 --- a/linux/evocheck.sh +++ b/linux/evocheck.sh @@ -683,7 +683,7 @@ check_phpmyadminapacheconf() { check_kerneluptodate() { if is_installed linux-image*; then # shellcheck disable=SC2012 - kernel_installed_at=$(date -d "$(ls --full-time -lcrt /boot | tail -n1 | awk '{print $6}')" +%s) + kernel_installed_at=$(date -d "$(ls --full-time -lcrt /boot/*lin* | tail -n1 | awk '{print $6}')" +%s) last_reboot_at=$(($(date +%s) - $(cut -f1 -d '.' /proc/uptime))) if [ "$kernel_installed_at" -gt "$last_reboot_at" ]; then failed "IS_KERNELUPTODATE" "machine is running an outdated kernel, reboot advised"