Advertisement
Guest User

Untitled

a guest
Mar 27th, 2015
213
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.34 KB | None | 0 0
  1. wusa c:temphotfixname.msu /quiet /norestart
  2.  
  3. import-module ActiveDirectory
  4.  
  5. $AllPCs = Get-ADComputer -SearchBase "Appropriate OU Here" -filter *
  6.  
  7. $AllPCs | Foreach {
  8. Invoke-Command -ComputerName "$($_.name)" -AsJob -ScriptBlock {
  9. if (!(Get-HotFix -id hotfixkb)) { CMD /C "wusa.exe c:temphotfixname.msu /quiet /norestart" }
  10. }
  11. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement