SCCM 2012 Management Scripts

System Center, Configuration Manager 2 feedbacks »

This is a sort of guest post from my good friend Marius van de Ven. It is about a set of management scripts for Configuration Manager. He loves to PowerShell and make his SCCM life easier and better that way. The pack of scripts can be found on TechNet Gallery:

PowerShell: SCCM 2012 Management Scripts (Create Collections, Packages and more)

He explains what this set of scripts is all about below:


I created some sort of "Management Pack" for SCCM 2012. This pack contains quite some scripts which should ease up the management (and maybe implementation) tasks of SCCM 2012. The following scripts + example input files are present:

  • add_PackagesToDPs.ps1
  • add_PackagesToDPs.input
  • create_collections.ps1
  • create_collections.input
  • create_folders.ps1
  • create_folders.input
  • create_metering_rules.ps1
  • create_metering_rules.input
  • create_packages.ps1
  • create_packages.input
  • create_programs.ps1
  • create_programs.input
  • move_collections.ps1
  • move_collections.input
  • move_metering_rules.ps1
  • move_metering_rules.input
  • move_packages.ps1
  • move_packages.input

The names of the scripts pretty much explain what they do, but here is a short description for all of them.

This script will add all packages to all the available DP's, except the PXE's. DP's can be excluded by changing the select query.

This script will create collections that are described in the input file. A distinction in the collections can be made by giving a different CollectionType (device or user).

This will create all the folders, within the SCCM console, to make seperation for collections, packages, etc. This makes the whole more manageable for the SCCM administrators. A distinction can be made between folders for Packages, Advertisements, Software Metering Rules, Devices and Users. Just change the FolderType in the input file to the appropriate value (see the script for an overview).

This will create all the Software Metering Rules. Not much more to say about this. Check the script for a short summary of common LanguageID's that can be used.

This script will create all the packages that are described in the input file. The packages can also be created / moved to a folder that is described in the input file (and was probably created with the create_folders.ps1 script). If the folder doesn't exist, the package will be created / placed in the root.

This will create all the programs in the package that is described in the input file. This was purposely seperated from the packages, because in some cases the program wasn't known yet and the package was. They had to be created in advance.

With this script it is possible to move collections from one folder (location) to another. I had to do this for a lot of collections / applications, because new versions were released, but we wanted to keep the old. I decided to move it all to an _old folder. This script does it fast and clean.

Same functionality as the previous script, except for the metering rules.

You could have guessed what this does :) Move multiple packages to new folders, fast and clean.

Most of these scripts will also work (with some minor adjustments) with SCCM 2007, but I created them especially for SCCM 2012, since more and more customers want this. Find a short 'snippet' of the create collections script + input. If you have any questions / improvements / etc. please let me know.

Note #1: I made the scripts not really in 'PowerShell style', but more in a 'VBScript style'. This is to make them more readable and understandable, also for the less experienced scripters.

Note #2: I seperated all scripts / steps, because that gives me greater control of the total management. All these scripts could also be combined in one (which I have build previously in VBScript for SCCM 2007), but I like this better. Feel free to adjust it to your needs :)

Note #3: I ran all these scripts from the Management Point / SCCM Server! You probably want to do that too or write a small function that makes a connect to that server.


Note from Bob Cornelissen:
This looks like a very nice set of scripts to make your life easier. And of course I see more possibilities to bring this into a combination with other System Center products even.
Feel free to send me your suggestions for changes/improvements/additions and so on and I will pass them on to Marius.

System Center 2012 SP1 is RTM and partly available

SCOM, DPM, SCVMM, Service Manager, SCCM, System Center, SCOM 2012 Send feedback »

You might have seen this out in the community already during some discussions and forum posts and such, but now we can tell you that the SP1 version of System Center 2012 is RTM (no not today, it was already at that stage an undisclosed amount of days ago). However today is the day it has been placed on TechNet and MSDN in order to download for people who have access to these. So now I can talk about it a bit more. Just to be clear, this does not mean everybody can download and use it yet, this is not GA. The GA date will be disclosed at a point in the near future when all the announcements will be made and everybody will have the pleasure of working with this great release!
Also the documentation is not at a final release on the internet yet, but this will also be updated soon.
There are lots of great things in this release for all the products. Of course the Windows 2012 support for both the System Center server backend machines and the managed/monitored systems is a big one. But there is a lot more in there!

