Sealing a Management Pack is easy. Although, it can be frustrating the first time through. It's a process that requires a few different pieces to interact, so preparation is key. Going through some simple steps now will save time in the future.
Finally, the c:\MPS directory will look like this.
The two files highlighted: Command.txt is just a file I created that contains the commands needed to seal the management pack. The MPResources.resources file is automatically created while sealing management packs. This is not anything you’ll need to copy into the directory.
Now, we're ready to seal our Management Pack.
Open a command prompt and navigate to your work directory (c:\MPS). Run these commands in sequence. (beware of word wrap with these commands)
You should now have your sealed MP in the Output directory. And, you'll have a working directory for later use. Just remember to keep the MP versions in the c:\MPS\MP directory current with your Management Groups. Otherwise, you'll get version errors while attempting to run the MPSeal tool.
Hint: Once you've created the key the first time around, it's not necessary to create a new key each time you seal a MP. The current key may be reused. So, the only step you'll need to actually do after the first run is the last step. How's that for easy!
A note to developers: I’ve had some questions about where the MPResources.resources file mentioned above is created. Specifically, if two build flavor threads (x64 and x86, for example), compiles at same time and try to create this file under sources, one build thread will break.
To solve that problem, execute MPSeal from a different location. Examples below.
This will create the MPResources.resources file in the users %temp% directory.
This will create the MPResources.resources file in the x86 directory I created.
This will create the MPResources.resources file in the x64 directory I created.
Great tutorial, congratulations.
Let me know, why can I copy Management Packs from SCOM instalation folder to other folder when I can referencing the original folder directly in command line? Example:
mpseal c:\mps\input\<unsealed_mp>.xml /I "c:\mps\mp" /Keyfi
e "c:\mps\key\PairKey.snk" /Company "Your Company" /Outdir "c:\mps\output"
mpseal c:\mps\input\<unsealed_mp>.xml /I "c:\Program Files\System Center Operations Manager 2007\" /Keyfi
This is my doubt.
Tnx a lot.
Response: The reason why I suggest creating these working directories, is because (1) not everyone will be sealing MP's directly on the RMS and (2) you may not have all required MP references to seal a custom MP in the programs directory on the RMS. If you are sealing an MP that contains, for example, an Active Directory reference, you'll need to reference that MP while sealing your custom MP. This will not be in RMS OpsMgr Program Files. You'll need to locate them. Creating these working directories on a workstation in which you'll be sealing MP's is simply an organizational practice.
Feed: www.contoso.se Posted on: Tuesday, February 03, 2009 8:54 AM Author: Anders Bengtsson Subject:
Let me just begin by saying : AAAaaaaaarrgh! Now I feel better. If you’ve made any attempt at implementing
Great article. I just followed point by point and i am successful. Great work... thanks a lot.
Gopalan (From India)
I have had a few requests now for this, so I thought I would take the time to write up the process.
Can we redirect the temporary files to some directory? I mean, can I give temporary path where MPResources.resources should be created?
This is generated when running MPSeal, but I don’t know of a way to command the MPSeal program to create the MPResources.resources file in some other directory.
I figured out how and and where that MPResources.resources file is created. I added some notes at the bottom of the post to answer your question. It's in "A note to developers".
Good Stuff... Thanks for the information. It's made my life with SCOM a lot better!
Excellent. The steps which you presented is working perfectly and its easy to follow up.
Thanks a lot for helping many SCOM people who are eagerly look for this information.
Great work. Easy to follow and implement.
Thank you a million times!
Worked like a charm from start to finish! cheers
I am getting error after following all these steps. Even though I have copied all mps from scom directory
Could not load ManagementPack [ID=Microsoft.SystemCenter.Library, Keytoken=31bf3
856ad364e35, Version=6.1.7221.61]. ManagementPack not found in the store.Cannot
find MP File "Microsoft.SystemCenter.Library.mp" in any of the search directorie
Sometimes customers need to create their own service monitor. This usually leads them to the Windows