Fixing Broken WSUS Clients
In the last post i showed you how to find WSUS client that were not working properly.
There are a few things that you can do to fix those clients.
1. Try and repair the client
2. Update the client to the newest version
First create a package and advertise this bat file to the broken clients (Machines that Failed to run the scan)
In my experience this works 90% of the time.
FixWSUS.bat
@echo off
net stop wuauserv /Y
net stop bits /Y
net stop cryptsvc /Y
REM Rename and Delete dircetories
rd /s /Q %SystemRoot%\SoftwareDistribution
ren %systemroot%\System32\Catroot2 Catroot2.old
Rem Change Directory to System 32
CD /D %SystemRoot%\System32
Rem Reregister files
regsvr32 Actxprxy.dll /s
regsvr32 Atl.dll /S
regsvr32 Browseui.dll /s
regsvr32 cryptdlg.dll /s
regsvr32 dssenh.dll /s
regsvr32 gpkcsp.dll /s
regsvr32 initpki.dll /s
regsvr32 jscript.dll /s
regsvr32 Mshtml.dll /s
regsvr32 Msjava.dll /s
regsvr32 Mssip32.dll /s
regsvr32 msxml.dll /s
regsvr32 msxml2.dll /s
regsvr32 Msxml3.dll /s
regsvr32 Oleaut32.dll /s
regsvr32 rsaenh.dll /s
regsvr32 sccbase.dll /s
regsvr32 shdocvw.dll /s
regsvr32 shell32.dll /s
regsvr32 slbcsp.dll /s
regsvr32 softpub.dll /s
regsvr32 Urlmon.dll /s
regsvr32 vbscript.dll /s
regsvr32 wintrust.dll /s
regsvr32 wuapi.dll /s
regsvr32 wuaueng.dll /s
regsvr32 wuaueng1.dll /s
regsvr32 wucltui.dll /s
regsvr32 wups.dll /s
regsvr32 wups2.dll /s
regsvr32 wuweb.dll /s
Rem Turn services back on
net start wuauserv
net start bits
net start cryptsvc
exit
Those that are not fixed by this should be updated to the latest client.
I actually have another collection and advertisement for that, because we update all the clients anyway.
Collection query:
ABC- WSUS Client need upgraded to 7.2.6001.788
select SMS_R_SYSTEM.ResourceID,SMS_R_SYSTEM.ResourceType,SMS_R_SYSTEM.Name,SMS_R_SYSTEM.SMSUniqueIdentifier,SMS_R_SYSTEM.ResourceDomainORWorkgroup,SMS_R_SYSTEM.Client from SMS_R_System inner join SMS_G_System_WINDOWSUPDATEAGENTVERSION on SMS_G_System_WINDOWSUPDATEAGENTVERSION.ResourceId = SMS_R_System.ResourceId where SMS_G_System_WINDOWSUPDATEAGENTVERSION.Version not like "7.2.6001.788" and SMS_R_System.Client = 1
Create an package with this commandline and these files
SCCM package Commandline needed:
WindowsUpdateAgent30-x86_726001788.exe /WUForce /quiet /norestart
if you are adding this to your OSD deployment the switches are:
WindowsUpdateAgent30-x86_726001788.exe /quiet /norestart
The three current links are:
x86:
http://download.windowsupdate.com/windowsupdate/redist/standalone/7.2.6001.788/windowsupdateagent30-x86.exe
x64:
http://download.windowsupdate.com/windowsupdate/redist/standalone/7.2.6001.788/windowsupdateagent30-x64.exe
Itanium:
http://download.windowsupdate.com/windowsupdate/redist/standalone/7.2.6001.788/windowsupdateagent30-ia64.exe