Can't wait to install the latest bits and start using it in a final version.
For those who can not download and use it yet... well there is lots to do during the holiday season of these weeks! Enjoy the season and your family and friends and food and drinks and so on!

I want to congratulate the System Center Product Team with this achievement and of course to also extend seasons greetings to them!

Update 21-Dec: FAQ

Q: Is SP1 RTM?
A: Yes

Q: Is SP1 GA? Or when will it be GA?
A: It is not GA today. I do not know when it is going to be GA and/or can not say. Microsoft will let us know at the GA point in time that it will be GA. Thats how its gonna be.

Q: Can I download and use SP1?
A: If you are TechNet or MSDN subscriber and have the right access rights (perhaps all subscribers have those rights, I dont know), you will see it and be able to downlaod and use it. Many people/customers/admins who do not have access to these tools will not be able to download/get it until GA. But I guess this is also linked to availability of license keys (if you start all over with SC 2012 at that level), and documentation and all such things. In this way the people who are playing with the products and test and investigate can use it for a few days/weeks/?? until GA and can hit the ground running.

Bob Cornelissen

Visual Guide to Windows Server training and certification

Active Directory, Windows 2012 Send feedback »

The Born to Learn team has posted a nice interactive graphic which shows you how to find training and get certified for Windows Server (2012). The linked picture below will take you there.

Windows Server Certification and Career Paths

Enjoy your learning path!
Bob Cornelissen

Activating your SCOM 2012 license again

SCOM, System Center, SCOM 2012 2 feedbacks »

Hi friends. Because I get this question more often, lets paste the commands again to license your SCOM 2012 server.

First check your license status.
Open an Operations Manager Shell and type/paste:
Get-SCOMManagementGroup | ft skuforlicense, version, timeofexpiration –a

If you on an eval version you will see something like the following


The word Eval gives it away, as well as an end-date within days to months.

What you need first it to find your System Center 2012 license somewhere. Once you have it you can apply it with another command - where the 99999 thing is of course to be replaced by your key:

Set-SCOMLicense -ProductId '99999-99999-99999-99999-99999'

Answer "Y" to confirm your action

Now you could get an error at this point looking like this:


In a text version the most important pieces is this:
Set-SCOMLicense : Requested registry access is not allowed.

If you encounter this, just open a normal Powershell, but use the right-click and Run As Administrator. Next, because it is not an Operations Manager Shell you need to import the SCOM module first and next enter the command again.

Import-Module OperationsManager
Set-SCOMLicense -ProductId '99999-99999-99999-99999-99999'

Answer "Y" to confirm your action

After this restart your SCOM server and check the license status again.


And there we go. It says retail and it is valid for a few more years, or at least longer than I expect to live B) Don't look at the version, I was too lazy to wait for the reboot so took it off another server.

Hope this helps, also if you get that nice registry error again :)

Reference the MS KB article:

Bob Cornelissen

Windows Server 2012 Essentials Management pack released

SCOM, System Center, SCOM 2012 Send feedback »

Windows Server 2012 Essentials management pack for SCOM 2012 has been released. I missed it a good week ago or so :roll: , but just in case... Here is the link to the
Windows Server 2012 Essentials Management pack


SCOM 2012 Visio Stencils

SCOM, System Center, SCOM Tricks, SCOM 2012 Send feedback »

Whenever you are designing or documenting SCOM environments you are likely to run into Visio to create those pictures with. Now in the past for SCOM 2007 we had the visio stencils which Jonathan Cusson brought together over here. Until now we did not have an extended set for the 2012 version.

Larry Rayl from Catapult Systems stepped up and created a number of icons he needed and while he was at it created a good number more! Kudo's Larry!!

You can download the SCOM 2012 Visio Stencil over here. Take a look at the accompanying blog post entry with examples of these figures from the Visio stencil for System Center 2012 Operations Manager.

For sure an addition to my toolbox!
Happy diagramming!
Bob Cornelissen

SCOM 2012 IPD guide is released

SCOM, System Center, SCOM Tricks, SCOM 2012 Send feedback »

