On Jan 19, 2010, at 12:42 PM, Gael Cheron wrote: > Hi all, > > In the doc dealing with the service cluster with the check_cluster plugin, > the example uses $SERVICESTATEID:host:Service$ > > But I'd like to use the hardstate. As far as I know, there is no variable > giving the service hardstate. I had a look at the list > http://nagios.sourceforge.net/docs/2_0/macros.html > > Do somebody know if there is a way to do this ?
Having such a macro wouldn't make much sense, IMHO. It seems you might not understand the difference between HARD and SOFT states or I don't understand the problem you're trying to solve? What would it's value be while the service was in a SOFT state, presumably when you'd be interested in using it? OK? WARNING? CRITICAL? $LASTSERVICESTATEID$ might be close to what you're thinking about but I believe that it updates after every check, regardless of HARD/SOFT status. I think you're wanting check_cluster to do something only if the things it's watching are in a HARD state. My suggestion would be to pass $SERVICESTATETYPE:host:Service$ for each cluster element to check_cluster and teach check_cluster to read that and to do what you need based on your business logic. Hope that helps... -- Marc ------------------------------------------------------------------------------ Throughout its 18-year history, RSA Conference consistently attracts the world's best and brightest in the field, creating opportunities for Conference attendees to learn about information security's most important issues through interactions with peers, luminaries and emerging and established companies. http://p.sf.net/sfu/rsaconf-dev2dev _______________________________________________ Nagios-users mailing list [email protected] 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
