Practice Exams for Windows

Practice Exams for Windows

Sunday, 18 September 2011

Hands on with the Hyper-V BPA (Best Practices Analyser)

Make sure you have the Hyper-V BPA hotfixes installed:

  1. http://support.microsoft.com/kb/977238
  2. http://support.microsoft.com/kb/2485986 (If using SP1, especially when using Dynamic Memory)

You can use Windows Update or Windows PowerShell (shown below as it should appear) to check if you have the updates installed.

image

Once installed, the Hyper-V BPA will appear in Server Manager as shown below. Click the “scan this role” link to see check your server:

image

Once the scan is complete, the results will be displayed. Double-click any of the entries to see more detail.

image

Ok, so I’m not compliant. Why? Well I didn’t realise the Windows XP processor issue was the case, I thought Windows XP took two vCPUs like Windows Server 2003 – Obviously that is not the case. Also, I only have one NIC in this server. It’s a lab, I can get away with it, but don’t do that in a production environment.

Now for the fun stuff. Maybe you want to schedule the BPA to run periodically and email you if it fails. That’s when you use PowerShell!

Start by importing the Best Practices Module:

image

To get a list of commands available in the module, use get-command:

image

The get-bpamodel cmdlet can be used to get a list of best-practices scanners available on the server:

image

The Invoke-BPAModel cmdlet can be used to run a best practice scan. Just pass in one of the Ids listed when from the get-bpamodel cmdlet:

image

The Get-BPAResult cmdlet will allow you to see to see the results of the analysis.

image

It can be a little bit of information overload, so you best combine it to a few select, sort and format statements:

image

This could easily be built into a larger script that performs the actions previously mentioned.

1 comment:

  1. just wanna say : great explaination ! i like the way you prepare & display of Text+image in your post.

    ReplyDelete