meta data de esta página
  •  

Diferencias

Muestra las diferencias entre dos versiones de la página.

Enlace a la vista de comparación

Ambos lados, revisión anteriorRevisión previa
Próxima revisión
Revisión previa
windows:wsus [2021/06/18 13:47] – [Referencias] lcwindows:wsus [2024/03/19 23:36] (actual) – [El equipo no aparece en el WSUS] lc
Línea 84: Línea 84:
  
 https://www.urtech.ca/2018/11/solved-easily-script-windows-10-to-download-install-and-restart-for-windows-updates/ https://www.urtech.ca/2018/11/solved-easily-script-windows-10-to-download-install-and-restart-for-windows-updates/
 +
 +=== Otro Script ===
 +https://www.signalwarrant.com/force-wsus-checkin-with-powershell-2/
 +<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/signalwarrant/
 + Google +: plus.google.com/113307879414407675617
 + YouTube Subscribe link: https://www.youtube.com/channel/UCgWfCzNeAPmPq_1lRQ64JtQ?sub_confirmation=1
 + 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
 +     .\force-WSUScheckin.ps1 -ComputerName CL1
 +     .\force-WSUScheckin.ps1 -ComputerName CL1 -verbose
 +     .\force-WSUScheckin.ps1 -ComputerName CL1, CL2 -verbose
 +     .\force-WSUScheckin.ps1 -ComputerName (Get-Content -Path "C:\computers.txt") -verbose
 +
 +#>
 +[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 "Stopped"){
 +
 +# 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]::Sleep(3000)
 +
 +Write-verbose "2. Forcing WSUS Checkin"
 +Invoke-Command -ComputerName $ComputerName -scriptblock {wuauclt.exe /detectnow}
 +[System.Threading.Thread]::Sleep(1500)
 +
 +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]::Sleep(1500)
 +
 +Write-Verbose "2. Checkin Complete"
 +Exit
 +
 +}
 +</sxh>
 +
 +
 +=== Forzar la sincronización con WSUS ===
 +Ejecutar desde powershell en el equipo ccon problemas  -> <sxh>
 +$updateSession = new-object -com "Microsoft.Update.Session"; $updates=$updateSession.CreateupdateSearcher().Search($criteria).Updates</sxh>
 +
 +Forzar la sincronización mediante un script 
 +<sxh>
 +Function Force-WSUSCheckin($Computer)
 +{
 +   Invoke-Command -computername $Computer -scriptblock { Start-Service wuauserv -Verbose }
 +   # Have to use psexec with the -s parameter as otherwise we receive an "Access denied" message loading the comobject
 +   $Cmd = '$updateSession = new-object -com "Microsoft.Update.Session";$updates=$updateSession.CreateupdateSearcher().Search($criteria).Updates'
 +   &amp; c:\bin\psexec.exe -s \\$Computer powershell.exe -command $Cmd
 +   Write-host "Waiting 10 seconds for SyncUpdates webservice to complete to add to the wuauserv queue so that it can be reported on"
 +   Start-sleep -seconds 10
 +   Invoke-Command -computername $Computer -scriptblock
 +   {
 +      # 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:\windows\system32\UsoClient.exe startscan
 +   }
 +}
 +</sxh>
 +
 +https://pleasework.robbievance.net/howto-force-really-wsus-clients-to-check-in-on-demand/
 ==== Problemas WSUS y XP ==== ==== Problemas WSUS y XP ====
  
Línea 112: 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:
   *     /ResetAuthorization /DetectNow (o /a /d)   *     /ResetAuthorization /DetectNow (o /a /d)
Línea 130: Línea 229:
   *     /ShowSettingsDialog   *     /ShowSettingsDialog
   *     /RunHandlerComServer   *     /RunHandlerComServer
 +
 +Por ejemplo para actualizar la conexión de la estación al servidor de wsus <sxh>wuauclt.exe /resetauthorization /detectnow</sxh>
 +
  
 == Referencias == == Referencias ==
Línea 135: Línea 237:
   * http://gonsystem.blogspot.com.es/search/label/Microsoft%20Windows%20Wsus   * http://gonsystem.blogspot.com.es/search/label/Microsoft%20Windows%20Wsus
   * http://pauby.com/blog/windows-update-agent-utility-wuauclt-exe/   * http://pauby.com/blog/windows-update-agent-utility-wuauclt-exe/
 +
 +==== Otros problemas ====
 +
 +  * https://techcommunity.microsoft.com/t5/configuration-manager-archive/recreating-the-susdb-and-wsus-content-folder-for-a-windows/ba-p/274122
 +  * https://michlstechblog.info/blog/windows-reset-wsus-and-recreate-susdb/
 +  * https://www.cenabit.com/2018/08/mover-los-parches-de-wsus-a-otro-disco/
 +  * forzar el chequeo -> https://pleasework.robbievance.net/howto-force-really-wsus-clients-to-check-in-on-demand/
 +
 +==== Error 7053 ====
 +  * https://www.wincert.net/windows-server/wsus-error-connection-error-event-id7053/
 +  * https://elcegu.wordpress.com/2017/06/08/windows-server-2012r2-wsus-y-el-error-7053-system-nullreferenceexception/
 +
 +
 +
 +
  
 ==== Parches fuera de ciclo ==== ==== Parches fuera de ciclo ====
Línea 143: Línea 260:
 ==== Referencias ==== ==== Referencias ====
   * http://social.technet.microsoft.com/Forums/windowsserver/en-US/f3fb4c50-4fa5-42a1-9ee6-f77c273233ba/wsus-30-xp-clients-not-updating-automatically-servers-updating-ok?forum=winserverwsus   * http://social.technet.microsoft.com/Forums/windowsserver/en-US/f3fb4c50-4fa5-42a1-9ee6-f77c273233ba/wsus-30-xp-clients-not-updating-automatically-servers-updating-ok?forum=winserverwsus
-  * Lista comandos netsh http://support.microsoft.com/kb/242468/es+  * Lista comandos netsh-> http://support.microsoft.com/kb/242468/es
   * http://www.sysadmit.com/2013/12/windows-update-solucionar-problemas.html   * http://www.sysadmit.com/2013/12/windows-update-solucionar-problemas.html
   * https://bloginspanish.wordpress.com/2016/06/18/wsus-usarlo-sin-dominio-y-algunos-consejos/   * https://bloginspanish.wordpress.com/2016/06/18/wsus-usarlo-sin-dominio-y-algunos-consejos/
Línea 154: Línea 271:
   * https://pureinfotech.com/install-windows-10-update-powershell/   * https://pureinfotech.com/install-windows-10-update-powershell/
   * https://raymii.org/s/blog/Windows_10_Updates_with_PowerShell_PSWindowsUpdpate.html   * https://raymii.org/s/blog/Windows_10_Updates_with_PowerShell_PSWindowsUpdpate.html
 +  * https://www.ajtek.ca/wsus/client-machines-not-reporting-to-wsus-properly/
 +  * https://blog.ragasys.es/instalacion-y-configuracion-de-wsus-en-ms-windows-server-2019