Understanding check_cluster

Thomas Guyot-Sionnest dermoth at aei.ca
Fri Feb 27 13:28:51 CET 2009


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On 24/02/09 07:03 PM, Lee Azzarello wrote:
> Here's my config. It's functional:
> 
> define command{
>   command_name	    check-cluster-health
>   command_line	    /usr/lib/nagios/plugins/check_cluster --service -l
> $ARG1$ -w $ARG2$ -c $ARG3$ -d $ARG4$
> }
> 
> define service{
>   service_description	check-cluster-health
>   host			app-proxy
>   check_command		check-cluster-health!"App Thread
> Health"!0!1!$SERVICESTATEID:app-1:mongrel-count$,$SERVICESTATEID:app-2:mongrel-count$,$SERVICESTATEID:app-3:mongrel-count$,$SERVICESTATEID:app-4:mongrel-count$
>   use			serviceClusterTemplate
> }
> 
> define service{
>   service_description	mongrel-count
>   hostgroup		app-servers,manager-servers
>   check_command		check_nrpe_1arg!check_mongrel_count
>   notifications_enabled	0
>   use			serviceClusterTemplate
> }

Indeed, here's some more macro examples:
$HOSTDOWNTIME:myhost$                       <--- On-demand host macro
$SERVICESTATEID:novellserver:DS Database$   <--- On-demand service macro

You can also use hostgroups/servicegroups with a delimiter (delimiter
should be ',' for check_cluster)

# $HOSTMACRONAME:hostgroup_name:delimiter$
# $SERVICEMACRONAME:servicegroup_name:delimiter$

See the Nagios documentation for more details...
http://nagios.sourceforge.net/docs/3_0/macros.html

- --
Thomas
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org

iD8DBQFJp9yD6dZ+Kt5BchYRArtxAKDA2rdPcIsA4dqVUUS3RDUwYJYeOQCgl/Nl
4RywRCmCMXfFmwWTfryiYTo=
=g5Ya
-----END PGP SIGNATURE-----

------------------------------------------------------------------------------
Open Source Business Conference (OSBC), March 24-25, 2009, San Francisco, CA
-OSBC tackles the biggest issue in open source: Open Sourcing the Enterprise
-Strategies to boost innovation and cut costs with open source participation
-Receive a $600 discount off the registration fee with the source code: SFAD
http://p.sf.net/sfu/XcvMzF8H
_______________________________________________
Nagios-users mailing list
Nagios-users at lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/nagios-users
::: Please include Nagios version, plugin version (-v) and OS when reporting any issue. 
::: Messages without supporting info will risk being sent to /dev/null





More information about the Users mailing list