Sorry for the flash back to the Mickey Mouse Club, but it sticks.

Quick Challenge on comparing hot fixes (QFEs) applied to a server farm to determine which ones are needed across all of the servers. There are a few options like Microsoft Baseline Security Analyzer, PowerShell, VBScript calling WMI, C#, C++, etc. However, in comes 2 tools that may may your life a little easier.

  1. WMIC
    1. “The WMI command-line (WMIC) utility provides a command-line interface for WMI. WMIC is compatible with existing shells and utility commands. “
    2. http://msdn.microsoft.com/en-us/library/aa394531.aspx
  2. Microsoft Excel
    1. For Pivot Table goodness

What the whosie what’s it sauce? Yes, WMIC and Excel. In just 1 line of WMIC and then an import into Excel plus a Pivot Table, you can see which QFEs, SP, etc are applied to the servers in your farm.

 

Description

  1. ServerWFE1,  ServerApp and ServerSQL make up your SharePoint Farm.
    1. You have admin permissions on all servers (or can at least run at that level, or have permission to read the WMI classes)
  2. From a command prompt on a machine that has connectivity (please see the link from WMIC for all the details).
    1. WMIC /NODE:”ServerWFE1”,”ServerApp”, “ServerSQL” /OUTPUT:c:\qfe.csv QFE LIST FULL /FORMAT:csv
  3. follow the steps in the Example to get into a Pivot Table!

 

Example

  1. I ran the following command on my local machine
    1. WMIC /NODE:"tadd1" /OUTPUT:c:\qfe.csv QFE LIST FULL /FORMAT:csv
  2. Opened Excel
  3. Opened the c:\qfe.csv file
    1. started at row 2
    2. comma separated
  4. Select the worksheet
  5. Insert Pivot Table
    1. Row
      1. drag HotFixID
    2. Column
      1. drag Node
    3. Values
      1. drag HotFixID
        1. use count
  6. If you have more than one node, you will see a quick table that if count is 1, great, if blank out of synch!

 

PivotTable Sample

Count of HotFixID Column Labels    
Row Labels TADD1 TADD2 Grand Total
KB958690 1   1
KB961367 1 1 2
KB962236 1   1
KB962921 1   1
KB963660 1 1 2
KB967062 1   1
KB967355 1 1 2
KB967492 1   1
KB967540 1 1 2
KB968004 1 1 2
KBWUClient-SelfUpdate-Aux 1   1
KBWUClient-SelfUpdate-Core 1   1
Grand Total 12 5 17

You can also apply an xml style sheet, hint hint, to highlight those that are bad. Or, use conditional formatting from Excel.

 

Peace