<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en-GB">
	<id>http://piszczynski.com/index.php?action=history&amp;feed=atom&amp;title=Eventviewer</id>
	<title>Eventviewer - Revision history</title>
	<link rel="self" type="application/atom+xml" href="http://piszczynski.com/index.php?action=history&amp;feed=atom&amp;title=Eventviewer"/>
	<link rel="alternate" type="text/html" href="http://piszczynski.com/index.php?title=Eventviewer&amp;action=history"/>
	<updated>2026-10-27T14:14:23Z</updated>
	<subtitle>Revision history for this page on the wiki</subtitle>
	<generator>MediaWiki 1.40.1</generator>
	<entry>
		<id>http://piszczynski.com/index.php?title=Eventviewer&amp;diff=1112&amp;oldid=prev</id>
		<title>Aleks: /* Search Through Event Logs With Powershell */</title>
		<link rel="alternate" type="text/html" href="http://piszczynski.com/index.php?title=Eventviewer&amp;diff=1112&amp;oldid=prev"/>
		<updated>2025-02-03T15:09:35Z</updated>

		<summary type="html">&lt;p&gt;&lt;span dir=&quot;auto&quot;&gt;&lt;span class=&quot;autocomment&quot;&gt;Search Through Event Logs With Powershell&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;table style=&quot;background-color: #fff; color: #202122;&quot; data-mw=&quot;interface&quot;&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;col class=&quot;diff-marker&quot; /&gt;
				&lt;col class=&quot;diff-content&quot; /&gt;
				&lt;tr class=&quot;diff-title&quot; lang=&quot;en-GB&quot;&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;← Older revision&lt;/td&gt;
				&lt;td colspan=&quot;2&quot; style=&quot;background-color: #fff; color: #202122; text-align: center;&quot;&gt;Revision as of 16:09, 3 February 2025&lt;/td&gt;
				&lt;/tr&gt;&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot; id=&quot;mw-diff-left-l17&quot;&gt;Line 17:&lt;/td&gt;
