Retrieve instances of a monitor in a critical state (in SCOM 2007)

by PowerShell MVP Marc van Orsouw, this PowerShell script (intermingled with bits of C#) will efficiently retrieve a list / count of monitors in a critical state in Operations Manager 2007. NOTE: This script requires PowerShell v2.0 To download, sign in and click the Download button at right.

Script:Folder Size with Performance Data for OpsMgr 2007

This is an unpdated version of the folder size monitoring script similar to the file size monitoring script offered in Part 2 of the ‘System Center Central Scripting Series. This file monitors for folder existence and folder size and logs folder Intended for use in a 2-state monitor, as explained in How to create a Script-based 2-State […]

Script to match string value (line) in text file

Checks to verify the text string specified is present in a text file. Script requires string match on full line in the file. Was originally wittento read an .ini file, but works with any plain text file.Designed to be used in OpsMgr 2007 or Essentials 2007/2010 in a two-state monitor. For steps to implement a […]

#2 Automate your group creation with Powershell

One of our very good customers are managing servers with an dedicated internal administrator as a primary contact for each server. They are managing this one to one relation with an Excel sheet. A while ago we talked about automating this group creation with powershell, so the last time Jacob and I was discussing Powershell in […]

Windows Service Recovery Monitor (for OpsMgr and Essentials)

Checks to see if a Windows service is configured to ‘automatically restart’ in case of service failure (service properties, Recovery tab). Use in a two-state monitor targeting a Windows operating system class. Script accepts one parameter – the name (not display name) of the Windows service. Works with OpsMgr 2007 or Essentials 2007 / 2010. For […]

Using a script to automatically reset monitor state when alert is closed

A powershell script that can help you reduce “monitoring noise” created by the “manual reset” monitors. The script is intended to be used as an alert notification command. The notification channel should be configured to pass alert ID as an argument to the script and corresponding notification subscription must include _closed_ alerts of warning and error severity. Once the script […]

A powershell script for resetting state of “manual reset” monitors

The script iterates through the state hierarchy of each monitoring object in the management group and resets all “manual reset” monitors that have been in “Error” or “Warning” state longer than the specified max period for time in state. The script is intended to run as a scheduled task. There are two variables that need […]