"MaJ ctl_all_nrpe.sh"

This commit is contained in:
Doug Le Tough 2017-07-23 09:16:08 +02:00
parent 2fb2322eff
commit 52a08ae3e7
2 changed files with 2 additions and 3 deletions

View File

@ -182,15 +182,15 @@ function check_all
function check_process
{
fct_message "Vérification des processus:"
for PROC in ${PROCESS[@]}
do
HOST=$(echo ${PROC} | cut -d: -f1)
PROC=$(echo ${PROC} | cut -d: -f2)
fct_message "Vérification du process ${PROC} sur ${HOST}"
ctl_host_process.sh -vm ${HOST} -process ${PROC}
RET_VAL=$?
if [ ! ${RET_VAL} -eq 0 ]; then
fct_message "Processus ${PROC} inexistant sur ${HOST}" -color orange
fct_message "Processus ${PROC} inexistant sur ${HOST}" -color rose
MESSAGE="${MESSAGE}|||${HOST}: CRITICAL: Processus ${PROC} inexistant sur ${HOST}"
fi
done

View File

@ -33,4 +33,3 @@ PROCESS[19]=billy.local.tetalab.org:/usr/sbin/ntpd
PROCESS[20]=billy.local.tetalab.org:/usr/sbin/crond
PROCESS[21]=billy.local.tetalab.org:/usr/bin/nrpe
PROCESS[22]=billy.local.tetalab.org:/usr/sbin/httpd
PROCESS[22]=billy.local.tetalab.org:/usr/sbin/test_monitoring_a_la_con