&lt;td colspan=&quot;2&quot; class=&quot;diff-lineno&quot;&gt;Line 17:&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;#Find Specific Text in message&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;#Find Specific Text in message&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Get-WinEvent -FilterHashtable @{logname=&amp;#039;System&amp;#039;}|Where {$_.Message -like &amp;quot;*USB*&amp;quot;}&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;Get-WinEvent -FilterHashtable @{logname=&amp;#039;System&amp;#039;}|Where {$_.Message -like &amp;quot;*USB*&amp;quot;}&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;#Get Events from Remote computers&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;$servers = @(&quot;server1&quot;,&quot;Server2&quot;)&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td colspan=&quot;2&quot; class=&quot;diff-side-deleted&quot;&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot; data-marker=&quot;+&quot;&gt;&lt;/td&gt;&lt;td style=&quot;color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #a3d3ff; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&lt;ins style=&quot;font-weight: bold; text-decoration: none;&quot;&gt;$servers | foreach-object {Get-WinEvent -ComputerName $_ -FilterHashtable @{logname=&quot;Microsoft-Windows-TerminalServices-LocalSessionManager/Operational&quot;} | Where-Object {$_.Message -like &quot;*&amp;lt;username&gt;*&quot;}}&lt;/ins&gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;tr&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;/syntaxhighlight&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;td class=&quot;diff-marker&quot;&gt;&lt;/td&gt;&lt;td style=&quot;background-color: #f8f9fa; color: #202122; font-size: 88%; border-style: solid; border-width: 1px 1px 1px 4px; border-radius: 0.33em; border-color: #eaecf0; vertical-align: top; white-space: pre-wrap;&quot;&gt;&lt;div&gt;&amp;lt;/syntaxhighlight&amp;gt;&lt;/div&gt;&lt;/td&gt;&lt;/tr&gt;
&lt;/table&gt;</summary>
		<author><name>Aleks</name></author>
	</entry>
	<entry>
		<id>http://piszczynski.com/index.php?title=Eventviewer&amp;diff=1111&amp;oldid=prev</id>
		<title>Aleks: Created page with &quot;== Search Through Event Logs With Powershell == Search through event logs using Get-WinEvent: [https://woshub.com/search-windows-event-logs-powershell/ Reference]&lt;syntaxhighlight lang=&quot;powershell&quot;&gt;  #Get full list of event log names to use in filters: Get-WinEvent -ListLog *  #Get events from multiple logs in a time period (last day) $StartDate = (Get-Date) - (New-TimeSpan -Day 1) Get-WinEvent Application,System | Where-Object {($_.LevelDisplayName -eq &quot;Error&quot; -or $_.Lev...&quot;</title>
		<link rel="alternate" type="text/html" href="http://piszczynski.com/index.php?title=Eventviewer&amp;diff=1111&amp;oldid=prev"/>
		<updated>2025-02-03T15:06:12Z</updated>

		<summary type="html">&lt;p&gt;Created page with &amp;quot;== Search Through Event Logs With Powershell == Search through event logs using Get-WinEvent: [https://woshub.com/search-windows-event-logs-powershell/ Reference]&amp;lt;syntaxhighlight lang=&amp;quot;powershell&amp;quot;&amp;gt;  #Get full list of event log names to use in filters: Get-WinEvent -ListLog *  #Get events from multiple logs in a time period (last day) $StartDate = (Get-Date) - (New-TimeSpan -Day 1) Get-WinEvent Application,System | Where-Object {($_.LevelDisplayName -eq &amp;quot;Error&amp;quot; -or $_.Lev...&amp;quot;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;New page&lt;/b&gt;&lt;/p&gt;&lt;div&gt;== Search Through Event Logs With Powershell ==&lt;br /&gt;
Search through event logs using Get-WinEvent: [https://woshub.com/search-windows-event-logs-powershell/ Reference]&amp;lt;syntaxhighlight lang=&amp;quot;powershell&amp;quot;&amp;gt;&lt;br /&gt;
&lt;br /&gt;
#Get full list of event log names to use in filters:&lt;br /&gt;
Get-WinEvent -ListLog *&lt;br /&gt;
&lt;br /&gt;
#Get events from multiple logs in a time period (last day)&lt;br /&gt;
$StartDate = (Get-Date) - (New-TimeSpan -Day 1)&lt;br /&gt;
Get-WinEvent Application,System | Where-Object {($_.LevelDisplayName -eq &amp;quot;Error&amp;quot; -or $_.LevelDisplayName -eq &amp;quot;Warning&amp;quot;) -and ($_.TimeCreated -ge $StartDate )}&lt;br /&gt;
&lt;br /&gt;
#Search for events in a specific time period&lt;br /&gt;
Get-winevent -filterhashtable @{logname=&amp;quot;Microsoft-Windows-TerminalServices-SessionBroker/Operational&amp;quot;; starttime=&amp;quot;12:20pm&amp;quot;; EndTime=&amp;quot;12:25pm&amp;quot;} | Where-Object {$_.Message -like &amp;quot;*&amp;lt;username&amp;gt;*&amp;quot;}&lt;br /&gt;
&lt;br /&gt;
#Find Events by ID&lt;br /&gt;
Get-WinEvent -FilterHashtable @{logname=&amp;#039;System&amp;#039;;id=1074}|ft TimeCreated,Id,Message&lt;br /&gt;
&lt;br /&gt;
#Find Specific Text in message&lt;br /&gt;
Get-WinEvent -FilterHashtable @{logname=&amp;#039;System&amp;#039;}|Where {$_.Message -like &amp;quot;*USB*&amp;quot;}&lt;br /&gt;
&amp;lt;/syntaxhighlight&amp;gt;&lt;/div&gt;</summary>
		<author><name>Aleks</name></author>
	</entry>
</feed>