Powershell Tip #96: Clear all event logs

By | April 23, 2016

Tip: You can clear all the events logs (Windows Logs + Application and Services Logs)


The solution 1 is faster than the solution 2.

I clear all the event logs and created 500 000 events on Application, System and Windows Powershell logs.

Solution 1 (GlobalSession.ClearLog) : 0.64 seconds
Solution 2 (wevtutil) : 4.6 seconds


Leave a Reply

Your email address will not be published.