v-restart-web: systemctl instead of service

This commit is contained in:
myvesta 2023-10-08 15:21:43 +02:00 committed by GitHub
commit 9c233e92a6
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -64,7 +64,9 @@ fi
# Resart web system if reload didn't work # Resart web system if reload didn't work
if [ "$rc" -ne 0 ]; then if [ "$rc" -ne 0 ]; then
service $WEB_SYSTEM restart >/dev/null 2>&1 # service $WEB_SYSTEM restart >/dev/null 2>&1
systemctl reset-failed
systemctl restart $WEB_SYSTEM >/dev/null 2>&1
if [ $? -ne 0 ]; then if [ $? -ne 0 ]; then
send_email_report send_email_report
check_result $E_RESTART "$WEB_SYSTEM restart failed" check_result $E_RESTART "$WEB_SYSTEM restart failed"