Author Topic: Reset the Reliability Monitor and Clear the Event Log Completely!  (Read 6970 times)

0 Members and 1 Guest are viewing this topic.

Offline cvscorp

  • Newbie
  • *
  • Join Date: Feb 2013
  • Posts: 9
  • Karma: 1
    • View Profile
Hello

I thought I would share this command script as it has no harmful affects on a users system.  It clears and resets the Reliability Monitor (and the event log).

Clearing the event log on any Server product also clears the Windows Backup Log, so if you want to keep the backup history, you need to temporarally remove or archive those logs and events by exporting them.

Put everthing below into a .cmd command script and run it locally. I keep it in my C:\GodMode directory.
--------------------------------------------------------------------------------------------------------------------
reg add "HKLM\SOFTWARE\Microsoft\Reliability Analysis\WMI /v WMIEnable /T REG_DWORD /D 00000001 /F"
del /f /S /Q /A "%ProgramData%\Microsoft\RAC\PublishedData\*"
del /f /S /Q /A "%ProgramData%\Microsoft\RAC\StateData\*"
@echo off
FOR /F "tokens=1,2*" %%V IN ('bcdedit') DO SET adminTest=%%V
IF (%adminTest%)==(Access) goto noAdmin
for /F "tokens=*" %%G in ('wevtutil.exe el') DO (call :do_clear "%%G")
echo.
echo goto theEnd
:do_clear
echo clearing %1
wevtutil.exe cl %1
goto :eof
:noAdmin
exit
--------------------------------------------------------------------------------------------------------------------
I use it to clear an event log (resetting it to no events) and rebooting to see what "noise" the system makes on initial bootup. Clearing and/or resolving these event errors seem to make any system run smoother, and it's nice to see a reliable reliability monitor.

If you code in batch, you can modify it to your liking. I assume no responsibility on your use of batch scripts you can't read or understand.

Enjoy.  :artist:
« Last Edit: February 24, 2013, 10:06:25 AM by cvscorp »

Offline Shane

  • Top Geek, err uh Dog.
  • Administrator
  • Hero Member
  • *****
  • Join Date: Sep 2011
  • Posts: 9274
  • Location: USA
  • Karma: 136
  • "Knowledge should be shared not hidden."
    • View Profile
    • Tweaking.com
Re: Reset the Reliability Monitor and Clear the Event Log Completely!
« Reply #1 on: February 25, 2013, 11:15:15 AM »
I moved this to "User Submitted Tweaks & Guides"

This will be helpful for people who need it :wink:

Shane
PLEASE EDIT YOUR TOPIC AND PUT (SOLVED) IF YOU ARE ALL FIXED.

(My weekends belong to my wife and kids, I will try my best to answer all posts daily during the work week)

(About Shane)
Site Owner, Top Admin, Lead Programmer, Wife & 5 kids, Needs a lot more coffee.

When people ask "Why fix what isn't broken?" I reply "To make it better."
"Only a life lived for others is a life worthwhile"
Honor & Respect is all that matters.

Owner & Programmer of: www.pcwintech.com & www.tweaking.com

Offline acclude

  • Newbie
  • *
  • Join Date: Mar 2013
  • Posts: 15
  • Location: Maryland
  • Karma: 1
  • Destructionator
    • View Profile
Re: Reset the Reliability Monitor and Clear the Event Log Completely!
« Reply #2 on: March 17, 2013, 08:06:56 AM »
cvscorp - any issues with me plagiarizing your work and making it into an Advanced Systems Tweaker Add-on? I'd give you credit for it within the add-on.
I'm new to Tweaking.com but very experienced with computers and networks since the early 90's.