meta data de esta página
Diferencias
Muestra las diferencias entre dos versiones de la página.
Ambos lados, revisión anteriorRevisión previaPróxima revisión | Revisión previa | ||
windows:wsus [2021/04/30 12:45] – lc | windows:wsus [2024/03/19 23:36] (actual) – [El equipo no aparece en el WSUS] lc | ||
---|---|---|---|
Línea 42: | Línea 42: | ||
* **ScanInstallWait** -> Combina escanear, descargar e instalar | * **ScanInstallWait** -> Combina escanear, descargar e instalar | ||
* **ResumeUpdate** -> | * **ResumeUpdate** -> | ||
+ | === Actualizar W10 con Powershell === | ||
+ | - Arrancamos powershell | ||
+ | - Instalamos el módulo -> Install-Module PSWindowsUpdate | ||
+ | - Get-Command -Module PSWindowsUpdate | ||
+ | - Ver las actualizaciones pendientes-> | ||
+ | - Instalar las actualizaciones -> Install-WindowsUpdate | ||
+ | - Install-WindowsUpdate -AcceptAll -AutoReboot | ||
+ | - Instalar un KB específico -> Get-WindowsUpdate -Install -KBArticleID ' | ||
+ | === Actualizar W10 con un script === | ||
+ | Creamos el siguiente script de powershell y lo llamamos actualizar.ps1 | ||
+ | <sxh> | ||
+ | $winVer = [System.Environment]:: | ||
+ | $dir = ' | ||
+ | mkdir $dir | ||
+ | |||
+ | if ($winVer -eq 10) | ||
+ | { | ||
+ | $webClient = New-Object System.Net.WebClient | ||
+ | $url = ' | ||
+ | $file = " | ||
+ | $webClient.DownloadFile($url, | ||
+ | Start-Process -FilePath $file -ArgumentList '/ | ||
+ | } | ||
+ | | ||
+ | else | ||
+ | |||
+ | { | ||
+ | echo "This is Not Windows10 OS " | ||
+ | } | ||
+ | | ||
+ | sleep 10 | ||
+ | |||
+ | Remove-Item " | ||
+ | </ | ||
+ | |||
+ | Ojo el link $url hay que cambiarlo según el upgrade que queramos instalar | ||
+ | |||
+ | Para ejecutarlo | ||
+ | powershell.exe -ExecutionPolicy Bypass ./ | ||
https:// | https:// | ||
+ | |||
+ | === Otro Script === | ||
+ | https:// | ||
+ | <sxh> | ||
+ | # *** THIS SCRIPT IS PROVIDED WITHOUT WARRANTY, USE AT YOUR OWN RISK *** | ||
+ | <# | ||
+ | |||
+ | .DESCRIPTION | ||
+ | Starts the Windows Update service (wuauserv) if it is stopped and forces a checkin | ||
+ | with the WSUS Server. This function uses the Invoke-Command CMDlet which | ||
+ | will require PSRemoting to be enabled on the target machine. | ||
+ | |||
+ | .NOTES | ||
+ | File Name: force-WSUScheckin.ps1 | ||
+ | Author: David Hall | ||
+ | Contact Info: | ||
+ | Website: www.signalwarrant.com | ||
+ | Twitter: @signalwarrant | ||
+ | Facebook: facebook.com/ | ||
+ | Google +: plus.google.com/ | ||
+ | YouTube Subscribe link: https:// | ||
+ | Requires: PowerShell Remoting Enabled (Enable-PSRemoting) | ||
+ | Tested: PowerShell Version 5 | ||
+ | |||
+ | .PARAMETER ComputerName | ||
+ | See the examples below, the computername can be one or | ||
+ | many computer names | ||
+ | |||
+ | .EXAMPLE | ||
+ | | ||
+ | | ||
+ | | ||
+ | | ||
+ | |||
+ | #> | ||
+ | [CmdletBinding()] | ||
+ | Param( | ||
+ | [Parameter(Mandatory=$True)] | ||
+ | [string[]]$ComputerName | ||
+ | |||
+ | ) | ||
+ | |||
+ | $service = get-service -Name wuauserv | ||
+ | |||
+ | # Check to see if the wuauserv service is stopped | ||
+ | if ($service.Status -eq " | ||
+ | |||
+ | # If the service is stopped we're going to start it and force WSUS checkin | ||
+ | # then Exit | ||
+ | Write-verbose "1. WUAUSERV is stopped... starting" | ||
+ | Invoke-Command -ComputerName $ComputerName -scriptblock {Start-Service wuauserv} | ||
+ | [System.Threading.Thread]:: | ||
+ | |||
+ | Write-verbose "2. Forcing WSUS Checkin" | ||
+ | Invoke-Command -ComputerName $ComputerName -scriptblock {wuauclt.exe /detectnow} | ||
+ | [System.Threading.Thread]:: | ||
+ | |||
+ | Write-verbose "3. Checkin Complete" | ||
+ | Exit | ||
+ | |||
+ | } else { | ||
+ | |||
+ | # If the service is started we'll just force the WSUS checkin and Exit | ||
+ | Write-verbose "1. Forcing WSUS Checkin" | ||
+ | Invoke-Command -ComputerName $ComputerName -scriptblock {wuauclt.exe /detectnow} | ||
+ | [System.Threading.Thread]:: | ||
+ | |||
+ | Write-Verbose "2. Checkin Complete" | ||
+ | Exit | ||
+ | |||
+ | } | ||
+ | </ | ||
+ | |||
+ | |||
+ | === Forzar la sincronización con WSUS === | ||
+ | Ejecutar desde powershell en el equipo ccon problemas | ||
+ | $updateSession = new-object -com " | ||
+ | |||
+ | Forzar la sincronización mediante un script | ||
+ | <sxh> | ||
+ | Function Force-WSUSCheckin($Computer) | ||
+ | { | ||
+ | | ||
+ | # Have to use psexec with the -s parameter as otherwise we receive an " | ||
+ | $Cmd = ' | ||
+ | & | ||
+ | | ||
+ | | ||
+ | | ||
+ | { | ||
+ | # Now that the system is told it CAN report in, run every permutation of commands to actually trigger the report in operation | ||
+ | wuauclt /detectnow | ||
+ | (New-Object -ComObject Microsoft.Update.AutoUpdate).DetectNow() | ||
+ | wuauclt /reportnow | ||
+ | c: | ||
+ | } | ||
+ | } | ||
+ | </ | ||
+ | |||
+ | https:// | ||
==== Problemas WSUS y XP ==== | ==== Problemas WSUS y XP ==== | ||
Línea 73: | Línea 212: | ||
==== El equipo no aparece en el WSUS ==== | ==== El equipo no aparece en el WSUS ==== | ||
- | ==== No aparecen máquinas en el WSUS ==== | ||
Podemos abrir un terminal y ejecutar el wuauclt.exe con alguna de estas opciones: | Podemos abrir un terminal y ejecutar el wuauclt.exe con alguna de estas opciones: | ||
* / | * / | ||
Línea 91: | Línea 229: | ||
* / | * / | ||
* / | * / | ||
+ | |||
+ | Por ejemplo para actualizar la conexión de la estación al servidor de wsus < | ||
+ | |||
== Referencias == | == Referencias == | ||
Línea 96: | Línea 237: | ||
* http:// | * http:// | ||
* http:// | * http:// | ||
+ | |||
+ | ==== Otros problemas ==== | ||
+ | |||
+ | * https:// | ||
+ | * https:// | ||
+ | * https:// | ||
+ | * forzar el chequeo -> https:// | ||
+ | |||
+ | ==== Error 7053 ==== | ||
+ | * https:// | ||
+ | * https:// | ||
+ | |||
+ | |||
+ | |||
+ | |||
==== Parches fuera de ciclo ==== | ==== Parches fuera de ciclo ==== | ||
Línea 104: | Línea 260: | ||
==== Referencias ==== | ==== Referencias ==== | ||
* http:// | * http:// | ||
- | * Lista comandos netsh http:// | + | * Lista comandos netsh-> http:// |
* http:// | * http:// | ||
* https:// | * https:// | ||
+ | * https:// | ||
+ | * https:// | ||
+ | * https:// | ||
+ | * https:// | ||
+ | * http:// | ||
+ | * https:// | ||
+ | * https:// | ||
+ | * https:// | ||
+ | * https:// | ||
+ | * https:// |