My team had a requirement to be able to reset monitors on a very granular level, the requirements included resetting a single monitoring object on a specific server, similar to reset the C:\ logical disk free space monitor on server X. I’ve not found a powershell or other utility that will meet these requirements so I decided to develop such a utility using the SCOM sdk in VB.net 2010.
Use cases for this utility
1. Reset all monitor objects in an SCOM environment.
2. Reset all C: monitoring objects in the SCOM environment
3. Reset the DB Free Space monitor for all database X objects in the environment
4. Reset all logical disk monitoring objects on server Y
5. Reset an monitoring object on a specific server, like C: monitoring object on server X
6. Reset the Fragmentation level monitor for the C: logical volume on server X
7. Using groups to reset monitors for objects and monitors in the group.
As you can see this utility will fit any and all resetting requirements, this utility as a console application allows the different reset actions to be scheduled in Windows Task Scheduler as well.
Screen shot of the this utility in action
The above screen shot is resetting a monitor called “Cluster Disk – Free Space Monitor (%)” on a disk group called “PBES001 Disk Group….” on a single server.
The color output of the utility is based on the health state of the particular monitoring object that is being reset.
Below is another screenshot
This command resets all “Logical Disk Free Space” monitors for the C:\ logical disk object in the environment
The utility uses the SDK criteria for the monitors and the objects, so this means you can by using the object and monitor fields including “DisplayName”, “Path”, “FullName”, “HealthState” you can select and reset any combination of monitors and objects, you can for example using the “FullName” and specifying the object criteria as “FullName like ‘Microsoft.SQLServer.DBEngine%'” you can also reset all monitors or specific monitors of the class of ‘Microsoft.SQLServer.DBEngine%’
The command line parameters that is passed is
1. the SCOM management server
2. Monitor Criteria ie: “DisplayName=’Logical Disk Free Space'”
3. Object Criteria ie : “DisplayName=’C:’ and Path='<server fqdn>’ and HealthState=’Warning'”
4. Group Name with “” if no group is to be used.
PM me for a copy of the utility.