Backup unsealed Management Pack command line tool

Hi, Mark Manty Premier Field Engineer for Microsoft with
another example command line tool. Microsoft recommends that you backup
unsealed management packs in the event that you need to restore them in the
future. This command line tool can simplify the process for you.

This example could be scheduled to run to help ensure you have
backed up the unsealed management packs in the environment. It also allows for
specifying custom query to change the export criteria.

Let’s go.

This sample program takes one required parameter along with
one optional second parameter:

  • Required: First parameter is the RMS Server
    name, example MyRMSServer
  • Optional: Second parameter is the custom query
    you would like to specify the management packs to export, example “Sealed = 1”.
    Note: if second parameter is not provided it defaults to criteria of “Sealed =
    0”

 

I ran this in a test environment and it does not have to run
on a RMS or MS to work. It must meet the below requirements in order to run
successfully:

  • .NET 3.5 Framework
  • SCOM R2 Console (User Interface installed)
  • Run as account that has administrative rights to
    the SCOM Management Group

Download the ZIP file BackupUnsealedMPs.zip and extract BackupUnsealedMPs.exe
to a folder of your choice.

Open an administrative command prompt running under an
account that has SCOM administrative privileges.

Change to the directory where you extracted
BackupUnsealedMPs.exe.

Run program “BackupUnsealedMPs.exe MyRMSServer” where
MyRMSServer is your RMS server name and press enter to run.

Program will create a folder with the format YYYY-MM-DD-HH-MM-SS
example: 2012-2-10-8-52-22 and export all unsealed MP’s to that folder.

 
 
 
 

Optionally you can specify a second parameter to modify what
will be exported.

See this link for available properties to specify in your
optional query:

https://blogs.msdn.com/b/scplat/

Run program BackupUnsealedMPs.exe MyRMSServer “DisplayName Like
‘%Microsoft%’” where MyRMSServer is your RMS server name and press enter to
run.


 

 

Disclaimer:

This example is provided “AS IS” with no warranty expressed
or implied. Run at your own risk.

The opinions and views expressed in this
blog are those of the author and do not necessarily state or reflect those of
Microsoft.

BackupUnsealedMPs.zip