Problems with WSUS Cleanup on SBS

I am trying to cleanup WSUS on SBS 2008. I have been trying to use the Server Cleanup Wizard located in the Server Manager. I chose all cleanup options exc ept the first one that says Clean upUnused updates and revision updates I I was able to get the 4 sections cleaned up.

I have read that The Unused updates section takes a while to run and if it crashes, that isn't unusual just rerun it. I have run this wizard over 12 times. Each time it crashes between 10 and 15 hours into the process. My WSUS database folder is over 130 Gb in size and I need to clean it up.

What should I be doing? Am I missing something?
LVL 1
LostInWindowsAsked:
Who is Participating?

[Product update] Infrastructure Analysis Tool is now available with Business Accounts.Learn More

x
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

Thomas GrassiSystems AdministratorCommented:
Hi

Try running this from command line

I use this script run once a week

@echo off
del c:\util\cleanup_history.txt

rem c:\util\wsus_cleanup_cl server f 80 all    removed 2/22/2013
c:\util\wsus_cleanup_cl server f 80 superseded expired obsolete compress computers files


if you have a batch email client you can send an email to your self here
exit
Rodney BarnhardtServer AdministratorCommented:
You could try to do it manually per these instructions:

https://www.3ait.co.uk/blog/solved-shrink-a-wsus-database-susdb-mdb-to-almost-nothing-2/

However, does the cleanup provide additional space each time  you run it? Does it seem to be working even though it crashes?
Randy DownsOWNERCommented:
There may be something helpful in this thread.

There was a similar question on EE last week where it took the author 6 times to get the clean up wizard to finally complete.  Each of the 5 previous times he had the time out and error message.  They only had an 11GB database.  Sounds like yours has the all languages switch enabled.  Usually each time it runs it is doing some cleanup, but due to size times out.

The following article may be of some help in troubleshooting:
http://blogs.technet.com/b/sus/archive/2008/10/20/wsus-updates-page-times-out-while-trying-to-view-or-approve-updates.aspx
The 7 Worst Nightmares of a Sysadmin

Fear not! To defend your business’ IT systems we’re going to shine a light on the seven most sinister terrors that haunt sysadmins. That way you can be sure there’s nothing in your stack waiting to go bump in the night.

LostInWindowsAuthor Commented:
@trgrassijr55
Your post seems incomplete. There isn't any file on my server called wsus_cleanup_cl
What are the scripts that wsus_cleanup_cl runs?
Thomas GrassiSystems AdministratorCommented:
Lostin

Oops my bad

you need to download that exe file

check this out
http://wsus.codeplex.com/releases/view/17612
LostInWindowsAuthor Commented:
Thanks,that makes it easier.  :-)
LostInWindowsAuthor Commented:
I finally called Microsoft and opened a case. Here is what they did:
>>Followed article -https://technet.microsoft.com/en-us/library/dd939795(v=ws.10) to re index WSUS database.

>>Browsed  C:\Program Files\Microsoft SQL Server\100\Tools\Binn and copied script as  WsusDBMaintenance.sql  (https://gallery.technet.microsoft.com/scriptcenter/6f8cde49-5c52-4abd-9820-f1d270ddea61)

>>browsed  C:\Program Files\Microsoft SQL Server\100\Tools\Binn in cmd prompt and run the below cmd

 C:\Program Files\Microsoft SQL Server\100\Tools\Binn\sqlcmd -I -i WsusDBMaintenance.sql -S \\.\pipe\MSSQL$MICROSOFT##SSEE\sql\query > reindex.txt

>>Ran the wsus removal script.

>>Rebooted the server.

>>Tried to install wsus 3.0 SP(http://www.microsoft.com/en-us/download/details.aspx?id=5216) got error " install windows installer 3.1 or higher version.

>>Ran sfc /scannow but no errors reported.

>>Ran checksur and it did not report any error.

>>Checked hklm\Software\Microsoft\Windows\CurrentVersion\Installer and compared the entries with working machine and found many entries missing on customer’s server.

>>Exported registry from working machine.

>>Installed wsus 3.0 Sp2  (http://www.microsoft.com/en-us/download/details.aspx?id=5216)

>>installed update for wsus 3.0 Sp2 (https://support.microsoft.com/en-us/kb/2734608)

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
LostInWindowsAuthor Commented:
I now consider this case resolved
Thomas GrassiSystems AdministratorCommented:
I still think that you should use my suggestion from this point forward so you do not run into this issue again.

Gave you the batch file and the link to the software
LostInWindowsAuthor Commented:
Thomas - I did try it but it did not work. I will use it monthly going forward. Thank you for the reminder.
Thomas GrassiSystems AdministratorCommented:
You should do it weekly
I have a small network here and was doing it monthly first and it failed sometimes because of so many updates after I changed it to weekly have not had a problem

Just a thought


Yes I know it did not fix the issue your db was corrupt that's why ms did what they did
LostInWindowsAuthor Commented:
I asked Microsft how to fix it. What they did is in the discussion.
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
SBS

From novice to tech pro — start learning today.