Scenario A: When the ActiveMatrix Service Grid Host is Abnormally Shut down
Detect when connected ActiveMatrix Service Grid Host is abnormally shut down, and restart only if the EMS server is running:
Rulebase Name:
SystemNodeRB-${tibcohost.instance.name}
Microagents Used:
com.tibco.hawk.amx.AMXHost
com.tibco.hawk.tibjms.HawkListener
COM.TIBCO.hawk.hma.Process
- Procedure
- Use
AMXHost.isHostRunning()
to determine if the ActiveMatrix Service Grid host is runningif Running is
False
then post the '
th_not_running
' condition and send the medium level alert: "TibcoHost is not running
". - Use
AMXHost.getHostInfo
to determine the runtime state of the ActiveMatrix Service Grid host.if Runtime State = '
LOST_CONTACT
' or Runtime State='NOT_RUNNING
'then post '
th_lost_contact
' condition and send the medium alert: "Lost Contact with Tibco Host, Host is in a NOT_RUNNING state
". - Use
HawkListener<tibcohost.ems.url>.isRunning()
to determine the state of the EMS server connected to the ActiveMatrix Service Grid host.if running is
True
then
post ems.server.<tibcohost.ems.url>.isrunning
conditionif running is
False
then send the high alert: "
Tibcohost Qin EMS Server is down: Rules will NOT restart TH
". - Use
Process.getInstanceCount(ProcessName='tibcohost')
to determinewhether there is a running OS process for the ActiveMatrix Service Grid host.
if Process Count < 1 AND the following posted conditions exist:
ems.server.<tibcohost.ems.url>.isrunning
ANDth_not_running
then runstart_tibcohost
script, and send high alert: "ActiveMatrix Host is not running, going to restart it.
"