Learn › Monitoring

Centralise Windows Logs with Windows Event Forwarding

Collect event logs from many Windows servers in one place with built-in Windows Event Forwarding (WEF): collector, subscriptions, Group Policy and queries.

Intermediate 11 min read
By Gopinath Karthikeyan

Checking event logs server by server works for one incident. To spot patterns – failed logons across the estate, a service crashing on many servers, who changed what – you need the logs in one place. Windows has this built in: Windows Event Forwarding (WEF).

How WEF works

  • Source servers forward selected events over WinRM to a collector server.
  • The collector stores them in its Forwarded Events log.
  • A subscription on the collector defines which events and which servers.
  • In source-initiated mode (best for domains), servers learn about the subscription through Group Policy.

From the collector, a SIEM or log platform can ship everything onward – or you can query it directly with PowerShell.

Windows Event Forwarding: Group Policy, source servers and the collector Group Policy Tells servers where the collector is Group Policy Collector எங்கே என்று servers-க்கு சொல்லும் SRV01 Source server SRV01 Source server SRV02 Source server SRV02 Source server DC01 Source server DC01 Source server Events pushed over WinRM (Kerberos) WinRM மூலம் events push (Kerberos) WEC collector Subscription → Forwarded Events log WEC collector Subscription → Forwarded Events log Query, report or send to a SIEM Query, report அல்லதுSIEM-க்கு அனுப்பு
Group Policy points servers at a collector; a subscription decides which events they push. Everything lands in one Forwarded Events log.Group Policy servers-ஐ collector பக்கம் காட்டுகிறது; எந்த events அனுப்ப வேண்டும் என்று subscription தீர்மானிக்கும். எல்லாம் ஒரே Forwarded Events log-ல்.

1. Prepare the collector

On a dedicated Windows Server (the collector):

wecutil qc /q                     # configure the Windows Event Collector service
Set-Service Wecsvc -StartupType Automatic

Give the Forwarded Events log enough space (Event Viewer → Forwarded Events → Properties), e.g. several GB.

2. Create a subscription

Event Viewer → Subscriptions → Create Subscription:

  • Type: Source computer initiated
  • Select Computer Groups → add the AD group of servers that should forward (e.g. Domain Computers or a WEF-Sources group)
  • Select Events → for example:
    • System: Critical, Error
    • Application: Critical, Error
    • Security: IDs 4625 (failed logon), 4720 (user created), 4728/4732 (added to group), 4740 (lockout), 1102 (log cleared)
  • Advanced → Minimize Latency for near-real-time delivery

Start small. Forwarding everything from every server overloads the collector and buries the signal.

3. Group Policy for the source servers

Create a GPO linked to your servers’ OU:

  1. Computer Configuration → Policies → Administrative Templates → Windows Components → Event Forwarding → Configure target Subscription Manager → Enabled, value: Server=http://WEC01.contoso.local:5985/wsman/SubscriptionManager/WEC,Refresh=60
  2. Make sure WinRM is running on the sources (Windows Server has it on by default).
  3. To forward the Security log, add the NETWORK SERVICE account to the event log readers: add it to the built-in Event Log Readers group on the sources (via Group Policy Restricted Groups or Local Users and Groups preferences).

Run gpupdate /force on a test server, then check on the collector: Subscriptions → right-click → Runtime Status lists active sources.

4. Query the collected events

# Failed logons across all servers, last hour
Get-WinEvent -FilterHashtable @{ LogName='ForwardedEvents'; Id=4625; StartTime=(Get-Date).AddHours(-1) } |
    Select-Object TimeCreated, MachineName,
        @{n='User';e={ $_.Properties[5].Value }},
        @{n='SourceIP';e={ $_.Properties[19].Value }} |
    Group-Object User | Sort-Object Count -Descending | Select-Object -First 10 Count, Name

# Which servers had unexpected service stops today?
Get-WinEvent -FilterHashtable @{ LogName='ForwardedEvents'; Id=7034; StartTime=(Get-Date).Date } |
    Group-Object MachineName | Select-Object Count, Name

(The property positions for event 4625 come from that event’s schema; verify them on your systems with $_.Properties before relying on them.)

Troubleshooting

Symptom Check
No sources in Runtime Status GPO applied? (gpresult /r) Collector name and port correct? Firewall 5985?
System/Application arrive but not Security NETWORK SERVICE in Event Log Readers on the source; reboot or restart WinRM
Events delayed Delivery optimisation set to Normal; switch to Minimize Latency
Collector log full Increase log size or ship events onward and keep less locally

Source-side errors appear in Applications and Services Logs → Microsoft → Windows → Eventlog-ForwardingPlugin → Operational.

Beyond WEF

WEF is free and built in, but searching and alerting on it is basic. Most companies forward the collector (or install agents directly) into a log platform – open-source stacks like Elasticsearch/OpenSearch or Grafana Loki, or a commercial SIEM – for search, dashboards and alerting. The event IDs and subscription design you learn here carry over directly.

What’s next

Next: Prometheus and Grafana for Windows servers.

Practise this topic

Test yourself with free questions on this topic – instant answers and explanations.

Start practice questions

MonitoringLoggingWindows Event ForwardingSecurityIntermediate

Gopinath Karthikeyan

Gopinath Karthikeyan – Windows Site Reliability Engineer with about 12 years in enterprise Windows Server infrastructure, and founder of WinOps Academy. YouTube · LinkedIn

More in Monitoring