When planning your customizations in Service Manager, one of the most important decisions to make is whether you are going to seal your Management packs or not.
As explained in Chapter 2, Personalizing SCSM 2016 Administration, a sealed management pack is a read-only management pack, which cannot be written to once it has been imported into Service Manager. Furthermore, sealing a management pack enables it to be referenced from within other management packs.
Some examples of when you need to reference another management pack are described here:
Sealing management packs also ensures upgradeability. When you import a later version of a sealed management pack into Service Manager, Service Manager checks whether an upgrade is possible or not, and will reject non-upgradeable management packs. For instance, if you have your own custom class with a set of properties and decide that you do not want a couple of these properties anymore, and try to import a new version of the management pack where these properties have been removed - Service Manager would reject the import. In order to import this new version of the management pack you would actually have to delete the older version from the system first, which also would remove any instances of that class in the database.
As a general rule, always seal management packs that contain the following:
To seal a management pack, you need a Strong Name Key (SNK) file. You can use the sn.exe tool to create a new SNK file. This tool is part of the Service Manager Authoring Tool, but it can also be found in the Windows Software Development Kit (SDK), which can be downloaded from the following URL:
http://www.microsoft.com/en-us/download/details.aspx?id=8279
To create your own strong name key file, first check on your computer for the existence of the sn.exe tool. On computers running the Authoring Tool, sn.exe should be located in C:Program Files (x86)Microsoft SDKsWindowsv6.0Ain
If it isn't present there, you can try searching for it using this method:
cmd
, and then press Enter.cd
and press Enter.dir sn.exe /s
and press Enter. This process will take a while and should output all locations where the sn.exe tool has been found. You can cancel the process with Ctrl-C once you find the tool. Write down the location of the sn.exe tool.Follow these steps to create your own SNK file:
cd <full Path to sn.exe directory>
and press Enter.sn.exe -k <myfilename>.snk
and press Enter, where <myfilename> is the name you want to give the file.
Make sure that you keep a backup of this file and that you use this SNK for all your customizations.
Now that you know the concept of sealed management packs and have created your SNK file, we are going to show you how you can seal management packs using the Authoring Tool:
.XML
file extension and one sealed management pack with the .MP
file extension. Both files should be kept as you need to have the unsealed management pack if you would like to update it in the future.If you have to seal management packs often or would like to do it without using the Authoring Tool, we recommend you use FastSeal.exe
.
Instead of using the System Center 2016 Service Manager Authoring Tool for sealing your management packs, you can also use the FastSeal.exe
command-line utility. This tool is very convenient if you need to seal management packs in bulk or if you want to automate the seal process.
You can download the FastSeal.exe utility from the following URL:
http://blogs.technet.com/b/servicemanager/archive/2009/12/25/sealing-management-packs.aspx.
To seal a management pack with FastSeal
, you simply run this command:
FastSeal.exe ManagementPackToSeal.xml /Company YourCompany /KeyFile YourKeyfile.snk
Refer to the following recipe for more information on how to work with management packs:
18.224.214.215