This will start a series of posts related to finally extracting that disk report you've always wanted from SCOM but just couldn't find anywhere, at least not for free. We're going to start with the basics of getting the logical disk size into the datawarehouse so that you can query it later for a SQL report view, or you can use it in the generic report library->performance report or even a workspace performance view. The cool thing with doing it this way is that you can then trend on disk size over time. In a virtual environment, where it is relatively easy to grow a disk, you will be able to go back in time and see when that growth occurred and by how much. That can be a handy report sometimes.
- Start by opening your Microsoft System Center Management Console and navigating to the "Authoring Screen"
- In the "Authoring Screen", right-click on "Rules" and select the "Create a new rule" option
- In the "Create Rule Wizard", expand the "Collection Rules" folder, then the "Performance Based" folder and select "WMI Performance"
- When the rule screen comes up, you'll need to provide a name for the rule and select the target for the rule. Leave the "Rule Category" alone.
- In the "Rule Target" selection screen, change the scope to "View all Targets" and look for "Logical Disk (Server)". Select that and hit "OK" to finish the selection.
- Before proceding, your screen should look something like this.
- In the next screen, you'll have to insert your WMI query. For the purposes of this monitor, we really only care about two values, the DeviceID (drive letter) and the Size. That keeps the data returned relatively small to have minimal impact on performance. If you left it as SELECT * and then run the rule, it will bog down SCOM significantly, trust me on that one. Enter how often you want to collect the information. Since total disk size does not change often, you can have a large value here, 14400 would be once every four hours if I have my math right.
- On the following screen, you'll need to select the values to collect and how the labels should show up when looking for them in the performance monitors. You want the "Object" to be LogicalDisk, this way you can search the datawarehouse for logicaldisk counters and it will show up in the same grouping. This will also allow the value to show up in the same group as your other Logical Disk performance counters elsewhere in the system. You want to give the "Counter" value a name, such as "Total Disk Space" or "Total Disk Size" something to identify this counter as representing the size of the partition in question.
- For the "Instance" Value, let's use the picker, select the "..." on the side and then "Target"
- In the target picker screen, let's pick the "Device Identifier"
- Now let's repeat the process for the "Value" field
- Select the "..." on the side and then "Target"
- In the target picker screen, let's pick the "Size (MBytes) (Numeric)"
- Your Rule Wizard should now look something like this and you are ready to finish the rule. It will initially gather data pretty quickly so you shouldn't have to wait too long before you can go searching for it. This will pick up the space for all logical instances on the Windows servers in your environment.
For the WMI Namespace, enter: root\cimv2
For the Query, enter: SELECT DeviceID,Size FROM Win32_LogicalDisk
In Part 2 of this series, I will outline a SQL query to dump the information in a basic table and a tabular report format, along with other ways to access this information in SCOM. In Part-3, I hope to put together a fancy, graphical report of all the data (we'll see on that one).