Sequencing SQL Server Management Studio 2014 with App-V 5.x normally throws the error “Invalid license data. Reinstall is required” at lauch. This error is not coming from Management Studio itself, but from the prereq Microsoft Visual Studio 2010 (isolated) version which is installed as part of the application.
Stuff like Visual C++ and Visual Studio should (if possible) be installed in the base image to keep the App-V packages size down. Rory Monaghan has already written an App-V Recipe: SQL Management Studio 2012, but it’s rather complex. Let me show you a very simple way to sequence SQL Server Management Studio 2014.
By now you probably now that I love automation, and my Powershell scripts below are extremely fast and flexible to customize. When I’m doing testing I always use Amazon because the downloads normally take only 1 minute compared to 30 minutes in my home lab. The VM’s even stop and start on demand as explain in my post Automatically Start and Stop Amazon VMs.
Before Sequencing
Run the following two Powershell scripts on the sequencing machine to download and install Microsoft Visual Studio 2010 with Service Pack 1.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 |
# PowerShell Wrapper for MDT, Standalone, Chocolatey and LifeCycle Management - (C)2015 xenappblog.com # Example 1: Start-Process "XenDesktopServerSetup.exe" -ArgumentList $unattendedArgs -Wait -Passthru # Example 2 Powershell: Start-Process powershell.exe -ExecutionPolicy bypass -file $Destination # Example 3 EXE (Always use ' '): # $UnattendedArgs='/qn' # (Start-Process "$PackageName.$InstallerType" $UnattendedArgs -Wait -Passthru).ExitCode # Example 4 MSI (Always use " "): # $UnattendedArgs = "/i $PackageName.$InstallerType ALLUSERS=1 /qn /liewa $LogApp" # (Start-Process msiexec.exe -ArgumentList $UnattendedArgs -Wait -Passthru).ExitCode Write-Verbose "Setting Arguments" -Verbose $startDTM = (Get-Date) $Vendor = "Microsoft" $Product = "Visual Studio" $PackageName = "VSIsoShell" $Version = "2010" $InstallerType = "exe" $LogPS = "${env:SystemRoot}" + "\Temp\$Vendor $Product $Version PS Wrapper.log" $LogApp = "${env:SystemRoot}" + "\Temp\$PackageName.log" $Destination = "${env:ChocoRepository}" + "\$Vendor\$Product\$Version\$packageName.$installerType" $UnattendedArgs = '/q /full /norestart' $url = "http://download.microsoft.com/download/1/9/3/1939AD78-F8E8-4336-83F3-E2470F422C62/VSIsoShell.exe" $output = "$env:SystemDrive\Installers\$Vendor\$Product\$Version\$PackageName.$InstallerType" Start-Transcript $LogPS if (-not (Test-Path $env:SystemDrive\Installers\$Vendor\$Product\$Version)) { Write-Verbose "Starting Download of $Vendor $Product $Version" -Verbose New-Item -Path $env:SystemDrive\Installers\$Vendor\$Product\$Version -ItemType Directory | Out-Null $wc = New-Object System.Net.WebClient $wc.DownloadFile($url, $output) } else {Write-Verbose "$Vendor $Product $Version Exist" -Verbose} CD $env:SystemDrive\Installers\$Vendor\$Product\$Version Write-Verbose "Starting Installation of $Vendor $Product $Version" -Verbose (Start-Process "$PackageName.$InstallerType" $UnattendedArgs -Wait -Passthru).ExitCode Write-Verbose "Customization" -Verbose Write-Verbose "Stop logging" -Verbose $EndDTM = (Get-Date) Write-Verbose "Elapsed Time: $(($EndDTM-$StartDTM).TotalSeconds) Seconds" -Verbose Write-Verbose "Elapsed Time: $(($EndDTM-$StartDTM).TotalMinutes) Minutes" -Verbose Stop-Transcript |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 |
# PowerShell Wrapper for MDT, Standalone, Chocolatey and LifeCycle Management - (C)2015 xenappblog.com # Example 1: Start-Process "XenDesktopServerSetup.exe" -ArgumentList $unattendedArgs -Wait -Passthru # Example 2 Powershell: Start-Process powershell.exe -ExecutionPolicy bypass -file $Destination # Example 3 EXE (Always use ' '): # $UnattendedArgs='/qn' # (Start-Process "$PackageName.$InstallerType" $UnattendedArgs -Wait -Passthru).ExitCode # Example 4 MSI (Always use " "): # $UnattendedArgs = "/i $PackageName.$InstallerType ALLUSERS=1 /qn /liewa $LogApp" # (Start-Process msiexec.exe -ArgumentList $UnattendedArgs -Wait -Passthru).ExitCode Write-Verbose "Setting Arguments" -Verbose $startDTM = (Get-Date) $Vendor = "Microsoft" $Product = "Visual Studio" $PackageName = "VS10sp1-KB983509" $Version = "2010 SP1" $InstallerType = "exe" $LogPS = "${env:SystemRoot}" + "\Temp\$Vendor $Product $Version PS Wrapper.log" $LogApp = "${env:SystemRoot}" + "\Temp\$PackageName.log" $Destination = "${env:ChocoRepository}" + "\$Vendor\$Product\$Version\$packageName.$installerType" $UnattendedArgs = '/q /full /norestart' $url = "http://download.microsoft.com/download/2/3/0/230C4F4A-2D3C-4D3B-B991-2A9133904E35/VS10sp1-KB983509.exe" $output = "$env:SystemDrive\Installers\$Vendor\$Product\$Version\$PackageName.$InstallerType" Start-Transcript $LogPS if (-not (Test-Path $env:SystemDrive\Installers\$Vendor\$Product\$Version)) { Write-Verbose "Starting Download of $Vendor $Product $Version" -Verbose New-Item -Path $env:SystemDrive\Installers\$Vendor\$Product\$Version -ItemType Directory | Out-Null $wc = New-Object System.Net.WebClient $wc.DownloadFile($url, $output) } else {Write-Verbose "$Vendor $Product $Version Exist" -Verbose} CD $env:SystemDrive\Installers\$Vendor\$Product\$Version Write-Verbose "Starting Installation of $Vendor $Product $Version" -Verbose (Start-Process "$PackageName.$InstallerType" $UnattendedArgs -Wait -Passthru).ExitCode Write-Verbose "Customization" -Verbose Write-Verbose "Stop logging" -Verbose $EndDTM = (Get-Date) Write-Verbose "Elapsed Time: $(($EndDTM-$StartDTM).TotalSeconds) Seconds" -Verbose Write-Verbose "Elapsed Time: $(($EndDTM-$StartDTM).TotalMinutes) Minutes" -Verbose Stop-Transcript |
Now since the prereqs are already installed, the sequencer won’t capture those and keep the package at a nice 226 MB in size.
Configure the Sequencer
Download Microsoft SQL Server Express 2014.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 |
Write-Verbose "Setting Arguments" -Verbose $StartDTM = (Get-Date) $url = "http://download.microsoft.com/download/E/A/E/EAE6F7FC-767A-4038-A954-49B8B05D04EB/ExpressAndTools%2064BIT/SQLEXPRWT_x64_ENU.exe" $output = "$PSScriptRoot\SQLEXPRWT_x64_ENU.exe" $start_time = Get-Date $Vendor = "Microsoft" $Product = "SQL Server Express" $Version = "2014" $LogPS = "${env:SystemRoot}" + "\Temp\$Vendor $Product $Version PS Wrapper.log" Start-Transcript $LogPS Write-Verbose "Start Downloading $Vendor $Product $Version" -Verbose $wc = New-Object System.Net.WebClient $wc.DownloadFile($url, $output) #OR (New-Object System.Net.WebClient).DownloadFile($url, $output) Write-Verbose "Stop logging" -Verbose $EndDTM = (Get-Date) Write-Verbose "Elapsed Time: $(($EndDTM-$StartDTM).TotalSeconds) Seconds" -Verbose Write-Verbose "Elapsed Time: $(($EndDTM-$StartDTM).TotalMinutes) Minutes" -Verbose Stop-Transcript |
Run the SQLEXPRWT_x64_ENU.exe to extract files. Close the setup and restart.
Download and load the App-V 5 Sequencer Template from Aaron Parker.
Exclusions
Add the following directory exclusion to the sequencer (VRF):
- [{Profile}]
- [{Common AppData}]\Microsoft\RAC
- [{UserProfiles}]
- [{AppVPackageDrive}]\Source
Sequence with App-V
The is sequencing is straight forward from here.
Select features as shown below.
Select to customize the package so you can delete unwanted icons.
Now the final part is to make sure Microsoft Visual Studio 2010 with Service Pack 1 is installed on the clients. If you’re using Citrix Lifecycle Management you can use the script as is.
With other OSD tools you just need to change the path to the installation media. There’s tons of examples with Microsoft Deployment Toolkit here on the blog.
Worked excellent! The only good guide for sequincing this crap.
Awesome, agree to both 🙂
Perhaps without the original guide, this one wouldn’t exist….
Correct 🙂
This recipe helped me to sequence SSMS 2014 on Win 7 x86. Every recipe I found for sequencing SSMS were all for x64.
Thank you!
Robert
Awesome, glad it worked for you.
Wish there was a way to get around the 1.2 Gb install of VSIsoShell 2010 on the client.
I used this recipe for sequencing SSMS 2012. Is worked fine. But the compoment “SQL Server Object Explorer is missing” on my APP-V.
Do you know how to fix it ?
Thank You
Hi Bao. so SSMS start okay and you get the error above? All pre-req’s have been installed on the target machines?
Hi Trond, I don’t get any errors.
ssms start but the feature/component “SQL Server Object Explorer” isn’t load.
Visual Studio 2010 Shell Isolate and Visual Studio 2010 SP1 has been installed on the machine.
See screenshots:
SSMS APPV : http://nsa38.casimages.com/img/2015/12/10/151210020439102838.png
SSMS NON APPV : http://nsa38.casimages.com/img/2015/12/10/151210020551909516.png
List of Prerequisites installed : http://nsa38.casimages.com/img/2015/12/10/151210020952214190.png
any ideas ?
This worked for me for SSMS 2014 but now we also need SSMS 2012 to do some DBs not upgraded yet. When I follow the same steps I get the error ‘Invalid License data. Reinstall is required’. Which is the same error I was getting before I found this article.
To resolve for 2014 I applied your two Powershell scripts to install MS Visual Studio 2010 (Isolated), .Net Framework 4 Multi-Targeting Pack, MS Visual C++ 2010 x86 runtime – 10.0.30319, MS SQL Server 2008 R2 Mgmt Objects, MS SQL Server System CLR Types and finally MS Help Viewer 1.0.
If we already have a current .NET version on our images can this be the culprit or is there another recipe to follow other than Rorymon’s?
Any help is appreciated.
I will give you the quick fix and it’s perfect, go for Turbo
https://turbo.net/hub/sqlserver/ssms2012
https://turbo.net/hub/sqlserver/ssms2014
Followed the steps above on Server 2008 r2 and I am continually getting error message when attempting to launch “SQL Server 2014 Configuration Manager”:
“Cannot connect to WMI provider. You do not have permission or the server is unreachable. Note that you can only manage SQL Server 2005 and later servers with SQL Server Configuration Manager.
Invalid namespace”
Anyone else experience this and/or have a workable solution?
The best option is to not sequence SSMS and instead use Turbo.net
Thanks Trond. Our company is looking for an App-V solution for this product. We are governed to only one virtual solution. Have you or anyone else successfully used “SQL Server 2014 Configuration Manager” with their App-V package?
Any template or update on SQL management studio 2016 ?
Nope, I’m using Turbo.net instead now. Much easier, and no work at all.
Looks like the VS 2010 components are for SSMS 2012. SSMS 2014 (SSMS-Setup-ENU) appears to require VS 2015 components.
May have changed with a newer release of 2014.
Nevermind! I was given the wrong install media
Can we choose different username under windows authentication. its grayed out and taken user credentials used to login in to citrix. Thank You!