solarwinds  |  thwack
in
Search 44,782 posts and 623 resources contributed by 21,553 members or post a topic.

Already Joined? Sign in
Greater than rule is not triggering correctly for VMFS disk space custom poller

rated by 0 users
Not Answered This post has 0 verified answers | 5 Replies | 2 Followers


53 Posts
Points 141
rmarshall posted on 09-13-2007 1:07 PM
rated by 0 users

I may put in a ticket for this, but I thought I would hit the forum first.  I have an issue with an advanced alert where my rule says alert if it goes over 80, but I get the alert when the value hits 9. 

The value provided is from a custom poller that returns the percentage of VMFS disk space on the ESX host.  It currently returns the percentage as a whole number, so 80% would return as 80.  I had it returning the value 80% before and had the same issue, so I switched it to a whole number to see if that fixed the problem.  I would like to be able to have it return "80%" if I can

 The trigger rule says:

Platform is equal to ESX
Poller Name is equal to VMFS_Storage1_Space
Status is greater than 80

 The web view of the host shows the custom poller returning the value of 9, and in the alert message and insert the ${CustomPollerStatus.Status} and it says 9, but it is alerting at 9 instead of at 81 or above.

I have also tried using "Total is greater than 80" and I have tried a complex condition that says "field Status is greater than 80" and I get the same results for each.

 Is this a bug?  What do I need to do to get this rule to evaluate both digits of the value "80" instead of just evaluating to the first digit "8" and alerting when it reaches "9"?

Thank you, Richard M.
  • | Post Points: 3

All Replies


2,686 Posts
Points 7,704
Moderator
SolarWinds Employee
denny.lecompte replied on 09-13-2007 3:53 PM
rated by 0 users

Is it possible that your value is text, not numeric? 

Denny LeCompte
Sr. Product Manager, Orion
SolarWinds
Austin, TX

  • | Post Points: 5

53 Posts
Points 141
rmarshall replied on 09-13-2007 5:28 PM
rated by 0 users

I am returning a number.  Is there something specific I need to do to tell Solarwinds to take this number and treat it like a number?

This is the script being run to return the value:

 ----------------------------------------------------------------------

#!/usr/bin/perl -w

 

use strict;

my $partition = ".";

my $partmaps = ".";

my $vmfsvolume = $ARGV[0];

my $cap = 0;

my $avail = 0;

my $output = "";

open("Y", "/usr/sbin/vmkfstools -P /vmfs/volumes/$vmfsvolume|");

while (<Y>) {

if (/Capacity ([0-9]*) .*, ([0-9]*) .*avail/) {

$cap = $1;

$avail = $2;

$output = int(((1-($avail/$cap))*100)+.5);

print ("$output\n");

}

}

-----------------------------------------------------------------

I execute it with a value of storage1 and it returns a number that is the percentage or free space on storage1.

I tried removing the \n and the quotes.  That did not work.  It still alerted on 9.

 

Thank you, Richard M.
  • | Post Points: 1

53 Posts
Points 141
rmarshall replied on 09-13-2007 5:33 PM
rated by 0 users

Another interesting note, I changed my script to send a decimal value (0.09) and set the alert to trigger at .8 and it still alerts.  The value from the host is 0.09, but Solarwinds thinks that is greater than .8.

Thank you, Richard M.
  • | Post Points: 3

67 Posts
Points 164
SolarWinds Employee
SteveSW replied on 09-13-2007 5:45 PM
rated by 0 users

Status will treat the value as text and that is why '9' is greater than '80'. If you have Orion 8.5 you can use Numeric Status for your alert and that will fix that up. If you are in 8.1 you can change the custom poller to be a rate poller instead of a status poller. This will do a numeric comparison.

 

  • | Post Points: 3

53 Posts
Points 141
rmarshall replied on 09-13-2007 8:54 PM
rated by 0 users

Changing the poller to be a rate poller and changing the alert to alert on a rate greater than 80 has worked.  This is an acceptable solution.  Thank you for your support. 

 I'm am glad I was able to share this dialogue in the forum for the benefit of others.

 

I will upgrade to 8.5 after it has been out for a few weeks.

Just out of curiosity, why don't you just host your own forum?  We just bought the exact same forum module for Sugient and we have branded it as ours.  Having to go to a forum called Thwack to get Solarwinds support seams a bit odd.

 

Thank you, Richard M.
  • | Post Points: 1
Page 1 of 1 (6 items) | RSS