π‘ Asking Find-Events for multiple reports
There's one more thing you should know. It's much faster to ask for events once, and then filter it out, then question 5 times separately.
Import-Module .\PSWinReportingV2.psd1 -Force
$Reports = @(
'ADUserChanges'
'ADUserChangesDetailed'
'ADComputerChangesDetailed'
'ADUserStatus'
'ADUserLockouts'
#ADUserLogon
'ADUserUnlocked'
'ADComputerCreatedChanged'
'ADComputerDeleted'
#'ADUserLogonKerberos'
'ADGroupMembershipChanges'
'ADGroupEnumeration'
'ADGroupChanges'
'ADGroupCreateDelete'
'ADGroupChangesDetailed'
'ADGroupPolicyChanges'
'ADLogsClearedSecurity'
'ADLogsClearedOther'
#ADEventsReboots
)
$Events = Find-Events -Report $Reports -DatesRange Last3days -Servers 'AD1', 'AD2' -Verbose
[Info] Preparing reports: ADUserChanges,ADUserChangesDetailed,ADComputerChangesDetailed,ADUserStatus,ADUserLockouts,ADUserUnlocked,ADComputerCreatedChanged,ADComputerDeleted,ADGroupMembershipChanges,ADGroupEnumeration,ADGroupChanges,ADGroupCreateDelete,ADGroupChangesDetailed,ADGroupPolicyChanges,ADLogsClearedSecurity,ADLogsClearedOther
[Info] Preparing servers list - defined list
[Info] Computer AD1 added to scan Security log for events: 1102, 1105, 4720, 4722, 4723, 4724, 4725, 4726, 4727, 4728, 4729, 4730, 4731, 4732, 4733, 4734, 4735, 4737, 4738, 4740, 4741, 4742, 4743, 4744, 4745, 4746, 4747, 4748, 4749, 4750, 4751, 4752, 4753, 4754, 4756, 4757, 4758, 4759, 4760, 4761, 4762, 4763, 4764, 4767, 4784, 4785, 4786, 4787, 4788, 4791, 4798, 4799, 5136, 5137, 5141
[Info] Computer AD2 added to scan Security log for events: 1102, 1105, 4720, 4722, 4723, 4724, 4725, 4726, 4727, 4728, 4729, 4730, 4731, 4732, 4733, 4734, 4735, 4737, 4738, 4740, 4741, 4742, 4743, 4744, 4745, 4746, 4747, 4748, 4749, 4750, 4751, 4752, 4753, 4754, 4756, 4757, 4758, 4759, 4760, 4761, 4762, 4763, 4764, 4767, 4784, 4785, 4786, 4787, 4788, 4791, 4798, 4799, 5136, 5137, 5141
[Info] Computer AD1 added to scan System log for events: 104
[Info] Computer AD2 added to scan System log for events: 104
[Info] Getting events for dates 04/25/2019 00:00:00 to 04/28/2019 23:59:59
VERBOSE: Get-Events - Preparing data to scan computer AD1
VERBOSE: Get-Events - Filter parameters provided EndTime = 04/28/2019 23:59:59
VERBOSE: Get-Events - Filter parameters provided LogName = Security
VERBOSE: Get-Events - Filter parameters provided StartTime = 04/25/2019 00:00:00
VERBOSE: Get-Events - Events to process in Total (unique): 55
VERBOSE: Get-Events - Events to process in Total ID: 1102, 1105, 4720, 4722, 4723, 4724, 4725, 4726, 4727, 4728, 4729, 4730, 4731, 4732, 4733, 4734, 4735, 4737, 4738, 4740, 4741, 4742, 4743, 4744, 4745, 4746, 4747, 4748, 4749, 4750, 4751, 4752, 4753, 4754, 4756, 4757, 4758, 4759, 4760, 4761, 4762, 4763, 4764, 4767, 4784, 4785, 4786, 4787, 4788, 4791, 4798, 4799, 5136, 5137, 5141
VERBOSE: Get-Events - There are more events to process then 22, split will be required.
VERBOSE: Get-Events - Preparing data to scan computer AD2
VERBOSE: Get-Events - Filter parameters provided EndTime = 04/28/2019 23:59:59
VERBOSE: Get-Events - Filter parameters provided LogName = Security
VERBOSE: Get-Events - Filter parameters provided StartTime = 04/25/2019 00:00:00
VERBOSE: Get-Events - Events to process in Total (unique): 55
VERBOSE: Get-Events - Events to process in Total ID: 1102, 1105, 4720, 4722, 4723, 4724, 4725, 4726, 4727, 4728, 4729, 4730, 4731, 4732, 4733, 4734, 4735, 4737, 4738, 4740, 4741, 4742, 4743, 4744, 4745, 4746, 4747, 4748, 4749, 4750, 4751, 4752, 4753, 4754, 4756, 4757, 4758, 4759, 4760, 4761, 4762, 4763, 4764, 4767, 4784, 4785, 4786, 4787, 4788, 4791, 4798, 4799, 5136, 5137, 5141
VERBOSE: Get-Events - There are more events to process then 22, split will be required.
VERBOSE: Get-Events - Preparing data to scan computer AD1
VERBOSE: Get-Events - Filter parameters provided EndTime = 04/28/2019 23:59:59
VERBOSE: Get-Events - Filter parameters provided LogName = System
VERBOSE: Get-Events - Filter parameters provided StartTime = 04/25/2019 00:00:00
VERBOSE: Get-Events - Events to process in Total (unique): 1
VERBOSE: Get-Events - Events to process in Total ID: 104
VERBOSE: Get-Events - Preparing data to scan computer AD2
VERBOSE: Get-Events - Filter parameters provided EndTime = 04/28/2019 23:59:59
VERBOSE: Get-Events - Filter parameters provided LogName = System
VERBOSE: Get-Events - Filter parameters provided StartTime = 04/25/2019 00:00:00
VERBOSE: Get-Events - Events to process in Total (unique): 1
VERBOSE: Get-Events - Events to process in Total ID: 104
VERBOSE: Get-Events - Running query with parallel enabled...
VERBOSE: Get-Events -------------START---------------------
VERBOSE: Get-Events - Inside AD1 for Events ID: 104
VERBOSE: Get-Events - Inside AD1 for Events LogName: System
VERBOSE: Get-Events - Inside AD1 for Events RecordID:
VERBOSE: Get-Events - Inside AD1 for Events Oldest: False
VERBOSE: Get-Events - Inside AD1 for Events Max Events: 0
VERBOSE: Get-Events - Inside AD1 Data in FilterHashTable EndTime 04/28/2019 23:59:59
VERBOSE: Get-Events - Inside AD1 Data in FilterHashTable LogName System
VERBOSE: Get-Events - Inside AD1 Data in FilterHashTable Id 104
VERBOSE: Get-Events - Inside AD1 Data in FilterHashTable StartTime 04/25/2019 00:00:00
VERBOSE: Constructed structured query:
.
VERBOSE: Get-Events - Inside AD1 Events found 2
VERBOSE: Get-Events - Inside AD1 Processing events...
VERBOSE: Get-Events - Inside AD1 Time to generate 0 hours, 0 minutes, 0 seconds, 77 milliseconds
VERBOSE: Get-Events --------------END----------------------
VERBOSE: Get-Events -------------START---------------------
VERBOSE: Get-Events - Inside AD2 for Events ID: 104
VERBOSE: Get-Events - Inside AD2 for Events LogName: System
VERBOSE: Get-Events - Inside AD2 for Events RecordID:
VERBOSE: Get-Events - Inside AD2 for Events Oldest: False
VERBOSE: Get-Events - Inside AD2 for Events Max Events: 0
VERBOSE: Get-Events - Inside AD2 Data in FilterHashTable EndTime 04/28/2019 23:59:59
VERBOSE: Get-Events - Inside AD2 Data in FilterHashTable LogName System
VERBOSE: Get-Events - Inside AD2 Data in FilterHashTable Id 104
VERBOSE: Get-Events - Inside AD2 Data in FilterHashTable StartTime 04/25/2019 00:00:00
VERBOSE: Constructed structured query:
.
VERBOSE: Get-Events - Inside AD2 No events found.
VERBOSE: Get-Events - Inside AD2 Time to generate 0 hours, 0 minutes, 5 seconds, 628 milliseconds
VERBOSE: Get-Events --------------END----------------------
VERBOSE: Get-Events -------------START---------------------
VERBOSE: Get-Events - Inside AD1 for Events ID: 4743 4744 4745 4746 4747 4748 4749 4750 4751 4752 4753 4754 4756 4757 4758 4759 4760 4761 4762 4763 4764 4767
VERBOSE: Get-Events - Inside AD1 for Events LogName: Security
VERBOSE: Get-Events - Inside AD1 for Events RecordID:
VERBOSE: Get-Events - Inside AD1 for Events Oldest: False
VERBOSE: Get-Events - Inside AD1 for Events Max Events: 0
VERBOSE: Get-Events - Inside AD1 Data in FilterHashTable EndTime 04/28/2019 23:59:59
VERBOSE: Get-Events - Inside AD1 Data in FilterHashTable LogName Security
VERBOSE: Get-Events - Inside AD1 Data in FilterHashTable Id 4743 4744 4745 4746 4747 4748 4749 4750 4751 4752 4753 4754 4756 4757 4758 4759 4760 4761 4762 4763 4764 4767
VERBOSE: Get-Events - Inside AD1 Data in FilterHashTable StartTime 04/25/2019 00:00:00
VERBOSE: Constructed structured query:
.
VERBOSE: Get-Events - Inside AD1 Events found 9
VERBOSE: Get-Events - Inside AD1 Processing events...
VERBOSE: Get-Events - Inside AD1 Time to generate 0 hours, 0 minutes, 25 seconds, 392 milliseconds
VERBOSE: Get-Events --------------END----------------------
VERBOSE: Get-Events -------------START---------------------
VERBOSE: Get-Events - Inside AD1 for Events ID: 1102 1105 4720 4722 4723 4724 4725 4726 4727 4728 4729 4730 4731 4732 4733 4734 4735 4737 4738 4740 4741 4742
VERBOSE: Get-Events - Inside AD1 for Events LogName: Security
VERBOSE: Get-Events - Inside AD1 for Events RecordID:
VERBOSE: Get-Events - Inside AD1 for Events Oldest: False
VERBOSE: Get-Events - Inside AD1 for Events Max Events: 0
VERBOSE: Get-Events - Inside AD1 Data in FilterHashTable EndTime 04/28/2019 23:59:59
VERBOSE: Get-Events - Inside AD1 Data in FilterHashTable LogName Security
VERBOSE: Get-Events - Inside AD1 Data in FilterHashTable Id 1102 1105 4720 4722 4723 4724 4725 4726 4727 4728 4729 4730 4731 4732 4733 4734 4735 4737 4738 4740 4741 4742
VERBOSE: Get-Events - Inside AD1 Data in FilterHashTable StartTime 04/25/2019 00:00:00
VERBOSE: Constructed structured query:
.
VERBOSE: Get-Events - Inside AD1 Events found 26
VERBOSE: Get-Events - Inside AD1 Processing events...
VERBOSE: Get-Events - Inside AD1 Time to generate 0 hours, 0 minutes, 25 seconds, 655 milliseconds
VERBOSE: Get-Events --------------END----------------------
VERBOSE: Get-Events -------------START---------------------
VERBOSE: Get-Events - Inside AD1 for Events ID: 4784 4785 4786 4787 4788 4791 4798 4799 5136 5137 5141
VERBOSE: Get-Events - Inside AD1 for Events LogName: Security
VERBOSE: Get-Events - Inside AD1 for Events RecordID:
VERBOSE: Get-Events - Inside AD1 for Events Oldest: False
VERBOSE: Get-Events - Inside AD1 for Events Max Events: 0
VERBOSE: Get-Events - Inside AD1 Data in FilterHashTable EndTime 04/28/2019 23:59:59
VERBOSE: Get-Events - Inside AD1 Data in FilterHashTable LogName Security
VERBOSE: Get-Events - Inside AD1 Data in FilterHashTable Id 4784 4785 4786 4787 4788 4791 4798 4799 5136 5137 5141
VERBOSE: Get-Events - Inside AD1 Data in FilterHashTable StartTime 04/25/2019 00:00:00
VERBOSE: Constructed structured query:
.
VERBOSE: Get-Events - Inside AD1 Events found 150
VERBOSE: Get-Events - Inside AD1 Processing events...
VERBOSE: Get-Events - Inside AD1 Time to generate 0 hours, 0 minutes, 31 seconds, 507 milliseconds
VERBOSE: Get-Events --------------END----------------------
VERBOSE: Get-Events -------------START---------------------
VERBOSE: Get-Events - Inside AD2 for Events ID: 4743 4744 4745 4746 4747 4748 4749 4750 4751 4752 4753 4754 4756 4757 4758 4759 4760 4761 4762 4763 4764 4767
VERBOSE: Get-Events - Inside AD2 for Events LogName: Security
VERBOSE: Get-Events - Inside AD2 for Events RecordID:
VERBOSE: Get-Events - Inside AD2 for Events Oldest: False
VERBOSE: Get-Events - Inside AD2 for Events Max Events: 0
VERBOSE: Get-Events - Inside AD2 Data in FilterHashTable EndTime 04/28/2019 23:59:59
VERBOSE: Get-Events - Inside AD2 Data in FilterHashTable LogName Security
VERBOSE: Get-Events - Inside AD2 Data in FilterHashTable Id 4743 4744 4745 4746 4747 4748 4749 4750 4751 4752 4753 4754 4756 4757 4758 4759 4760 4761 4762 4763 4764 4767
VERBOSE: Get-Events - Inside AD2 Data in FilterHashTable StartTime 04/25/2019 00:00:00
VERBOSE: Constructed structured query:
.
VERBOSE: Get-Events - Inside AD2 No events found.
VERBOSE: Get-Events - Inside AD2 Time to generate 0 hours, 0 minutes, 56 seconds, 577 milliseconds
VERBOSE: Get-Events --------------END----------------------
VERBOSE: Get-Events -------------START---------------------
VERBOSE: Get-Events - Inside AD2 for Events ID: 1102 1105 4720 4722 4723 4724 4725 4726 4727 4728 4729 4730 4731 4732 4733 4734 4735 4737 4738 4740 4741 4742
VERBOSE: Get-Events - Inside AD2 for Events LogName: Security
VERBOSE: Get-Events - Inside AD2 for Events RecordID:
VERBOSE: Get-Events - Inside AD2 for Events Oldest: False
VERBOSE: Get-Events - Inside AD2 for Events Max Events: 0
VERBOSE: Get-Events - Inside AD2 Data in FilterHashTable EndTime 04/28/2019 23:59:59
VERBOSE: Get-Events - Inside AD2 Data in FilterHashTable LogName Security
VERBOSE: Get-Events - Inside AD2 Data in FilterHashTable Id 1102 1105 4720 4722 4723 4724 4725 4726 4727 4728 4729 4730 4731 4732 4733 4734 4735 4737 4738 4740 4741 4742
VERBOSE: Get-Events - Inside AD2 Data in FilterHashTable StartTime 04/25/2019 00:00:00
VERBOSE: Constructed structured query:
.
VERBOSE: Get-Events - Inside AD2 Events found 1
VERBOSE: Get-Events - Inside AD2 Processing events...
VERBOSE: Get-Events - Inside AD2 Time to generate 0 hours, 1 minutes, 2 seconds, 270 milliseconds
VERBOSE: Get-Events --------------END----------------------
VERBOSE: Get-Events -------------START---------------------
VERBOSE: Get-Events - Inside AD2 for Events ID: 4784 4785 4786 4787 4788 4791 4798 4799 5136 5137 5141
VERBOSE: Get-Events - Inside AD2 for Events LogName: Security
VERBOSE: Get-Events - Inside AD2 for Events RecordID:
VERBOSE: Get-Events - Inside AD2 for Events Oldest: False
VERBOSE: Get-Events - Inside AD2 for Events Max Events: 0
VERBOSE: Get-Events - Inside AD2 Data in FilterHashTable EndTime 04/28/2019 23:59:59
VERBOSE: Get-Events - Inside AD2 Data in FilterHashTable LogName Security
VERBOSE: Get-Events - Inside AD2 Data in FilterHashTable Id 4784 4785 4786 4787 4788 4791 4798 4799 5136 5137 5141
VERBOSE: Get-Events - Inside AD2 Data in FilterHashTable StartTime 04/25/2019 00:00:00
VERBOSE: Constructed structured query:
.
VERBOSE: Get-Events - Inside AD2 Events found 47
VERBOSE: Get-Events - Inside AD2 Processing events...
VERBOSE: Get-Events - Inside AD2 Time to generate 0 hours, 1 minutes, 5 seconds, 841 milliseconds
VERBOSE: Get-Events --------------END----------------------
VERBOSE: Get-Events - Overall errors: 0
VERBOSE: Get-Events - Overall events processed in total for the report: 235
VERBOSE: Get-Events - Overall time to generate 0 hours, 1 minutes, 6 seconds, 83 milliseconds
VERBOSE: Get-Events - Overall events processing end
[Info] Events scanned found 235 - Time elapsed: 0 days, 0 hours, 1 minutes, 6 seconds, 138 milliseconds
[Info] Running ADUserChanges
[Info] Running ADUserChanges with subsection Events
[Info] Ending ADUserChanges with subsection Events events found 9
[Info] Ending ADUserChanges - Time to run 0 days, 0 hours, 0 minutes, 0 seconds, 949 milliseconds
[Info] Running ADUserChangesDetailed
[Info] Running ADUserChangesDetailed with subsection Events
[Info] Ending ADUserChangesDetailed with subsection Events events found 30
[Info] Ending ADUserChangesDetailed - Time to run 0 days, 0 hours, 0 minutes, 2 seconds, 997 milliseconds
[Info] Running ADComputerChangesDetailed
[Info] Running ADComputerChangesDetailed with subsection Events
[Info] Ending ADComputerChangesDetailed with subsection Events events found 6
[Info] Ending ADComputerChangesDetailed - Time to run 0 days, 0 hours, 0 minutes, 0 seconds, 612 milliseconds
[Info] Running ADUserStatus
[Info] Running ADUserStatus with subsection Events
[Info] Ending ADUserStatus with subsection Events events found 6
[Info] Ending ADUserStatus - Time to run 0 days, 0 hours, 0 minutes, 0 seconds, 614 milliseconds
[Info] Running ADUserLockouts
[Info] Running ADUserLockouts with subsection Events
[Info] Ending ADUserLockouts with subsection Events events found 0
[Info] Ending ADUserLockouts - Time to run 0 days, 0 hours, 0 minutes, 0 seconds, 14 milliseconds
[Info] Running ADUserUnlocked
[Info] Running ADUserUnlocked with subsection Events
[Info] Ending ADUserUnlocked with subsection Events events found 0
[Info] Ending ADUserUnlocked - Time to run 0 days, 0 hours, 0 minutes, 0 seconds, 10 milliseconds
[Info] Running ADComputerCreatedChanged
[Info] Running ADComputerCreatedChanged with subsection Events
[Info] Ending ADComputerCreatedChanged with subsection Events events found 6
[Info] Ending ADComputerCreatedChanged - Time to run 0 days, 0 hours, 0 minutes, 0 seconds, 602 milliseconds
[Info] Running ADComputerDeleted
[Info] Running ADComputerDeleted with subsection Events
[Info] Ending ADComputerDeleted with subsection Events events found 1
[Info] Ending ADComputerDeleted - Time to run 0 days, 0 hours, 0 minutes, 0 seconds, 117 milliseconds
[Info] Running ADGroupMembershipChanges
[Info] Running ADGroupMembershipChanges with subsection Events
[Info] Ending ADGroupMembershipChanges with subsection Events events found 8
[Info] Ending ADGroupMembershipChanges - Time to run 0 days, 0 hours, 0 minutes, 0 seconds, 815 milliseconds
[Info] Running ADGroupEnumeration
[Info] Running ADGroupEnumeration with subsection Events
[Info] Ending ADGroupEnumeration with subsection Events events found 149
[Info] Ending ADGroupEnumeration - Time to run 0 days, 0 hours, 0 minutes, 14 seconds, 615 milliseconds
[Info] Running ADGroupChanges
[Info] Running ADGroupChanges with subsection Events
[Info] Ending ADGroupChanges with subsection Events events found 6
[Info] Ending ADGroupChanges - Time to run 0 days, 0 hours, 0 minutes, 0 seconds, 579 milliseconds
[Info] Running ADGroupCreateDelete
[Info] Running ADGroupCreateDelete with subsection Events
[Info] Ending ADGroupCreateDelete with subsection Events events found 0
[Info] Ending ADGroupCreateDelete - Time to run 0 days, 0 hours, 0 minutes, 0 seconds, 18 milliseconds
[Info] Running ADGroupChangesDetailed
[Info] Running ADGroupChangesDetailed with subsection Events
[Info] Ending ADGroupChangesDetailed with subsection Events events found 5
[Info] Ending ADGroupChangesDetailed - Time to run 0 days, 0 hours, 0 minutes, 0 seconds, 489 milliseconds
[Info] Running ADGroupPolicyChanges
[Info] Running ADGroupPolicyChanges with subsection Group Policy Name Changes
[Info] Ending ADGroupPolicyChanges with subsection Group Policy Name Changes events found 0
[Info] Running ADGroupPolicyChanges with subsection Group Policy Edits
[Info] Ending ADGroupPolicyChanges with subsection Group Policy Edits events found 0
[Info] Running ADGroupPolicyChanges with subsection Group Policy Links
[Info] Ending ADGroupPolicyChanges with subsection Group Policy Links events found 0
[Info] Ending ADGroupPolicyChanges - Time to run 0 days, 0 hours, 0 minutes, 0 seconds, 32 milliseconds
[Info] Running ADLogsClearedSecurity
[Info] Running ADLogsClearedSecurity with subsection Events
[Info] Ending ADLogsClearedSecurity with subsection Events events found 0
[Info] Ending ADLogsClearedSecurity - Time to run 0 days, 0 hours, 0 minutes, 0 seconds, 18 milliseconds
[Info] Running ADLogsClearedOther
[Info] Running ADLogsClearedOther with subsection Events
[Info] Ending ADLogsClearedOther with subsection Events events found 2
[Info] Ending ADLogsClearedOther - Time to run 0 days, 0 hours, 0 minutes, 0 seconds, 38 milliseconds
As you can see above, Get-Events (from PSEventViewer) is utilizing its power to get all events, and it does it in just 1 minute and 6 seconds. So even thou we've asked for much more events than we did above we get them in the same amount of time.
One more thing to know, and notice, is that I've skipped three reports. ADUserLogon, ADuserLogonKerberos and ADEventsReboots. The first two reports often contain so much information that getting that information is time-consuming. ADEventsReboots, on the other hand, is useless. I've not spent much time developing that report, so the information there is hardly useful.