Monitoring Weather Conditions – Using SCOM

16-03-2013: This MP has been updated. the download link in this article has been updated. Details of the update can be found here. Background Back in July this year, one day I was playing with PowerShell and discovered using New-WebProxyService to get various information from http://www.webservicex.net. I then had an idea to write a SCOM management pack to monitor weather conditions for cities around the world using the weather data from www.webservicex.net. And after I started writing it, I realised this idea wasn’t new. Pete Zerger has already blogged about it 2 years ago : OpsMgr: Probing a Web Service

Continue reading

MP Authoring: Targeting RMS or MS?

I’m writing a write action module for a management pack that I’m currently working on. This module contains a PowerShell script that connects to SCOM SDK service and interacts with agent computers. I originally wrote the script and planed to target the workflow to the RMS. which I thought it would make sense because SDK service runs on it no matter whether the management group version is 2007 or 2012 (RMS Emulator). My initial PowerShell code in the write action module looked something like this: [sourcecode language=”PowerShell”] [System.Reflection.Assembly]::LoadWithPartialName("Microsoft.EnterpriseManagement.OperationsManager.Common") | Out-Null [System.Reflection.Assembly]::LoadWithPartialName("Microsoft.EnterpriseManagement.OperationsManager") | Out-Null $MGConnSetting = New-Object Microsoft.EnterpriseManagement.ManagementGroupConnectionSettings($Env:COMPUTERNAME) $MG = New-Object

Continue reading

SCCM 2007 Client Management Pack Updated

I received an email this morning regarding to the SCCM 2007 Client Management Pack that I wrote few months ago. Someone pointed out it had some issues in the language packs section of the MP. I had a look and realised the TYANG.System.Center.Configuration.Manager.2007.Monitoring.mp does have some orphaned string resources. A bit background of this MP. I originally wrote this MP for my employer. Before I posted it on my blog, I removed everything that were specfic to my employer (few monitors, application components, relationships, discoveries, etc.). However, I ddin’t delete associated display string resources in here: I have just updated

Continue reading

Hyper-V Cluster Virtual Machines Current Cluster Node SCOM Monitor

First of all, apologies for not updating this blog for over a months. Life has been pretty busy outside of work. My wife gave birth to our first child a months ago and I’ve been flat out looking after our little girl Rosie . Apart from enjoying every moment with the little one while I’m at home, At work, I have been asked to provide a solution to an issue that bothers our infrastructure support team on daily basis. Background Windows 2008 R2 Hyper-V Clusters are heavily utilised in my employer’s infrastructure. There are over 700 2-node Hyper-V clusters operating in the

Continue reading

Using SCOM To Count Logs and Produce Reports

Recently, I’ve been asked twice to produce daily reports involves counting some kind of logs: Scenario 1: The support team need to count number of Application event log entries of events with a specific event ID. A daily report is required to list the number for each computer. Scenario 2: An application produces a log file each day. The support team need to count the number of a specific phrase appeared in previous day’s log file. A daily report is required to list the count number for each computer. The solution I produced for both scenarios are very similar. so

Continue reading

SCOM: Monitoring an Interactive Process and The Recovery Task

Recently I’m working on a management pack for a series of apps for a business unit of my employer. There is a large number of processes that I need to monitor and they run interactively on the console session. Auto Admin Logon is enabled on these servers, when the server starts up, it automatically logged on using the account configured and the the interactive processes are automatically started. Setting up monitors for these processes is easy. However, I went a step further and created a generic write action module to be used as recovery task that restarts the process interactively

Continue reading

SCOM: Process Performance Collection Rule for Services

Setting up Performance Collection rules for a particular process is pretty straightforward in SCOM. However, the it has it’s limitations. Process performance collections rules are straightforward to setup, as long as there is ONLY ONE instance of the particular process running on the computers that your rule is targeting. Also, each rule can only collect ONE performance counter. The problem with that is, if I need to collect performance counters for a particular service, i.e. Server Service (lanmanserver) or a particular SQL server instance (when there are multiple SQL instances running on the same server) , I will not be

Continue reading

SCOM: Powershell Property Bag Trigger Only Probe VS Windows Script Property Bag Probe

When writing a Probe Action Module to run a trigger only PowerShell script and return property bags, Microsoft.Windows.PowerShellPropertyBagTriggerOnlyProbe module can be used. However, there is no trigger only probe module if you want to run VBScript. Below are 2 examples how to create trigger only probe modules for both PowerShell and VBScript: 1. PowerShell Member Modules: Microsoft.Windows.PowerShellPropertyBagTriggerOnlyProbe Data Types: Input: Trigger Only Output: System.PropertyBag Data 2. VBScript: Member Modules: System.PassThroughProbe Microsoft.Windows.ScriptPropertyBagProbe Data Type: Input: Trigger Only Output: System.PropertyBag Data

Continue reading

SCOM MP Authoring Example: Generate alerts based on entries from SQL Database (Part 2 of 2)

This is the 2nd part of the 2-part series.  Part 1 can be found here. In Part 2, I’ll cover the steps involved to create each module type and the rule in this article. all these objects will be created in SCOM 2007 R2 Authoring Console. You can create a new management pack for this or use an existing one. Firstly, we will need create the probe action and data source modules: Probe Action Module: 1. Under Type Library pane, go to “Probe Actions” under Module Types and click New—>”Composite Probe Action…” 2. Give it a unique identifier such as

Continue reading

SCOM MP Authoring Example: Generate alerts based on entries from SQL Database (Part 1 of 2)

This is probably going to be a bit too long for one single blog post. I’ll separate this topic into 2 articles: Part 1 includes the background and overview of the rule and it’s workflow Part 2 documents all the steps to create all the module types and the rule itself. This article is the first part of the 2-part series. Recently, I’ve been writing a SCOM management pack for a new application that my employer is implementing. This application logs any application related alarms into a SQL express database. One of the requirement for the MP is to catch

Continue reading
%d bloggers like this: