Trying to generate a list of all warnings and errors within a specified time and dates
i trying generate errors , warnings specific time , date specific time , date, kind of stuck... got far, not seem work... can help?
get-winevent application | where-object {$_.datetime -gt "2/25/2014 6:00:00 am"} | ?{$_.leveldisplayname -eq "error" -or $_.leveldisplayname -eq "warning"}
hi gramelot,
to filter event log, can try parameter -filterhashtable, like:
get-winevent -filterhashtable @{logname='application';id=4107;starttime="1/15/11";endtime="1/17/11"}
for more detailed information, please refer article:
use powershell cmdlet filter event log easy parsing
i hope helps.
Windows Server > Windows PowerShell
Comments
Post a Comment