Users Pricing

forum

Home Forums Why does my IIS Application Pool keep crashing automatically with Event ID 5002? – MindStick

Why does my IIS Application Pool keep crashing automatically with Event ID 5002?

Rana Sunny 29 28 Sep 2026

Hey everyone, I'm facing a weird issue on our Windows Server 2019 hosting an ASP.NET Core web application under IIS 10.

Every few hours, or immediately under slight load, the Application Pool automatically stops itself. When I check the Windows Event Viewer under System logs, I see Event ID 5002 stating that the application pool is being automatically disabled due to a series of failures in the process serving it.

I know this is related to Rapid Fail Protection in IIS, but I cannot figure out what is causing the worker process (w3wp.exe) to crash in the first place before IIS disables the pool. The Application event log does not always show a clear stack trace.

Below is the PowerShell command I used to inspect the pool failure properties:

# Import IIS Administration module
Import-Module WebAdministration

# Inspect Rapid Fail Protection settings for the application pool
Get-ItemProperty "IIS:\AppPools\MyAppPool" -Name failure

# Temporarily disable Rapid Fail Protection to test stability
Set-ItemProperty "IIS:\AppPools\MyAppPool" -Name failure.rapidFailProtection -Value $false

How do you usually debug worker process crashes like this? Are there specific tools like DebugDiag or WinDbg settings that I should configure to capture a dump right when w3wp crashes?


0 Answers

Markdown for AI

A clean, structured version of this page for AI assistants and LLMs.

Open .md