I've taken it to mean a Debug / Analytic log, and as such my "entry" follows:
Get-WinEvent -ListLog * -Force -EA 0 | Where-Object {($_.IsEnabled -eq $true) -and ($_.RecordCount)} | Sort-Object RecordCount -Descending | Format-Table -Property "LogName","RecordCount" -AutoSize -Wrap
Time to check the expert blog...
UPDATE:
It would appear I didn't need the "-Force" according to the expert, and also I could loose the "-eq $true" from my Where-Object clause (as IsEnabled is already a boolean.)
No comments:
Post a Comment