Skip to content

Instantly share code, notes, and snippets.

@kkamegawa
Created December 8, 2012 15:58
Show Gist options
  • Star 1 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save kkamegawa/4240828 to your computer and use it in GitHub Desktop.
Save kkamegawa/4240828 to your computer and use it in GitHub Desktop.
Deny Itanium patch in Windows Server 2012's WSUS
$wsus = Get-WsusServer -name localhost -PortNumber 8530
$ia64 = $wsus.GetUpdates() | Where-Object {$_.title.indexof("Itanium") -gt 1 -and $_.title.indexof("x64") -eq -1 -and $_.ArrivalDate -gt [datetime]::Now.AddDays(-7)}
foreach($patch in $ia64) {
Get-WsusUpdate -UpdateId $patch.id.updateid | Deny-WsusUpdate
}
$wsus | Invoke-WsusServerCleanup -CleanupObsoleteUpdates -CleanupUnneededContentFiles -CompressUpdates -DeclineExpiredUpdates
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment