|
Key
This line was removed.
This word was removed. This word was added.
This line was added.
|
Changes (24)
View Page Historyh1. Nagios configuration
h2. Core configuration
All the following configurations are grouped in the attached file to put in your directory [{{/etc/nagios3/conf.d/petals-esb.cfg}}|^petals-esb.cfg].
h2. JVM host template
h3. Petals ESB administrators
Define your Petals ESB administrator as following. For each administrator, don't forget to add it to the contact group:
{code}
define contact {
contact_name cde
alias Christophe DENEUX
host_notification_period 24x7
service_notification_period 24x7
host_notification_options d,u,r
service_notification_options w,u,c,r
host_notification_commands notify-host-by-email
service_notification_commands notify-service-by-email
email christophe.deneux@linagora.com
}
define contactgroup {
contactgroup_name petals-esb
alias Petals ESB Administrators
members cde
}
{code}
h3. JVM host template
{code}
define contact {
contact_name cde
alias Christophe DENEUX
host_notification_period 24x7
service_notification_period 24x7
host_notification_options d,u,r
service_notification_options w,u,c,r
host_notification_commands notify-host-by-email
service_notification_commands notify-service-by-email
email christophe.deneux@linagora.com
}
define contactgroup {
contactgroup_name petals-esb
alias Petals ESB Administrators
members cde
}
{code}
h3. JVM host template
A best practice to monitor Java application is to create a template 'JVM host':
{code}
{code}
{code}
h23. Nagios commands definition to interact with a SNMP agent
We recommand to define specific Nagios command to interact with the Java virtual machine MIB.
{code}
h23. Petals ESB host template
A best practice to monitor Petals ESB nodes is to create a template 'Petals ESB host' that inherits from the 'JVM host':
name petals-esb-host ; The name of this host template
register 0 ; DONT REGISTER THIS DEFINITION - ITS NOT A REAL HOST, JUST A TEMPLATE!
register 0 ; DONT REGISTER THIS DEFINITION - ITS NOT A REAL HOST, JUST A TEMPLATE!
contact_groups petals-esb
# Specific attributes
{code}
h23. Defining your Petals ESB hosts
For each Petals ESB node of your Petals ESB topology, create an instance of the template 'petals-esb-host':
{code}
h23. Defining your Petals ESB topology as a Petals ESB host group
The Petals ESB topology can be considered as a Nagios host group composed of your Petals ESB nodes:
{code}
h23. Petals ESB host services
We group all Petals ESB host services:
check_command check_disk!20%!10%!/var
servicegroups petals-services
servicegroups petals-services
contact_groups petals-esb
}
check_command check_load!5.0!4.0!3.0!10.0!6.0!4.0
servicegroups petals-services
servicegroups petals-services
}
contact_groups petals-esb
}
}
# Define a service to check the heap memory used by Petals ESB node.
check_command jvm_heapused!public!2c!912680550!1020054732
servicegroups petals-services
servicegroups petals-services
}
contact_groups petals-esb
}
}
# Define a service to check the max (commited) heap memory used by Petals ESB node.
check_command jvm_heapmaxused!public!2c!912680550!1020054732
servicegroups petals-services
servicegroups petals-services
}
contact_groups petals-esb
}
}
{code}
h2. Petals BC Soap services SOAP configuration
h3. Active checks
To add services associated to the BC SOAP, you can add a service based on the [following one|^petals-esb-bcsoap.cfg] [here|https://anonymous:anonymous@svn.petalslink.org/svnroot/trunk/product/dev/prod/petals/client-tools/petals-nagios/src/cfg/petals-esb-bcsoap.cfg] that check the current number of allocated threads of the HTTP thread pool:
{code}
########################################################
########################################################
use generic-service
hostgroup_name petals-esb
hostgroup_name petals-esb
service_description petals-esb-bcsoap-httpthreadpool-current-allocated
service_description display_name Petals BC SOAP - HTTP Thread Pool - Current allocated thread
check_command petals_bcsoap_httpthreadpool_currentallocatedthreads!petals-bc-soap!40!45
servicegroups petals-services
servicegroups petals-services
contact_groups petals-esb
}
{code}
where {{check_petals_bcsoap}} is a nagios plugin wrapping Petals CLI. You can get a such plugin [here|^check_petals_bcsoap].
{code}
where {{check_petals_bcsoap}} is a nagios plugin wrapping Petals CLI. You can get a such plugin [here|^check_petals_bcsoap].
h3. Passive check
The probes available in the BC SOAP are available to send JMX notifications when they detect a defect. These notifications can be sent to Nagios with a dedicated new monitoring command of Petals CLI (this command does not exist yet) that receive JMX notification and write in the channel of the Nagios passive checks.
For example, when no more threads is available in the HTTP thread pool of the BC SOAP:
{code}
echo "[`date +%s`] PROCESS_SERVICE_CHECK_RESULT;petals-esb-node-1;petals-esb-bcsoap-httpthreadpool-current-allocated;2;No more thread available" > /var/lib/nagios3/rw/nagios.cmd
{code}
The probes available in the BC SOAP are available to send JMX notifications when they detect a defect. These notifications can be sent to Nagios with a dedicated new monitoring command of Petals CLI (this command does not exist yet) that receive JMX notification and write in the channel of the Nagios passive checks.
For example, when no more threads is available in the HTTP thread pool of the BC SOAP:
{code}
echo "[`date +%s`] PROCESS_SERVICE_CHECK_RESULT;petals-esb-node-1;petals-esb-bcsoap-httpthreadpool-current-allocated;2;No more thread available" > /var/lib/nagios3/rw/nagios.cmd
{code}
h2. Restart Nagios