aboutsummaryrefslogtreecommitdiffstats
path: root/deploy/adapters/ansible/roles/monitor/files/check_RedHat_service.sh
blob: 0fd921f48be4bf112a8e326dde2578ae51962948 (plain)
1
2
3
4
5
6
7
8
#!/bin/bash
services=`cat /opt/service | uniq`
for service in $services; do
    /usr/sbin/service $service status >/dev/null 2>&1
    if [[ $? -ne 0 ]]; then
        /usr/sbin/service $service start
    fi
done