Windows 2000 / 2k3 Disk Statistics
Moderators: Developers, Moderators
Windows 2000 / 2k3 Disk Statistics
UPDATED 12.5.05
* Changes - Revision 2 *
- Fixed the Available Space problem. Now shows free space in GB
- Removed the Transfer Time section since I had no stats.
- Added Disk IO (Reads / Writes) to the graph. No visual element to prevent clutter. Just the stats
- Data Query / SNMP-Query / Data Templates & Graph updated. Please delete your current graphs & data sources, update the files, and create new graphs to see the new data.
Summary
I browsed the forums, and a few graphs that used WMI to grab disk statistics from Windows hosts, but none of them seemed to fit the bill entirely. I wanted a graph that would combine the Free Space utilization of the server, with the logical disk performance stats so I could monitor our EMC Clariion SAN performance.
I ran into a few roadblocks. First off, the WMI classes for Win32_PerfFormatted_LogicalDisk were not entirely available on Windows 2000, but fully supported on 2003. I could get the raw statistics, but did not want to do all of the math on the number, but wanted it presented to me. I found the best method was to install the free version of SNMP-Informant which takes the values from Perfmon on the server, and puts them into OID values on a custom SNMP MIB which you can query. This also helps, since it would be supported in Linux versus a straight WMI query for windows.
I then had a second problem. To analyze SAN performance, I wanted the Disk Reads and Disk Writes in Mileseconds (ms). This would let me see how long it took the OS to commit data to the SAN, and from there take a look at bottlenecks like clones, and snapshots through replication manager during certain times of the day. I would cross reference this to see if there was an impact on Windows performance. Utilizing Perfmon on the server in question yields the EXACT values I wanted (Like .009 / sec (9ms). The values in the SNMP MIB for SNMP-Informant shows 0. That sucks. Unless the ms is extremly high (more than 1/2 a second), it will not show. If anyone has experience on how to fix this, please reply. I have included it in the graph for future use if I find a fix.
I put in the obligatory %Disk Read / %Disk Write time. This does not necessarily indicate a performance bottleneck, but just a busy server. More of our high performance databases can be at 100% disk utilization, but still commit data at less than 10ms, which does not indicate a bottleneck. It's still useful for general server utilization.
Installation Steps
Installing the Required Files
1: Install SNMP-Informant Free Edition. It takes up little to no resources on a windows box (http://www.snmp-informant.com).
2: Go to the command prompt, and type in diskperf -y (Not necessary on a Windows 2003 Server)
3: Reboot specified server (required - In my testing, it's required for SNMP-Informant to work on a 2000 server.)
4: Copy the snmp_informant_disk.xml file into <cacti_path>/resources/snmp-queries/
5: Import the XML template for the graph (cacti_graph_template_w32_disk_statistics.xml)
6: Import the XML template for the data query (cacti_data_query_snmp_informant_disk_statistics.xml)
Associating the SNMP-Query
Now that you have the graph, and the script to gather the information, you must add the SNMP-Query to the server you would like to graph. This allows you to query a server, get the Logical Disks, and select which one you would like to graph. To do this
- Click on Devices
-> Click on the server in question
-> Under Associated Data Queries, click on the drop down box Add Data Query. Select SNMP - Informant Disk Statistics, and click the Add button.
-> You should now under Associated Data Queries see the SNMP - Informant Disk Statistics, and it should say something like "Success [6 Items, 6 Rows]". If it says 0 Items, you have a problem. Please post here
You have now associated this query, with this device. If you would like to save some time, you can follow the above steps under Host Templates, and associate this with a type of host (Like Windows 2000/XP) so you do not have to repeat this for each server.
Creating the Graph
Now that you have the query associated with the host / server in question, you can run this query, and select what Logical Disk you would like to graph. To do this, follow these steps.
- Click on Devices
-> Click on the server in question
-> Click on Create Graphs for this Host
-> You should see a section that says Data Query [SNMP - Informant Disk Statistics] Under this should be a list of all Logical Disks on the server
-> Select one, or mutiple logical disks you would like to graph. They should be highlighted Yellow. Scroll down to the bottom, and click on Create
Your graphs should now be created.
Conclusion
If you have any problems / questions. Please post here. I will do my best to answer them. If anybody would like to contribute to this graph, and try to help me get MS response time on Disk Reads / Writes, that would be appreciated.
Thanks!
Many thanks to Fred Dran for providing his XML template that I modified for this graph. Utilizing this template, and many hours researching on Cacti, I have gained a good grasp of SNMP Indexed queries.
* Changes - Revision 2 *
- Fixed the Available Space problem. Now shows free space in GB
- Removed the Transfer Time section since I had no stats.
- Added Disk IO (Reads / Writes) to the graph. No visual element to prevent clutter. Just the stats
- Data Query / SNMP-Query / Data Templates & Graph updated. Please delete your current graphs & data sources, update the files, and create new graphs to see the new data.
Summary
I browsed the forums, and a few graphs that used WMI to grab disk statistics from Windows hosts, but none of them seemed to fit the bill entirely. I wanted a graph that would combine the Free Space utilization of the server, with the logical disk performance stats so I could monitor our EMC Clariion SAN performance.
I ran into a few roadblocks. First off, the WMI classes for Win32_PerfFormatted_LogicalDisk were not entirely available on Windows 2000, but fully supported on 2003. I could get the raw statistics, but did not want to do all of the math on the number, but wanted it presented to me. I found the best method was to install the free version of SNMP-Informant which takes the values from Perfmon on the server, and puts them into OID values on a custom SNMP MIB which you can query. This also helps, since it would be supported in Linux versus a straight WMI query for windows.
I then had a second problem. To analyze SAN performance, I wanted the Disk Reads and Disk Writes in Mileseconds (ms). This would let me see how long it took the OS to commit data to the SAN, and from there take a look at bottlenecks like clones, and snapshots through replication manager during certain times of the day. I would cross reference this to see if there was an impact on Windows performance. Utilizing Perfmon on the server in question yields the EXACT values I wanted (Like .009 / sec (9ms). The values in the SNMP MIB for SNMP-Informant shows 0. That sucks. Unless the ms is extremly high (more than 1/2 a second), it will not show. If anyone has experience on how to fix this, please reply. I have included it in the graph for future use if I find a fix.
I put in the obligatory %Disk Read / %Disk Write time. This does not necessarily indicate a performance bottleneck, but just a busy server. More of our high performance databases can be at 100% disk utilization, but still commit data at less than 10ms, which does not indicate a bottleneck. It's still useful for general server utilization.
Installation Steps
Installing the Required Files
1: Install SNMP-Informant Free Edition. It takes up little to no resources on a windows box (http://www.snmp-informant.com).
2: Go to the command prompt, and type in diskperf -y (Not necessary on a Windows 2003 Server)
3: Reboot specified server (required - In my testing, it's required for SNMP-Informant to work on a 2000 server.)
4: Copy the snmp_informant_disk.xml file into <cacti_path>/resources/snmp-queries/
5: Import the XML template for the graph (cacti_graph_template_w32_disk_statistics.xml)
6: Import the XML template for the data query (cacti_data_query_snmp_informant_disk_statistics.xml)
Associating the SNMP-Query
Now that you have the graph, and the script to gather the information, you must add the SNMP-Query to the server you would like to graph. This allows you to query a server, get the Logical Disks, and select which one you would like to graph. To do this
- Click on Devices
-> Click on the server in question
-> Under Associated Data Queries, click on the drop down box Add Data Query. Select SNMP - Informant Disk Statistics, and click the Add button.
-> You should now under Associated Data Queries see the SNMP - Informant Disk Statistics, and it should say something like "Success [6 Items, 6 Rows]". If it says 0 Items, you have a problem. Please post here
You have now associated this query, with this device. If you would like to save some time, you can follow the above steps under Host Templates, and associate this with a type of host (Like Windows 2000/XP) so you do not have to repeat this for each server.
Creating the Graph
Now that you have the query associated with the host / server in question, you can run this query, and select what Logical Disk you would like to graph. To do this, follow these steps.
- Click on Devices
-> Click on the server in question
-> Click on Create Graphs for this Host
-> You should see a section that says Data Query [SNMP - Informant Disk Statistics] Under this should be a list of all Logical Disks on the server
-> Select one, or mutiple logical disks you would like to graph. They should be highlighted Yellow. Scroll down to the bottom, and click on Create
Your graphs should now be created.
Conclusion
If you have any problems / questions. Please post here. I will do my best to answer them. If anybody would like to contribute to this graph, and try to help me get MS response time on Disk Reads / Writes, that would be appreciated.
Thanks!
Many thanks to Fred Dran for providing his XML template that I modified for this graph. Utilizing this template, and many hours researching on Cacti, I have gained a good grasp of SNMP Indexed queries.
- Attachments
-
- cacti_data_query_snmp_informant_disk_statistics.xml
- Import Into Cacti via Import Templates
- (37.6 KiB) Downloaded 16097 times
-
- graph_image.php2.png (66.92 KiB) Viewed 177212 times
-
- graph_image.php.png (34.13 KiB) Viewed 177212 times
-
- cacti_graph_template_w32_disk_statistics.xml
- Import Into Cacti via Import Templates
- (34.16 KiB) Downloaded 17127 times
-
- snmp_informant_disk.xml
- Save under <CACTI_PATH>/resources/snmp-queries
- (2.21 KiB) Downloaded 20867 times
Last edited by Phobos182 on Tue Dec 06, 2005 3:04 pm, edited 20 times in total.
[size=84][color=red] Electronic Frontier Foundation[/color]
[url]http://eff.org[/url][/size]
[url]http://eff.org[/url][/size]
Missing step
Hey,
I do not manage to execute this template correctly.
First, here is one missing step: Create the DATE QUERY. I did it, but it would like to verify it is correct.
Cacti: 0.8.6g
Tks.
I do not manage to execute this template correctly.
First, here is one missing step: Create the DATE QUERY. I did it, but it would like to verify it is correct.
According to, after creating the graph, DATASOURCES are not generated in POLLER. Some explanation ?- Click on Devices
-> Click on the server in question
-> Under Associated Data Queries, click on the drop down box Add Data Query. Select SNMP - Informant Disk Statistics, and click the Add button.
-> You should now under Associated Data Queries see the SNMP - Informant Disk Statistics, and it should say something like "Success [6 Items, 6 Rows]". If it says 0 Items, you have a problem. Please post here
You have now associated this query, with this device. If you would like to save some time, you can follow the above steps under Host Templates, and associate this with a type of host (Like Windows 2000/XP) so you do not have to repeat this for each server.
Cacti: 0.8.6g
Tks.
Are you creating the graph through the SNMP-Query? Please see the attached screenshot, this is how you should be creating the graph.s16pt wrote:I follow your guide , but when I create graph.I got the empty column as the attachment.
Please give me a hand.Thanks.
Cacti: 0.8.6f(patched)
OS:Fedora Core 1
If you click on Create Graphs, and Choose the graph from the drop down list, it will require you to fill in these values. To not have this show up, you must follow these steps.
Creating the Graph
Now that you have the query associated with the host / server in question, you can run this query, and select what Logical Disk you would like to graph. To do this, follow these steps.
- Click on Devices
-> Click on the server in question
-> Click on Create Graphs for this Host
-> You should see a section that says Data Query [SNMP - Informant Disk Statistics] Under this should be a list of all Logical Disks on the server
-> Select one, or mutiple logical disks you would like to graph. They should be highlighted Yellow. Scroll down to the bottom, and click on Create
Your graphs should now be created.
- Attachments
-
- selection.JPG (61.73 KiB) Viewed 177213 times
Last edited by Phobos182 on Fri Dec 02, 2005 11:58 am, edited 1 time in total.
[size=84][color=red] Electronic Frontier Foundation[/color]
[url]http://eff.org[/url][/size]
[url]http://eff.org[/url][/size]
Re: Missing step
You are specifically looking for the information provided in the screenshot I attached. No data sources are created when you associate an SNMP-Query with a Device. Data Sources are only created when you make a graph from the SNMP-Querycecbr wrote:Hey,
I do not manage to execute this template correctly.
First, here is one missing step: Create the DATE QUERY. I did it, but it would like to verify it is correct.According to, after creating the graph, DATASOURCES are not generated in POLLER. Some explanation ?- Click on Devices
-> Click on the server in question
-> Under Associated Data Queries, click on the drop down box Add Data Query. Select SNMP - Informant Disk Statistics, and click the Add button.
-> You should now under Associated Data Queries see the SNMP - Informant Disk Statistics, and it should say something like "Success [6 Items, 6 Rows]". If it says 0 Items, you have a problem. Please post here
You have now associated this query, with this device. If you would like to save some time, you can follow the above steps under Host Templates, and associate this with a type of host (Like Windows 2000/XP) so you do not have to repeat this for each server.
Cacti: 0.8.6g
Tks.
- Attachments
-
- query.JPG (90.93 KiB) Viewed 177214 times
[size=84][color=red] Electronic Frontier Foundation[/color]
[url]http://eff.org[/url][/size]
[url]http://eff.org[/url][/size]
No SNMP data returned ?
hello .
What happen! I using the Verbose Query for debugging, and returned is "No SNMP data returned" message.
Server os : Windows 2000 sp4
Cacti version : 0.8.6g
What happen! I using the Verbose Query for debugging, and returned is "No SNMP data returned" message.
Server os : Windows 2000 sp4
Cacti version : 0.8.6g
- Attachments
-
- No_SNMP_data_returned.jpg (94.34 KiB) Viewed 176369 times
No data in graph!
thanks !
ok , i will be try on win2k server.
in addition , I use win2003 for try, and SNMP Query was successful. But no data in graph. SNMP Information version is Std-1.4. Server OS is Win2003SP1
ok , i will be try on win2k server.
in addition , I use win2003 for try, and SNMP Query was successful. But no data in graph. SNMP Information version is Std-1.4. Server OS is Win2003SP1
- Attachments
-
- disk_io.jpg (77.93 KiB) Viewed 176008 times
Re: No data in graph!
I have the same result, win2003 and the graphs are fine except the disk performance.86833884 wrote:thanks !
ok , i will be try on win2k server.
in addition , I use win2003 for try, and SNMP Query was successful. But no data in graph. SNMP Information version is Std-1.4. Server OS is Win2003SP1
I am running cacti 8.6g on SuSE 9.0. Polled Server is Win2K, SNMP Informant installed, Diskperf -y ran and rebooted. After i import the templates given here, I get
SNMP - Informant Disk Statistics (Verbose Query) Uptime Goes Backwards Success [0 Items, 0 Rows]
Verbose Query gives the foll:
+ Running data query [10].
+ Found type = '3' [snmp query].
+ Found data query XML file at '/srv/www/htdocs/cacti/resource/snmp_queries/snmp_informant_disk.xml'
+ Error parsing XML file into an array.
+ Found data query XML file at '/srv/www/htdocs/cacti/resource/snmp_queries/snmp_informant_disk.xml'
+ Found data query XML file at '/srv/www/htdocs/cacti/resource/snmp_queries/snmp_informant_disk.xml'
+ Found data query XML file at '/srv/www/htdocs/cacti/resource/snmp_queries/snmp_informant_disk.xml'
I go to Data Queries --> SNMP - Informant Disk Statistics , it says XML file loaded sucessfully. I click on Disk Statistics , i get following error as shown in attachment. Same error for all entries.
Please help !!!
SNMP - Informant Disk Statistics (Verbose Query) Uptime Goes Backwards Success [0 Items, 0 Rows]
Verbose Query gives the foll:
+ Running data query [10].
+ Found type = '3' [snmp query].
+ Found data query XML file at '/srv/www/htdocs/cacti/resource/snmp_queries/snmp_informant_disk.xml'
+ Error parsing XML file into an array.
+ Found data query XML file at '/srv/www/htdocs/cacti/resource/snmp_queries/snmp_informant_disk.xml'
+ Found data query XML file at '/srv/www/htdocs/cacti/resource/snmp_queries/snmp_informant_disk.xml'
+ Found data query XML file at '/srv/www/htdocs/cacti/resource/snmp_queries/snmp_informant_disk.xml'
I go to Data Queries --> SNMP - Informant Disk Statistics , it says XML file loaded sucessfully. I click on Disk Statistics , i get following error as shown in attachment. Same error for all entries.
Please help !!!
- Attachments
-
- Data Template-W32-Disk Statistics Error-1.JPG (62.66 KiB) Viewed 175800 times
Who is online
Users browsing this forum: No registered users and 1 guest