User Tools

Site Tools


computing:windows:clear_event_logs

Clear All Windows Event Logs

:!: Run commands in elevated PowerShell.

PowerShell 1.0

wevtutil el | Foreach-Object {Write-Host "Clearing $_"; wevtutil cl "$_"}

PowerShell

:!: Ignore the error clearing the Debug logs.

Get-WinEvent -ListLog * -Force | % { Wevtutil.exe cl $_.logname }
computing/windows/clear_event_logs.txt · Last modified: 2016/10/14 11:18 by jcooper