diff --git a/bin/netupgrade b/bin/netupgrade index 03696f6..c2bb1bf 100755 --- a/bin/netupgrade +++ b/bin/netupgrade @@ -201,8 +201,11 @@ runCmd() { # $1=host $2=name $3=cmd case ${CMD} in reboot) - if ! runSSH "${HOST}" reboot | tee -a "${LOGFILENAME}"; then + echo "reboot (detached)" | tee -a "${LOGFILENAME}" + if ! runSSH "${HOST}" sh -c 'nohup sh -c "reboot || /sbin/reboot || shutdown -r now" >/dev/null 2>&1