Nagios Plugin

Navigation:  »No topics above this level«

Nagios Plugin

Previous pageReturn to chapter overviewNext page

check_kcare is a Nagios plugin that provides a way to monitor the out of date and inactive servers. It can provide information on servers assigned to the KernelCare key, or for all the servers in partner account.

 

You can download the plugin from http://patches.kernelcare.com/downloads/nagios/check_kcare

 

Place the plugin into /usr/lib/nagios/plugins/ directory.

 

To use the plugin you need to configure Nagios. You will also need your KernelCare key or login & API security token from your partner account. You can find it in Profile section of your partner account.

 

Script options:

 

-k KERNELCARE_KEY

retrieve status for servers associated with KEY

-l PARTNER_LOGIN --api-token TOKEN

retrieve status for all servers in partner account based on login/token

-c o,u,i -- return CRITICAL

list of coma separate o, u & i. o -- out of date, u - unknown kernel, i - inactive server

-w o,u,i -- return WARNING

list of coma separate o, u & i. o -- out of date, u - unknown kernel, i - inactive server

 

 

Here is an example configuration:

 

Example host to associate the KernelCare status check service with

 

define host {

       host_name                       kcare-service

       notifications_enabled           0

       max_check_attempts              1

       notification_interval           0

       check_period                    never

       contacts                        server-admins

}

 

 

define command {

       command_name     check_kcare

       command_line     /usr/lib/nagios/plugins/check_kcare -k $ARG1$

}

 

define command {

       command_name     check_kcare_opts

       command_line     /usr/lib/nagios/plugins/check_kcare -k $ARG1$ -c $ARG2$ -w $ARG3$

}

define command {

       command_name     check_kcare_partner

       command_line     /usr/lib/nagios/plugins/check_kcare -l $ARG1$ --api-token $ARG2$

}

 

define command {

       command_name     check_kcare_partner_opts

       command_line     /usr/lib/nagios/plugins/check_kcare -k $ARG1$  -l $ARG1$ --api-token $ARG2$ -c $ARG2$ -w $ARG3$

}

 

define service {

       host_name                       kcare-service

       service_description             KernelCare Server Status Checker By Key

       check_command                   check_kcare!KCAREKEY

       notifications_enabled           1

       check_interval                  240

       retry_interval                  60

       max_check_attempts              4

       notification_options            w,c,r

       contacts                        server-admins

}

 

define service {

       host_name                       kcare-service

       service_description             KernelCare Server Status Checker By login/token with outdated/inactive considered as critical

       check_command                   check_kcare_partner_opts!parnter_login!partner_token!o,i!u

       notifications_enabled           1

       check_interval                  240

       retry_interval                  60

       max_check_attempts              4

       notification_options            w,c,r

       contacts                        server-admins

}