Is there a way to search all the event-logs on a LAN for a specifc event?
Asked
Active
Viewed 209 times
2 Answers
3
You could broadcast the Windows event log events to a syslog server using a tool like the Eventlog to Syslog Service utility or a software like EventLog Inspector.

splattne
- 28,508
- 20
- 98
- 148
-
This is the way to go if you have more than a few machines. Centralize that data and searching! – Joe Doyle Apr 30 '09 at 15:14
0
You can search the event log on remote machines with PowerShell, using System.Diagnostics.EventLog
. Assuming the event you're looking for is in the System log...
# get a list of all server names, maybe from AD, we'll assume it's in a variable called $serverlist
$eventIdToFind = "1234" # or whatever ID you're looking for
$logToSearch = "System"
foreach ($aServer in $serverlist) {
$theLog = New-Object System.Diagnostics.EventLog($logToSearch, $aServer)
$matchingEventList = $theLog.Entries | where { $_.EventId -eq $eventToFind }
if ($null -ne $machingEventList -and $matchingEventList.Count -gt 0) {
"Event Found on $aServer" # or do something else with it here
}
}

Abs
- 320
- 3
- 8