Awesome hidden super powerful updatable SCOM class property that has unlimited possibilities like Tags in Azure

Imagine if you had an empty property in SCOM that was in every class that you could set and update.  The possibilities for this property are endless.  First dynamic grouping comes to mind, but there are many more such as notifications, reports etc..

Thanks to PFE Hugh Scott for sharing this cool “feature”.

How to set or access this property?

You can set this property using SCOM PowerShell or the SCOM SDK.

Here is how you do it.

First let’s get all windows computers using powershell. (Note this can be any class not just a windows computer class)

Now lets grab one of my windows computers and set it to a variable named $myComputer

Now lets look at the properties of that computer.

As you can see their is a property called [System.ConfigItem].Notes that is not used.  This is the property we will be using.

To set this property you need to set the value of it.   [System.ConfigItem].Notes needs to be in single quotes.

You also need to commit the changes using Overwrite()

Now when I query the object again I can see the Notes property has been set to Production.  (This is a free rich text field so you could list multiple values like Environment:Production,Team:SQL   Then use regex queries when you are creating groups)

 

Now how do I use this property when creating groups?

If I create a dynamic group in SCOM called Production Servers

I add Windows Computer, and then add the Notes Property and set it Equals to Production

Now I select the group and click View Group Members

I can see my group contains all Windows Computers with “Production” in the notes field.

 

The only downside to this property is that it is not viewable in the console state views.  But you can query it with PowerShell, SQL,  create a Dashboard view in the Web console https://docs.microsoft.com/en-us/system-center/scom/manage-create-web-dashboard-posh?view=sc-om-1807 to view it, or a PowerShell Grid widget https://blogs.technet.microsoft.com/stefan_stranger/2014/04/28/new-powershell-grid-widget-walkthrough/

 

Another similar example that inspired much of this work using asset status can be found here.  https://randomnote1.github.io/scom/using-the-asset-status-property-in-scom/  This property uses enum type so it is a little less powerful.

One Response to Awesome hidden super powerful updatable SCOM class property that has unlimited possibilities like Tags in Azure

  1. Markus Klein July 29, 2019 at 9:30 am #

    Guess we have SCOM’s cousin SCSM to thank for this…

Leave a Reply