The Infrastructure Planning and Design guide (IPD) for SCOM 2012 has just been released for download. As I wrote before it had been in development for a few months.

You can download the new SCOM 2012 IPD guide over here:

Enjoy your designing!
Bob Cornelissen

Cluster Disks management pack addendum updated

Windows 2008, SCOM, System Center, SCOM Tricks, SCOM 2012, Windows 2012 3 feedbacks »

A few months ago Microsoft released newer versions of the Windows Server base OS management pack. This version had a good number of improvements, especially in the monitoring of cluster disk and cluster shared volumes. However the pack was still not complete enough in the sense that it missed the performance collection rules for Cluster Disks (the new class, replacing the Logical Disk pieces especially for CLustered instances).

My highly respected colleague MVP Daniele Grandini helped out by creating an addendum management pack for Cluster Disks which would take care of this. Explanation can be found here: Cluster Disks management pack addendum and he posted the management pack on the Technet Gallery over here:

This week I was loading new management packs - Windows Base OS and SQL and of course this addendum mp because they had a lot of clusters in this monitored environment. And discovered that the pack Daniele had authored was authored on a SCOM 2012, while I was loading it into a SCOM 2007 R2 at the moment and that did not work for two reasons. So I changed the management pack a bit to make it work with SCOM 2007 R2 as well and sent it back to Daniele and he immediately placed the changed MP on the TechNet Gallery entry mentioned above. Its great to get these adjustments out this fast and really proves how much we can do in the community by joining forces to make things work and share!

If you are into monitoring Clusters than take a good look at the latest WIndows Server mp and this addendum mp to catch a bit more (and more reliable) ifnormation about your high available systems.

Big thanks to Daniele Grandini!

Bob Cornelissen

SCOM Management pack fails to import due to nulnulnul entries in xml

SCOM, System Center, SCOM Tricks, SCOM 2012 Send feedback »

Had something funny today, with an unsealed management pack failing to import.
It gave an error like so:

The management pack cannot be imported.
Xml failure while validating maangement pack. [Line: 227, Position 18]
hexadecimal value 0x00, is an invalid character. Line 227, postion 18.

As it turns out when opening the xml file in Notepad++ we saw a lot of nulnulnul entries at the end of the file.

Mp nul

This seems to have been caused by copying the file around. Another instance from where it was copied from did not have these entries. It does not always happen, but just occasionally.

Solution is simple of course... delete those nulnulnul entries at the end of the file and try to import again.

A friend of mine, Yvo Quirijnen, already ran into this last week while trying to import other management packs in the same environment and found those nulnulnul entries. As we could not find posts from other people running into this I thought to post it here, just in case you run into this.

Happy importing!
Bob Cornelissen

Mastering System Center 2012 Operations Manager book available

SCOM, System Center, SCOM Tricks, SCOM 2012 Send feedback »

Lately we have gotten many questions about when the book Mastering System Center 2012 Operations Manager from Sybex would be available. It is great that you all have so much interest in what we are writing about and when you can get your hands on it! B)

Well, a few weeks ago the printing presses started rolling and last week the boxes with books started to be sent out to the big book stores. Depending on where your closest book store is this moves faster or slower. Officially we understood that in the Amazon stores the books would be available around 6 November in the USA and 9 November in Europe.

However.... I got word that the site in the USA already has it in stock! :D

So this is a good time to buy the book and get started with it! Also if you order on one of the european sites you know it will not be long until you receive it so start pre-ordering! And while you are there, also take a look at the Mastering System Center 2012 Configuration Manager book from our ConfigMgr friends.

Again our website is: where you can find some more information about the book and the authors.

Links where you can order the book at a number of Amazon stores in Europe and the US:

Order your copy here from the Amazon COM site
Mastering System Center 2012 Operations Manager at Amazon UK
Mastering System Center 2012 Operations Manager at Amazon DE Germany
Mastering System Center 2012 Operations Manager at Amazon FR France
Mastering System Center 2012 Operations Manager at Amazon IT Italy
Mastering System Center 2012 Operations Manager at Amazon ES Spain

Mastering SCOM 2012 Cover

Contact / Help. ©2017 by Bob Cornelissen. blog software.
Design & icons by N.Design Studio. Skin by Tender Feelings / Evo Factory.