Windows Update PowerShell Module

This function is a piece of PSWindowsUpdate module to manage Windows Update on a computer system running Windows. Whole module contain set of functions to check, download and install updates from PowerShell.

 
 
 
 
 
4.6 Star
(315)
509,445 times
Add to favorites
Windows Update
4/4/2017
E-mail Twitter del.icio.us Digg Facebook
Sign in to ask a question


  • Using Get-WUInstall in start-job or -AsJob process is only retriving update but not downloading or installing
    1 Posts | Last post October 10, 2017
    • Using Get-WUInstall in start-job or -AsJob process is only retriving update but not downloading or installing
      
      Invoke-Command -ComputerName $servers -ScriptBlock { Get-WUInstall -ServiceID "7971f918-a847-4430-9279-4a52d1efe18d" -AutoSelectOnly -AcceptAll -Confirm:$false -IgnoreUserInput  -Verbose | ft | Out-File C:\Temp\PSWindowsUpdate_$(Get-Date -Format mmddyy).log }  -ThrottleLimit 8 -AsJob
      
      is retrieving only updates in log file but not downloading and installing them? Is this because of it's looking for manual input accept to upgrade your module from online. I get this pop-up message everytime when I run the command using Invoke-WUInstall option.
  • How to auto approve UI which prompting me everytime select to upgrade your module version?
    1 Posts | Last post October 10, 2017
    • How to auto approve UI which prompting me everytime select to upgrade your module version?
  • Which Change Version Should I use for PowerShell 2.0?
    1 Posts | Last post October 03, 2017
    • I still have PS 2.0 on several of my 2008 R2 boxes...  Barring the process of upgrading those to version 3...  Which change revision should I use in order to use PSWindowsUpdate ??
      
      Running "Import-Module PSWindowsUpdate" returns the error "Unblock-file is not a recognized cmdlet".  That appears to be included in PS v3.
  • Get-WUList -MicrosoftUpdate Hangs on few servers
    1 Posts | Last post September 29, 2017
    • Run this cmd on bunch of servers and it hangs on some of them ?
      Debug out :
      DEBUG: STAGE 0: Prepare environment
      DEBUG: Check if ComputerName in set
      DEBUG: Set ComputerName to localhost
      DEBUG: STAGE 1: Get updates list
      DEBUG: Create Microsoft.Update.ServiceManager object
      DEBUG: Create Microsoft.Update.Session object for XXXXXX
      DEBUG: Create Microsoft.Update.Session.Searcher object for XXXXXX
      DEBUG: Set source of updates to Microsoft Update
      DEBUG: Set source of updates to Microsoft Update
      DEBUG: Set pre search criteria: IsInstalled = 0
      DEBUG: Search criteria is: IsInstalled = 0
      
      Anything i need to check on the server ?
      Thanks
  • Exclude updates with no KB
    1 Posts | Last post September 29, 2017
    • I'm running a script that installs updates on a schedule and I'd like to exclude any update that doesn't have a KB ID (usually drivers - Server 2012 R2).
      
      I've tried:
      Get-WUInstall -IsHidden:$false -AcceptAll -IgnoreReboot -Verbose | Where {$_.KB -ne ""}
      but this still install these updates.
      
      Is there any way I can do this?
      
      Thanks
  • Remote errors with Get-WUInstall
    1 Posts | Last post September 27, 2017
    • I have a question posted on stack exchange.  Would you mind taking a look?  THank you so much. 
      https://stackoverflow.com/questions/46457625/using-get-wuinstall-on-remote-machines-access-denied
  • Get-WUServiceManager - WSUS not listed as default
    3 Posts | Last post September 27, 2017
    • OS is Server 2016 w/GUI. For some reason our wsus server is not listed as the default.  I know my client is checking in to our wsus server when I use the GUI to check for updates because I can see the connection on our wsus server.  I have added pointed the client to our wsus server using gpedit.msc.
      
      Here is the output of Get-WUServiceManager (couldnt copy and paste so leaving ID as XXX:
      ServiceID  IsManaged  IsDefault  Name
      ---------  ---------  ---------  ----
      XXX        True       False      Windows Server Update Service
      XXX        False      True       Windows Update
      
      My question is, how can I change it so that our wsus server is the default so that Get-WUInstall pulls updates from our wsus server?
      
      Thanks
    • I have a question posted on stack exchange.  Would you mind taking a look?  THank you so much. 
      https://stackoverflow.com/questions/46457625/using-get-wuinstall-on-remote-machines-access-denied
      
    • Disregard my last reply to you.  That was accidental and not related to your question. Sorry.
  • Exclude Optional
    5 Posts | Last post September 27, 2017
    • In my testing I cannot get this to exclude optional updates. Categorically they are Updates just like normal updates. Running Get-WUInstall -AcceptAll -IgnoreReboot included the update "July, 2017 Preview of Quality Rollup for .NET Framework". Obviously I don't want a preview to be installed on a production server. I can't find a good way to exclude it because it's category was Updates, and it's severity was Moderate. So how can I identify these optionals?
    • Try adding the switch -nottitle 'preview' 
    • That would eliminate only the updates with preview in the title. There are other updates that are normally marked as optional that still be included.
    • After having a look at this, excluding the phrase preview looks the only way, or filter out the updates category 
    • Filtering out updates seems like a bad way to do it since it would eliminate updates.
  • Downloading Updates... Size Displayed is Incorrect
    1 Posts | Last post September 13, 2017
    • When performing the update download, the progress bar is incorrectly reporting the size of the previous downloaded update.  It appears that it's using the size of the last found update and not modifying it for each update as it downloads.  For example if I have 3 updates (11 MB, 1 GB and 144 MB), the download progress bar shows the correct update name but always report the size of 144 MB (the last one in the list).  Hopefully this is an easy fix.  Thanks!
      
  • Registry key not updated after Install
    2 Posts | Last post September 11, 2017
    • Hi,
      I'm using Get-WUInstall since a couple months ago and I've just noticed that the registry key "HKLM\Software\Microsoft\Windows\CurrentVersion\WindowsUpdate\AutoUpdate\Results\Install"  were not updated.
      I build reports based on the value of this key.
      Did I miss something? Is it a normal behavior?
      Any Ideas?
      Thx
    • Please, some help.
1 - 10 of 283 Items