Lync/SfB: Check client version using PowerShell

During troubleshooting we often need to check the installed version, for Lync/SfB Server we already know how to check the installed version using PowerShell:

Skype for Business Server Component Version using Get-CsServerPatchVersion

Skype for Business Server 2015 Component Version using PowerShell

Lync Server Component Version using PowerShell (Windows Registry)

On the client we can check the version by using going to Option > Help > About:

However, for the SfB 2016 MSI this is a slightly different since the displayed version is the MSO component and not the SfB client version:

To get the Lync/SfB client version we can simply run the following in PowerShell cmdlet:

(Get-ItemProperty -path “HKLM:\Software\Microsoft\Windows\CurrentVersion\App Paths\lync.exe”).”(Default)” | ForEach-Object {Get-ChildItem -Path $_ | Select-Object -ExpandProperty VersionInfo | Select FileDescription,ProductVersion} | ft -autosize

Skype for Business 2016 MSI

Skype for Business 2016 Click-to-Run

Skype for Business 2015 MSI

Please note that this will work for Lync2013/SfB2015/SfB2016 Click-to-Run or MSI versions.

For Lync 2010 and previous client versions we need to modify from lync.exe to communicator.exe:

(Get-ItemProperty -path “HKLM:\Software\Microsoft\Windows\CurrentVersion\App Paths\communicator.exe”).”(Default)” | ForEach-Object {Get-ChildItem -Path $_ | Select-Object -ExpandProperty VersionInfo | Select FileDescription,ProductVersion} | ft -autosize

Lync/SfB Server: Stop Front End service in Starting state

Some of the cases we work have the Front End service in a Starting state:

In PowerShell the status is StartPending:

We cannot stop it on the Services Management Console:

We can go to Task Manager and try to manual stop the service:

If that doesn’t work we need to Go to Details and End task that is associated with the service:

Another simple way to stop all Starting services is by using the following PowerShell cmdlet. We will get a prompt for each service:

Get-Service | ?{$_.Status -eq “StartPending”} | Stop-process

Get-Service
https://msdn.microsoft.com/en-us/powershell/reference/5.1/microsoft.powershell.management/get-service

Stop-Process
https://msdn.microsoft.com/en-us/powershell/reference/5.1/microsoft.powershell.management/stop-process