Fixing common MP issues using MPBPA v2

Today, we will take a look at MPBPA v2’s ability to automatically fix problems it finds in management packs. To illustrate this behavior, I attached a small sample MP that has a few best practice violations that can be fixed by MPBPA v2. (MPBPA v2 is available from the System Center Operations Manager 2007 R2 Authoring Resource Kit.

After downloading the sample MP, open it in the Authoring Console. Then, click Tools \ Analyze with MPBPA… :

image

This will bring up a window similar to this:

image

If you see something different, make sure that you are checking for all best practice violations. The easiest way to do that is by clicking Configure and then Restore default configuration in the window that opens.

Looking at the window above, check all the available check boxes by either clicking Check All or manually clicking each violation displayed. This will enable the Fix Checked Violation(s) button:

 

image

Click Fix Checked Violation(s) . The following window will appear:

image

As you can see, the Description field has a red exclamation point near it. This means that the data entered in the field is invalid. Hover the cursor anywhere over the field or the exclamation point to find out why the entered data is invalid:

image

 

Entering some description will enable Preview and Fix buttons as well as the Fix all similar violations using same inputs.

image

Clicking Preview will display a preview of the fix about to be made to the management pack using the preview tool that you have configured. If you have a preview tool configured, click Preview. If you had WinDiff configured, something similar to this would appear:

image

 

This is the only change that fixing will make to the MP. A missing MP description requires that we add the missing tag and an appropriate value. Let’s click Fix to make the change. Since the other two checked violations do not require any user input, MPBPA will just fix them. The result will be similar to this:

image

 

 

At this point, you can click Rescan to confirm that fixed violations are really gone, but you don’t have to. Simply close the MPBPA v2 window and save the MP in the Authoring Console.

MPBPA v2 is capable of automatically fixing many common issues with MPs and identifying many more. If you’d like some more information about a particular issue, simply highlight it and click Link to help:

image

When you do that, a knowledge article will be displayed using your default browser with information about the selected issue. Good luck and happy fixing!

 

This posting is provided "AS IS" with no warranties.
Use of included tools and reports are subject to the terms specified at
https://www.microsoft.com/info/cpyright.htm

MarcinAtWork.BestPracticeViolations.One.xml