check_win_perfmon plugin configuraiton
check_win_perfmon plugin configuraiton
Team,
Need help with disk io for windows servers. I got the check_win_perfmon plugin from the exchange and did the test on the local server by executing the command and it works fine.
I need help in configuring this on nagios server to monitor the performance on target client . We have Nsclient++ installed on the target windows server so please provide me the steps.
I would need steps in defining this service in nagios. most of the documentation i got in the web were point to NCPA plugin but we are using Nsclient++ in our enviroment.
Thanks.
Need help with disk io for windows servers. I got the check_win_perfmon plugin from the exchange and did the test on the local server by executing the command and it works fine.
I need help in configuring this on nagios server to monitor the performance on target client . We have Nsclient++ installed on the target windows server so please provide me the steps.
I would need steps in defining this service in nagios. most of the documentation i got in the web were point to NCPA plugin but we are using Nsclient++ in our enviroment.
Thanks.
-
kyang
Re: check_win_perfmon plugin configuraiton
Hello,
I have never tried using this plugin, and the creator doesn't say how it works with NSClient++. This isn't a plugin created or maintained by us.
https://github.com/juangranados/check_win_perfmon
If you're looking to monitor Disk IO, does NSClient not work for you? You should be able to grab a list of counters using something like this from your Windows machine. nscp sys -- --list Disk --all
Then set them correctly while using check_nt
I have never tried using this plugin, and the creator doesn't say how it works with NSClient++. This isn't a plugin created or maintained by us.
https://github.com/juangranados/check_win_perfmon
If you're looking to monitor Disk IO, does NSClient not work for you? You should be able to grab a list of counters using something like this from your Windows machine. nscp sys -- --list Disk --all
Then set them correctly while using check_nt
Re: check_win_perfmon plugin configuraiton
@kyang : Could you give me more information or steps on how to add the performance counter using check_nt.
Also suggest the default plugin available from nagios to monitor the windows disk io along with complete documentation.
Regards..
Also suggest the default plugin available from nagios to monitor the windows disk io along with complete documentation.
Regards..
-
kyang
Re: check_win_perfmon plugin configuraiton
Try running this command from the XI terminal and let me know the output. (If you changed your hard drive letters, then change it in the command below as well)
Also, make sure to put in your windowsIP address and replace password with your password from the nsclient.ini file.
Also, make sure to put in your windowsIP address and replace password with your password from the nsclient.ini file.
Code: Select all
/usr/local/nagios/libexec/check_nt -H windowsIP -p 12489 -s 'password' -v COUNTER -l "\\PhysicalDisk(0 C:)\\Avg. Disk Bytes//Write","Disk Write Time","MB" -w 1000 -c 500Re: check_win_perfmon plugin configuraiton
This is the output I am receiving. Please let me know how do I incorporate this as service checks.. Was not very clear on how to add this using the configuration manager.
Disk Write Time = 0.00 MB | 'Disk Write Time'=0.000000MB;1000.000000;500.000000;
Disk Write Time = 0.00 MB | 'Disk Write Time'=0.000000MB;1000.000000;500.000000;
Re: check_win_perfmon plugin configuraiton
@kyang : I went ahead and tried the below steps in adding these performance counter by using the windows servers wizard and getting the error as shown in the attachment... The service check uses check_xi_service_nsclient and not check_nt.
Below is the command used in the nagios XI after adding the counter.
check_xi_service_nsclient!!COUNTER!-l "\\PhysicalDisk(0 C:)\\Avg. Disk Bytes//Write","MB" -w 1000 -c 500
Below is the command used in the nagios XI after adding the counter.
check_xi_service_nsclient!!COUNTER!-l "\\PhysicalDisk(0 C:)\\Avg. Disk Bytes//Write","MB" -w 1000 -c 500
You do not have the required permissions to view the files attached to this post.
-
kyang
Re: check_win_perfmon plugin configuraiton
I actually just wanted to see the output first.
Could you send me your list of counters?
On your Windows Machine that has nsclient++ installed follow these steps: (fill in your username)
1. Open the cmd.exe
2. Please post or PM me the nscp.txt file that is located on your desktop.
Adding counters in the wizard, can be shown in here with examples.
https://support.nagios.com/kb/article.php?id=127
https://support.nagios.com/kb/article.php?id=785
https://support.nagios.com/kb/article.php?id=779
Also, check_xi_service_nsclient is the template in which it uses check_nt
Could you send me your list of counters?
On your Windows Machine that has nsclient++ installed follow these steps: (fill in your username)
1. Open the cmd.exe
Code: Select all
cd C:\Program Files\NSClient++
nscp sys -- --list Disk --all > "C:\Users\username\Desktop\nscp.txt"Adding counters in the wizard, can be shown in here with examples.
https://support.nagios.com/kb/article.php?id=127
https://support.nagios.com/kb/article.php?id=785
https://support.nagios.com/kb/article.php?id=779
Also, check_xi_service_nsclient is the template in which it uses check_nt
Re: check_win_perfmon plugin configuraiton
I would like to add to what kyang said. The output you showed us:
Here's an example of a check that worked for me:
If you don't want to use check_nrpe, you could try modifying your original (check_nt) command. Play with single/double quotes, and the use of backslash ("\") for escaping. You counter is:
so, if you use double quotes, I believe that it needs to be escaped as such:
Or you can try using single quotes as such:
Example:
For more information on monitoring performance counter in Nagios using NSClient++, please read our KB article on the topic here:
https://support.nagios.com/kb/article/n ... t-127.html
indicates that the check is not working as expected (0.00 MB)... This may be because of some escaping issues or issues with check_nt and performance counters. In my experience, some performance counters are better checked via check_nrpe (instead of check_nt). There has been a push towards deprecating check_nt in general. Our wizard uses check_nt, so you won't be able to set up a check_nrpe service automatically (via the Windows Server wizard), however you could set up one manually.Disk Write Time = 0.00 MB | 'Disk Write Time'=0.000000MB;1000.000000;500.000000;
Here's an example of a check that worked for me:
Code: Select all
/usr/local/nagios/libexec/check_nrpe -H x.x.x.x -c CheckCounter -a 'Counter:Disk Write Time=\PhysicalDisk(0 C:)\Avg. Disk Bytes/Write' ShowAll MinWarn=1000 MinCrit=500
Disk Write Time = 4915|'Disk Write Time'=4915;1000;500Code: Select all
\PhysicalDisk(0 C:)\Avg. Disk Bytes/WriteCode: Select all
\\PhysicalDisk(0 C:)\\Avg. Disk Bytes\/WriteCode: Select all
/usr/local/nagios/libexec/check_nt -H windowsIP -p 12489 -s 'password' -v COUNTER -l '\PhysicalDisk(0 C:)\Avg. Disk Bytes/Write','Disk Write Time','MB' -w 1000 -c 500Code: Select all
/usr/local/nagios/libexec/check_nt -H x.x.x.x -p 12489 -s 'password' -v COUNTER -l '\PhysicalDisk(0 C:)\Avg. Disk Bytes/Write', 'Disk Write Time','MB' -w 1000 -c 500
5546https://support.nagios.com/kb/article/n ... t-127.html
Be sure to check out our Knowledgebase for helpful articles and solutions!
Re: check_win_perfmon plugin configuraiton
Hello,
I was able to execute the below command and with the following output.
/usr/local/nagios/libexec/check_nt -H xx.xx.xx.xx -p 12489 -s '' -v COUNTER -l '\PhysicalDisk(0 C:)\Avg. Disk Bytes/Write','Disk Write Time','MB' -w 1000 -c 50
Disk Write Time = 12288.00 MB | 'Disk Write Time'=12288.000000MB;1000.000000;50.000000;
I am ok in using the nrpe but i couldn't execute the provided command was getting connection refused.
connect to address 1xx.xx.xx.x port 5666: Connection refused
Also, I couldn't execute the below command on the server as it couldn't recognize nscp
cd C:\Program Files\NSClient++
nscp sys -- --list Disk --all > "C:\Users\username\Desktop\nscp.txt"
I was able to execute the below command and with the following output.
/usr/local/nagios/libexec/check_nt -H xx.xx.xx.xx -p 12489 -s '' -v COUNTER -l '\PhysicalDisk(0 C:)\Avg. Disk Bytes/Write','Disk Write Time','MB' -w 1000 -c 50
Disk Write Time = 12288.00 MB | 'Disk Write Time'=12288.000000MB;1000.000000;50.000000;
I am ok in using the nrpe but i couldn't execute the provided command was getting connection refused.
connect to address 1xx.xx.xx.x port 5666: Connection refused
Also, I couldn't execute the below command on the server as it couldn't recognize nscp
cd C:\Program Files\NSClient++
nscp sys -- --list Disk --all > "C:\Users\username\Desktop\nscp.txt"
-
kyang
Re: check_win_perfmon plugin configuraiton
Hello,
Given the options of checks, are you looking to use check_nt or check_nrpe?
lmiltchev, has provided great examples, but I'm not sure if you wanted to use both or only one?
https://support.nagios.com/kb/article/n ... t-622.html
Given the options of checks, are you looking to use check_nt or check_nrpe?
lmiltchev, has provided great examples, but I'm not sure if you wanted to use both or only one?
This is leading into another issue in which its either your firewall or what you have for allowed hosts.connect to address 1xx.xx.xx.x port 5666: Connection refused
https://support.nagios.com/kb/article/n ... t-622.html