Jump to content

Recommended Posts

Posted

we have some computers that need driver updates from Windows Update (we use WSUS for security updates). There is a powershell command to check and then install updates

 

Install-Module -Name PSWindowsUpdate

 

#Check

Get-WindowsUpdate -ComputerName ITROOM24 -MicrosoftUpdate

 

#Install

Get-WindowsUpdate -ComputerName ITROOM24 -MicrosoftUpdate -Install-AcceptAll

 

It finds updates, and the updates listed status changes to 'Accepted', but after leaving for a long time, reboot etc running the same command again it finds them again, having done nothing.

 

Anyone had luck doing updates via command line or powershell?

Posted

I assume you've got a space between -Install and -AcceptAll

 

Have you tried Install-WindowsUpdate instead of Get-WindowsUpdate:

 

Install-WindowsUpdate -MicrosoftUpdate -AcceptAll -AutoReboot

 

I've tried this in the past and it seemed to work OK, this was from Microsoft Update (no WSUS)

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now



×
×
  • Create New...