Page 3 of 4
Re: How do I monitor Cisco CPU utilisation ?
Posted: Mon Aug 10, 2015 2:08 pm
by ssax
This is how you would go about it:
Code: Select all
cd /usr/local/nagios/libexec
wget "https://exchange.nagios.org/components/com_mtree/attachment.php?link_id=2609&cf_id=24" -O check_cisco_ips.pl
chmod +x check_cisco_ips.pl
Re: How do I monitor Cisco CPU utilisation ?
Posted: Mon Aug 10, 2015 2:26 pm
by vijilants
Thanks SSAX.
Another question on the first plugin......
If I wish to monitor "hardware-health" what would be the command line for CCM Commands.
This is what I entered for CPU but I am confused as to what the ARGS 3 and 4 should read for hardware-health and on the service management what would I enter in the ARG 3 and ARG 4 Boxes ?
Code: Select all
$USER1$/check_nwc_health --hostname $HOSTADDRESS$ --mode $ARG1$ --community '$ARG2$' --warning $ARG3$ --critical $ARG4$ $ARG5$
Re: How do I monitor Cisco CPU utilisation ?
Posted: Mon Aug 10, 2015 2:43 pm
by snapon_admin
It's actually a perl script, so just save it as a .pl file. I believe I copied all of the text into notepad++ and then saved as check_cisco_ips.pl when I did it. Then you can just add it to Nagios by going to Admin > Manage components > upload component.
Re: How do I monitor Cisco CPU utilisation ?
Posted: Tue Aug 11, 2015 2:40 am
by vijilants
snapon_admin wrote:It's actually a perl script, so just save it as a .pl file. I believe I copied all of the text into notepad++ and then saved as check_cisco_ips.pl when I did it. Then you can just add it to Nagios by going to Admin > Manage components > upload component.
Thanks Snapon!!
Can you please supply me your command line and what you entered for the ARGS for the service ?
Re: How do I monitor Cisco CPU utilisation ?
Posted: Tue Aug 11, 2015 7:01 am
by jdalrymple
What you had below should be just fine:
vijilants wrote:Code: Select all
$USER1$/check_nwc_health --hostname $HOSTADDRESS$ --mode $ARG1$ --community '$ARG2$' --warning $ARG3$ --critical $ARG4$ $ARG5$
$ARG3$ and $ARG4$ are thresholds, both appear to be measured in percentage. So create the command as written above, the do something like
$ARG1$: cpu-load
$ARG2$: test-123
$ARG3$: 80
$ARG4$: 90
Adjust to fit your needs.
Re: How do I monitor Cisco CPU utilisation ?
Posted: Tue Aug 11, 2015 9:41 am
by vijilants
Thanks,
If I wish to monitor "hardware-health" what would be the command line for CCM Commands ?
Re: How do I monitor Cisco CPU utilisation ?
Posted: Tue Aug 11, 2015 10:46 am
by snapon_admin
This is ours:
Code: Select all
$USER1$/check_nwc_health --t 60 --hostname $HOSTADDRESS$ --community $ARG1$ --mode hardware-health
The only threshold I can think of would be for temperature which I'm not eve nsure if you can specify that. By default it looks like the alert threshold is set for 60, which is a good alert threshold if that's Celsius. Everything else it monitors doesn't really require a threshold because it's stuff like PSUs being on or off, fans spinning or not, etc.
Re: How do I monitor Cisco CPU utilisation ?
Posted: Tue Aug 11, 2015 11:01 am
by vijilants
snapon_admin wrote:This is ours:
Code: Select all
$USER1$/check_nwc_health --t 60 --hostname $HOSTADDRESS$ --community $ARG1$ --mode hardware-health
The only threshold I can think of would be for temperature which I'm not eve nsure if you can specify that. By default it looks like the alert threshold is set for 60, which is a good alert threshold if that's Celsius. Everything else it monitors doesn't really require a threshold because it's stuff like PSUs being on or off, fans spinning or not, etc.
OK, so without any threshold info, say if a fan or psu failed, how would this be shown in nagios ?.....Would it bring up some sort of a red alarm indication ?
Re: How do I monitor Cisco CPU utilisation ?
Posted: Tue Aug 11, 2015 11:42 am
by snapon_admin
Yep, shows as a critical alert and will output something like "PSU 1 is bad" or "Fan 2 is bad" or something along those lines. I don't remember the exact syntax, but that's the gist. We got an alert that one of our fans failed on a core switch at one of our locations a few months ago using this plugin.
Re: How do I monitor Cisco CPU utilisation ?
Posted: Tue Aug 11, 2015 11:57 am
by vijilants
snapon_admin wrote:Yep, shows as a critical alert and will output something like "PSU 1 is bad" or "Fan 2 is bad" or something along those lines. I don't remember the exact syntax, but that's the gist. We got an alert that one of our fans failed on a core switch at one of our locations a few months ago using this plugin.
Great....that's exactly what I need.....Thank you.
Is there any way to permanently fix the situation where I have to run this command when I use the Test Command button under services ?