how to set warning and critical thresholds for CPU VMWare?

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
gornm565
Posts: 72
Joined: Tue Nov 15, 2016 6:11 pm

how to set warning and critical thresholds for CPU VMWare?

Post by gornm565 »

I started monitoring VMware ESX 6.0 host and it's now working successfully. However, I am not sure how to set the threshold for warning and critical alerts in the GUI in Core Config Manager. Let's say I wanted to alert warning at 85% CPU and to alert critical at 90%.
cpu1.JPG
cpu2.JPG
How would I do it?
You do not have the required permissions to view the files attached to this post.
avandemore
Posts: 1597
Joined: Tue Sep 27, 2016 4:57 pm

Re: how to set warning and critical thresholds for CPU VMWar

Post by avandemore »

If you run:

Code: Select all

# /usr/local/nagios/libexec/check_esx3.pl -h
You will see the built-in help for the plugin. You will notice it supports -w and -c arguments with thresholds described at http://nagiosplug.sourceforge.net/devel ... HOLDFORMAT

So you would need to add that in as needed to your plugin or service definition.
Previous Nagios employee
gornm565
Posts: 72
Joined: Tue Nov 15, 2016 6:11 pm

Re: how to set warning and critical thresholds for CPU VMWar

Post by gornm565 »

So to warn above 85% and for critical above 90%, would this be correct?
cpu3.JPG
:?:
You do not have the required permissions to view the files attached to this post.
gornm565
Posts: 72
Joined: Tue Nov 15, 2016 6:11 pm

Re: how to set warning and critical thresholds for CPU VMWar

Post by gornm565 »

Doesn't look like that works. I did -w 4 -c 5, so it should alert if it's above 5%. But it's not alerting:
cpu4.JPG
You do not have the required permissions to view the files attached to this post.
User avatar
tgriep
Madmin
Posts: 9190
Joined: Thu Oct 30, 2014 9:02 am

Re: how to set warning and critical thresholds for CPU VMWar

Post by tgriep »

It could be that is you do not specify a sub command, it ignores the threshold settings.
If you want to generate an alert if the CPU usage if too high, add the following to $ARG3$

Code: Select all

-s usage
To specify usage as the subcommand and the thresholds will be used.

Code: Select all

 * cpu - shows cpu info
            + usage - CPU usage in percentage
                o quickstats - switch for query either PerfCounter values or Runtime info
            + usagemhz - CPU usage in MHz
                o quickstats - switch for query either PerfCounter values or Runtime info
            ^ all cpu info
                o quickstats - switch for query either PerfCounter values or Runtime info
Be sure to check out our Knowledgebase for helpful articles and solutions!
gornm565
Posts: 72
Joined: Tue Nov 15, 2016 6:11 pm

Re: how to set warning and critical thresholds for CPU VMWar

Post by gornm565 »

Yes, that was it. Now it works.
User avatar
tgriep
Madmin
Posts: 9190
Joined: Thu Oct 30, 2014 9:02 am

Re: how to set warning and critical thresholds for CPU VMWar

Post by tgriep »

That is good news. If you don't have any questions, shall I close and lock the post for you?
Be sure to check out our Knowledgebase for helpful articles and solutions!
Locked