티스토리 뷰
>>> Monitor 스크립트 (/opt/VRTSvcs/bin/01_APPSVC/{monitor_svc})
#!/bin/ksh
file_stat_cron=`ls -al /opt/VRTSvcs/bin/01_APPSVC/|grep .app_stat_file_AP3CronAP`
if [ -z "${file_stat_cron}" ] ; then
exit 100;
else
exit 110;
fi
정도의 느낌으로 monitoring script를 작성하게 될건데, 이 때 exit 100 exit 110이 어떤 의미인지에 대해 궁금하단 말이지
그래서 Article같은거 없을까 했는데 역시나
About the monitor script exit codes (veritas.com)
About the monitor script exit codes
About the monitor script exit codes Custom monitor scripts use exit codes to let VCS know the status of the resource or process that is being monitored. The values that VCS expects as return values are: 1 or 100 - indicates that the resource is offline. 10
sort.veritas.com
요약하자면 exit 1 or exit 100 = offline
exit 0 or exit 110 = online
101~109 = 신뢰도가 100이 아니어도 온라인으로 표시
if [ -z] 의 경우 내부에 있는 저 file_stat_cron의 결과값이 0이면 참, 0이 아니면 거짓으로 산출한다는 거니까
참이 offline, 거짓이 online이 된다.
'Infoscale' 카테고리의 다른 글
| Fencing Configure - Using CP(Coordination Point) Server (1) | 2023.01.09 |
|---|