Running Best Practice Analyzer for WSS and MOSS 2007
Today I wanted to share howto use the "Microsoft Best Practices Analyzer for Windows SharePoint Services 3.0 and the 2007 Microsoft Office System"
available from http://www.microsoft.com/downloads/details.aspx?familyid=cb944b27-9d6b-4a1f-b3e1-778efda07df8&displaylang=en in your environment.
As you may have read this BPA collects settings and values from data repositories including Microsoft SQL Server, Registry, and Performance Monitor.
It is nice to see the core BPA to extend to others products, although they do not leverage the same interface/help/guidance nor installation process:
- BizTalk Server 2006 Best Practices Analyzer http://www.microsoft.com/downloads/details.aspx?FamilyID=dda047e3-408e-48ba-83f9-f397226cd6d4&displaylang=en
- SQL Server 2005 Best Practices Analyzer http://www.microsoft.com/downloads/details.aspx?familyid=DA0531E4-E94C-4991-82FA-F0E3FBD05E63&displaylang=en
- Microsoft Best Practices Analyzer for Windows SharePoint Services 3.0 and the 2007 Microsoft Office System http://www.microsoft.com/downloads/details.aspx?FamilyId=CB944B27-9D6B-4A1F-B3E1-778EFDA07DF8&displaylang=en
- Microsoft Exchange Best Practices Analyzer v2.8 http://www.microsoft.com/downloads/details.aspx?FamilyID=dbab201f-4bee-4943-ac22-e2ddbd258df3&DisplayLang=en
- Microsoft Internet Security and Acceleration (ISA) Server Best Practices Analyzer Tool http://www.microsoft.com/downloads/details.aspx?FamilyID=d22ec2b9-4cd3-4bb6-91ec-0829e5f84063&DisplayLang=en
- Best Practice Analyzer for ASP.NET http://www.microsoft.com/downloads/details.aspx?FamilyID=d2717206-e804-415e-9173-c7b7327289e4&DisplayLang=en
- Microsoft Commerce Server 2007 Best Practices Analyzer http://www.microsoft.com/downloads/details.aspx?FamilyID=6be6a088-d613-471a-b1a6-e80dc5050494&DisplayLang=en
- Microsoft Systems Management Server 2003 Desired Configuration Monitoring 2.0 http://www.microsoft.com/downloads/details.aspx?FamilyId=A867FC14-DAA3-4C2A-9E65-4FBCBEC60AAA&displaylang=en
This could bring you a little confusion when using different BPAs, as there is no common UI.
Microsoft Best Practices Analyzer for Windows SharePoint Services 3.0 and the 2007 Microsoft Office System
- First of all, download the bits from the url above.
- execute it, this will ask for a path in order to extract the files.
- Prepare the files
- execute sharepointbpa.exe
There are 3 important files:
- sharepointbpa.config.xml, Configuration file for the BPA process.
- FormatXslTransform.xsl and ReportXslTransform.xsl, XSL Transformations to generate the report.
In order to execute sharepointbpa.exe you can first ask for the neccessary parameters:
- sharepointbpa.exe -? for general help
- sharepointbpa.exe -help analyze for specific run help.
This will bring you this information:
Microsoft Best Practices Analyzer for Microsoft(R) Windows(R) SharePoint(R) Services 3.0 and the 2007 Microsoft(R) Office System version 12.0.4518.1016 Copyright (C) Microsoft Corporation 2007. All rights reserved. sharepointbpa.exe -cmd analyze [-rulefile <\\server\share\rules.xml>] [-outputdirectory <\\server\share>] [-reportformat <xml|html>] [-substitutions <name value>[< ...>]] Performs analysis against the specified Xml file. rulefile: This file contains the set of rules to be run. If not specified, a default rule file located at C:\Blog Entry BPA\sharepointbpa.config.xml will be used. outputdirectory: Specifies the directory where analysis report output files will be created. If not specified, all report files will be saved to the C:\Blog Entry BPA directory. reportformat: Specifies the format of the report that will be generated during an analysis run. If the specified format is xml, the report format will be in xml. If the specified format is html, the report format will be in html. If a format is not specified, then html is used. substitutions: A list of name value pair combinations that are used as substitution variables in the specified rule file. For example, substitution variable names in a rule file use the format %somevariable%. To replace all occurrences of %somevariable% in a rule file, specify 'somevariable somevalue' on the command line. Note that variable names are case sensitive; the case of the variable specified in the rule file must match the case used on the command line.
So you can start running sharepointbpa.exe -cmd analyze -servername <servername>
This will generate a log file, called spbpatrace_<unique identifier>.log and the report
If you include the third parameter -reportformat xml, this file will be sharepointbpa<number>.report.xml
After that you will be provided with a report with the results. After reading the report you will have specific instructions in order to fix them or just be aware of.
Here we can explode other rules and configurations as Bill Baer wrote about at http://blogs.technet.com/wbaer/archive/2007/04/17/understanding-the-microsoft-best-practices-analyzer-for-windows-sharepoint-services-3-0-and-the-2007-microsoft-office-system-rule-file.aspx
The point I wanted to surface is the other options we can use in the config file as:
Substitution in the Configuration node, where a node like this
will give us the option to run with sharepointbpa.exe -cmd analyze
I have attached a sample from the SQL Server BPA.