Using Nagios if my java process goes down I want to restart it when it stops. Is there an available api/listener from nagios to do the same and is this possible using nagios.
Any help on this would be useful.
thanks Lokesh
Using Nagios if my java process goes down I want to restart it when it stops. Is there an available api/listener from nagios to do the same and is this possible using nagios.
Any help on this would be useful.
thanks Lokesh
Use event handlers.
Here is a config i use
define service{
host_name mysql_host
service_description mysql
max_check_attempts 2
event_handler mysql_bounce
}
define command{
command_name mysql_bounce
command_line /opt/nagios/scripts/mysql_bounce
}
/opt/nagios/scripts/mysql_bounce contains the command to bounce mysql.