You can collect 20 most recent Windows Event logs in system category with below script:
import os;
syslogs=os.popen(‘wevtutil qe System /f:text /c:20 /rd:True’).read()
print(syslogs);
Example output would be:
You can collect 20 most recent Windows Event logs in system category with below script:
import os;
syslogs=os.popen(‘wevtutil qe System /f:text /c:20 /rd:True’).read()
print(syslogs);
Example output would be:
Thanks for all the event log scripts, I was working on one in powershell but this may do what I need. I will have to do some testing
Whatever scripts you need, pls tell us, we’ll be more than happy to write it for you.