mirror of
https://github.com/Security-Onion-Solutions/securityonion.git
synced 2025-12-06 17:22:49 +01:00
Only kill+start on final loop and increase time between status checks
This commit is contained in:
@@ -1650,13 +1650,16 @@ salt_checkin() {
|
|||||||
|
|
||||||
count=0
|
count=0
|
||||||
while ! (check_service_status "$service"); do
|
while ! (check_service_status "$service"); do
|
||||||
systemctl kill "$service"
|
if [ $count -eq 12 ]; then
|
||||||
systemctl start "$service"
|
systemctl kill "$service"
|
||||||
if [ $count -gt 120 ]; then
|
systemctl start "$service"
|
||||||
|
fi
|
||||||
|
|
||||||
|
if [ $count -gt 12 ]; then
|
||||||
echo "$service could not be restarted in 120 seconds, exiting" >> "$setup_log" 2>&1
|
echo "$service could not be restarted in 120 seconds, exiting" >> "$setup_log" 2>&1
|
||||||
kill -SIGUSR1 "$(ps --pid $$ -oppid=)"; exit 1
|
kill -SIGUSR1 "$(ps --pid $$ -oppid=)"; exit 1
|
||||||
fi
|
fi
|
||||||
sleep 1;
|
sleep 10;
|
||||||
((count++))
|
((count++))
|
||||||
done
|
done
|
||||||
done
|
done
|
||||||
|
|||||||
Reference in New Issue
Block a user