Installing Windows Update Services
WSUS is a feature within Windows Server 2019. To use Windows Update Services, you first install the WSUS Windows feature and then do basic configuration and setup. In this recipe, you install WSUS and review the results of that installation.
Getting ready
This recipe uses the WSUS1
server, a member server in the Reskit.Org
domain. At the start of this recipe, WSUS1
has no additional features or software loaded.
How to do it...
Install the Windows Update feature and tools:
$IFHT = @{ Name = 'UpdateServices' IncludeManagementTools = $true } Install-WindowsFeature @IFHT
Determine the features installed on the
WSUS1
server after installation of WSUS:Get-WindowsFeature | Where-Object Installed
Create a folder for WSUS update content:
$WSUSDir = 'C:\WSUS' If (-Not (Test-Path -Path $WSUSDir -ErrorAction SilentlyContinue)) {New-Item -Path $WSUSDir -ItemType Directory| Out-Null}
Perform post-installation configuration using
WsusUtil.Exe
:$CMD ...