We cannot rely on documentation, if they exist, to be accurate, special regarding to the status of the machines present in the environment that tell us what is installed on the machine, what are the updates (or CU) or service pack installed and so on… and regarding to BizTalk Server I do not remember another simple task like this, get or check the list of all BizTalk Cumulative Updates installed in your machine/environment, being so painful to perform!

Of course, there are some ways to check that, for example:

Probably there are other ways, nevertheless, I just want a quick and very easy way, because this is a basic and very simple task, to know what are the BizTalk Cumulative Updates installed like:

HTML
Edit|Remove
This is the list of BizTalk Cumulative Update installed in this machine: BTS2016LAB01  
- Microsoft BizTalk Server 2016 CU1 
So how can we easily automate tasks? and reuse them whenever necessary and at the same time saving significant time for other tasks?

Using PowerShell is a good option. Windows PowerShell is a Windows command-line shell designed especially for system administrators and can be used by BizTalk administrators to help them in automating repetitive tasks or tasks that are time consuming to perform manually.

This is a simple script that allows you to configure the template name of the cumulative updates, that will change from version to version, and will give you the list of all cumulative updates installed in your machine:

 

PowerShell
Edit|Remove
$keyResults = Get-ChildItem -path HKLM:\SOFTWARE\Wow6432Node\Microsoft\Windows\CurrentVersion\Uninstall\ -Recurse -ErrorAction SilentlyContinue | where { $_.Name -match $CUNameTemplate}  
  
foreach($keyItem in $keyResults)  
{  
    if ($keyItem.GetValue("DisplayName"-like "*$CUNameTemplate*")  
    {  
        write-host "-" $keyItem.GetValue("DisplayName").ToString().Substring(0,$keyItem.GetValue("DisplayName").ToString().IndexOf(" CU")+4)  
    }  
}
THIS SQL SCRIPT IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND.

 

Know more about this script here: How to check what BizTalk Server 2016 Cumulative Updates are installed in your Servers with PowerShell

About Me

Sandro Pereira
DevScope | MVP & MCTS BizTalk Server 2010
http://sandroaspbiztalkblog.wordpress.com/ | @sandro_asp