Cacti & NetSaint/Nagios NSClient Scripts to monitor Wind
Moderators: Developers, Moderators
I'm trying to, but not succeeding. I'm trying to use the package Caliban put together with the perl scripts and templates, but I can't get the CPU load one to work. From a command line I can successfully query a server for CPU load average just fine with the proper check_nt statement, but something isn't translating properly in Cacti as I get nothing but a flatlined graph for the CPU graph. The memory one that was provided works fine.
I'm going to guess something is up in the templates somewhere, but I don't know enough working with Cacti to figure this out.
I'm going to guess something is up in the templates somewhere, but I don't know enough working with Cacti to figure this out.
-
- Posts: 18
- Joined: Fri Jun 03, 2005 6:42 am
I tryed to monitor the memory of one w2k box but I am getting this error in the graph managment:
RRDTool Says:
ERROR: can't parse '#FF4105:'
FF4105 is the color selected on the graph template to display the area, whenever I change the color the error changes too.
I can execute the perl script and get the correct values
RRDTool Says:
ERROR: can't parse '#FF4105:'
FF4105 is the color selected on the graph template to display the area, whenever I change the color the error changes too.
I can execute the perl script and get the correct values
- Diggit2001
- Cacti User
- Posts: 195
- Joined: Tue May 03, 2005 4:29 pm
- Location: MD, US
It's making me crazy!!!
Hey everybody. I have no idea what the heck I'm doing wrong here and would appreciate any help that anyone can throw my way. I have installed the nsclient on one of my servers and using the scripts and other info from this thread, I have had success with getting hard drive, memory and Exchange Information Store stats to graph in cacti. I am having problems getting the CPU load script to work, however. I can run it from a terminal session no problem and it returns data. In cacti, it jut says "nan" and I get no results whatsoever. I've seen that another user has had pretty much this same problem, but I have not seen a solution.
I am running Cacti on Linux and I am a Linux noob, so it is completely possible that I am doing something wrong. I just don't understand why everything else is working and this one particular item is not.
Please help before I go mad!!!
Thanks!
I am running Cacti on Linux and I am a Linux noob, so it is completely possible that I am doing something wrong. I just don't understand why everything else is working and this one particular item is not.
Please help before I go mad!!!
Thanks!
-
- Posts: 6
- Joined: Wed Jul 20, 2005 4:01 am
-
- Posts: 6
- Joined: Wed Jul 20, 2005 4:01 am
Instructions
Can someone post newer instructions on using these perl scripts with NSclient. I understand the scripts, can use them just need help with adding all necessary parts for cacti. LIke step one create input methods and so on with a new version of cacti. Like at least version .8.6d /// The previous examples are good and helpful but loose me somewhat since this post is a year old.
Thanks to anyone who helps!
Thanks to anyone who helps!
Re: Instructions
Are you still having trouble with this? If you are, I can attempt to write a walk through.spoonman wrote:Can someone post newer instructions on using these perl scripts with NSclient. I understand the scripts, can use them just need help with adding all necessary parts for cacti. LIke step one create input methods and so on with a new version of cacti. Like at least version .8.6d /// The previous examples are good and helpful but loose me somewhat since this post is a year old.
Thanks to anyone who helps!
-zb
Make your own scripts for WMI counters
Make your own scripts for other WMI counters
I don't know if anyone else took awhile to figure this out, so I will give a quick step by step using a new Terminal Server Monitoring graph as an example.
1) Figure out what you want to monitor in Windows (we want to monitor Terminal Services for this example)
2) Open up the Peformance snap in (in Windows) and browse the list of counters. Add the ones you want to get a feel for how it will look on your graph. In this case we add Terminal Services -> Active Sessions and Inactive Sessions.
3) Once you have chosen your counters, right click on one and select properties. You should see something like:
4) You probably have alread guessed it, but thats the path we are going to use with the check_nt tool. So now we will drop those values into the script we lifted from some helpful folks a page or two ago (note that we use \\ instead of a single \, also make sure to replace PASSWORD and PORTNUMBER with your specifics):
5) Now we run through the tutorial earlier on in this thread. The key differences will be in the Data Input Methods configuration. We will use the values "active" and "inactive" as our output fields.
Sooo... You can use the above method to generate a script for ANY of those counters you can browse to in windows. Hope that helps someone. Took me a while to figure out where to find those \\paths\.
-zbose
I don't know if anyone else took awhile to figure this out, so I will give a quick step by step using a new Terminal Server Monitoring graph as an example.
1) Figure out what you want to monitor in Windows (we want to monitor Terminal Services for this example)
2) Open up the Peformance snap in (in Windows) and browse the list of counters. Add the ones you want to get a feel for how it will look on your graph. In this case we add Terminal Services -> Active Sessions and Inactive Sessions.
3) Once you have chosen your counters, right click on one and select properties. You should see something like:
Code: Select all
\\servername\Terminal Services\Active Sessions
\\servername\Terminal Services\Inactive Sessions
Code: Select all
#!/usr/bin/perl
$active_sessions= `/usr/lib/nagios/plugins/check_nt -H $ARGV[0] -p PORTNUMBER -s PASSWORD -v COUNTER -l "\\Terminal Services\\Active Sessions"`;
chomp $active_sessions;
$inactive_sessions= `/usr/lib/nagios/plugins/check_nt -H $ARGV[0] -p PORTNUMBER -s PASSWORD -v COUNTER -l "\\Terminal Services\\Inactive Sessions"`;
chomp $inactive_sessions;
print "active:$active_sessions inactive:$inactive_sessions\n";
Sooo... You can use the above method to generate a script for ANY of those counters you can browse to in windows. Hope that helps someone. Took me a while to figure out where to find those \\paths\.
-zbose
I also have a question for others doing this type of monitoring:
Up until now, I have only been using check_nt to check hosts that I have SNMP on (win2k3 servers). Cacti can grab the network IF through SNMP (or anything else that SNMP offers) and I am using check_nt scripts to get WMI counter data.
My question: Can I get cacti to run the check_nt scripts for hosts that do not have SNMP enabled (ie win2k servers?). Cacti seems to think the host is down if it can't run any SNMP queries against it, and it won't run the rest of the scripts (at least that is how it seems to be behaving for me).
Thanks,
zb
Up until now, I have only been using check_nt to check hosts that I have SNMP on (win2k3 servers). Cacti can grab the network IF through SNMP (or anything else that SNMP offers) and I am using check_nt scripts to get WMI counter data.
My question: Can I get cacti to run the check_nt scripts for hosts that do not have SNMP enabled (ie win2k servers?). Cacti seems to think the host is down if it can't run any SNMP queries against it, and it won't run the rest of the scripts (at least that is how it seems to be behaving for me).
Thanks,
zb
I had that same issue where my settings were set to poll via snmp only and if snmp messed up the device was considered down// All graphs stop... I changed my setting to PING and SNMP so that if snmp service hangs or stops for some reason the graphs that are run via check_nt should not stop // I only use snmp to grab NIC stats// I also set my ping option to ICMP, and yes i do use root to run cacti so that's not an issue/
Excellent idea. I just changed the setting and will see if it works.spoonman wrote:I had that same issue where my settings were set to poll via snmp only and if snmp messed up the device was considered down// All graphs stop... I changed my setting to PING and SNMP so that if snmp service hangs or stops for some reason the graphs that are run via check_nt should not stop // I only use snmp to grab NIC stats// I also set my ping option to ICMP, and yes i do use root to run cacti so that's not an issue/
Is there an advantage to using the ICMP ping instead of the UDP one?
BTW, Spoonman, are you in Seattle? Referencing the real spoonman? hehe.
Who is online
Users browsing this forum: No registered users and 0 guests