Operating System - Linux
1753674 Members
5352 Online
108799 Solutions
New Discussion

Restart monitored service

 
Matthias Kretschmer
Frequent Advisor

Restart monitored service

Hello,
We are running HP Serviceguard on RHEL5.
We have a package that starts and monitors a oracle database, the listener and a service called "MFC_APP" which is our application.
The monitoring is fine. We use the HP oracle toolkit. When ever a service fails the package fails and startup on the other node.
Now we want to enable 1 possible restart for the listener and our service (MFC_APP).

I configured:
SERVICE_NAME[0]=ORACLE_WPIR
SERVICE_CMD[0]="/usr/local/cmcluster/pkg/test_pkg/toolkit.sh monitor"
SERVICE_RESTART[0]="-r 0"

SERVICE_NAME[1]=LISTENER
SERVICE_CMD[1]="/usr/local/cmcluster/pkg/test_pkg/toolkit.sh monitor_listener"
SERVICE_RESTART[1]="-r 1"

SERVICE_NAME[2]=MFC_APP
SERVICE_CMD[2]="/usr/local/cmcluster/pkg/test_pkg/mfc_app.sh monitor"
SERVICE_RESTART[2]="-r 1"

If the listener fails, it restarts one time. -> This works.
If our application fails, the package fails at the first time.

What I am not understanding:
How can a restart of the monitor script restart the service itselfe. Is this a ability that the monitor script hase to have? I think so.
How does the monitor script has to look like to do this?

Thank you in advance
Matthias Kretschmer