Tag : powershell

Package Powershell 5.0 in SCCM

A Surprisingly very easy SCCM Package, the command line is just

wusa.exe Win7AndW2K8R2-KB3134760-x64.msu /quiet /norestart

 

You can download Powershell 5.0 from here:

https://www.microsoft.com/en-us/download/details.aspx?id=50395

 

Detection Method:

http://serverfault.com/questions/555100/methods-to-detect-version-of-windows-management-framework

 

Updated: here is a better way to detect Powershell instillation, especially for Powershell 5.1

if (($PSVersionTable.PSVersion | Select-Object -ExpandProperty Major) -eq 5 -and ($PSVersionTable.PSVersion | Select-Object -ExpandProperty Minor) -eq 1 )

{
Write-Host “Installed”
}

To make it a nice force reboot, I use SCCM 2012 to do the reboot: