Skip to content

Monitoring guide

IIS monitoring and IIS logs

On IIS, requests queue when application pools are busy or recycling. Performance counters and the time-taken field in IIS logs show where.

4 min read14 sectionsUpdated

On this page

Key points

  • Requests in application queue rising means the app pool is saturated.
  • Unexpected app pool recycles cause slow first requests and lost sessions.
  • time-taken in W3C logs gives response time per request.
  • HTTPERR logs record requests rejected before they reach your app.

Performance counters

plaintext
# PowerShell
Get-Counter '\Web Service(_Total)\Current Connections', `
            '\HTTP Service Request Queues(*)\CurrentQueueSize', `
            '\ASP.NET\Requests Queued', `
            '\Process(w3wp*)\% Processor Time' -SampleInterval 5 -MaxSamples 3

What to watch

MetricWorry when
HTTP Service Request Queues: CurrentQueueSizeAbove 0 for minutes
Requests Queued (ASP.NET)Growing
w3wp CPU and private bytesNear limits; memory growing
App pool recycles / stopsUnplanned recycles or rapid-fail protection
5xx share and time-taken p95 (logs)Rising
HTTPERR entriesConnection_Dropped, Timer_ConnectionIdle in bulk

IIS log fields

Enable at least date time cs-method cs-uri-stem sc-status sc-substatus time-taken in W3C logging. sc-substatus explains many 4xx and 5xx (for example 503.2 means the concurrent request limit was exceeded). Logs live under %SystemDrive%\inetpub\logs\LogFiles by default; HTTPERR logs under %SystemRoot%\System32\LogFiles\HTTPERR.

Collecting metrics

On Windows, the OpenTelemetry Collector's iis receiver reads these counters, and a filelog receiver can ship IIS logs.

otel-collector.yamlyaml
receivers:
  iis:
    collection_interval: 60s
exporters:
  otlphttp/vitalrix:
    encoding: json
    metrics_endpoint: ${env:VITALRIX_API}/api/v1/metrics/otlp/v1/metrics
    headers: { x-api-key: ${env:VITALRIX_KEY} }
service:
  pipelines:
    metrics: { receivers: [iis], exporters: [otlphttp/vitalrix] }

IIS monitoring with VitalRix

Collector metrics arrive over OTLP and can be charted on dashboards and used in alert rules. A TCP check confirms IIS accepts connections from the network your app uses, and APM traces show which requests wait on IIS and for how long, from the client spans your instrumented services create. For .NET applications on IIS, add OpenTelemetry for .NET to get traces per request.

Alerts to start with

  • Requests in the HTTP.sys queue above 0 for 5 minutes.
  • Application pool stopped, or rapid-fail protection triggered (event log).
  • w3wp private bytes growing steadily (a leak) or near limits.
  • 5xx share above 1 to 2% in logs.
  • An uptime check on each site from outside the server.

Application pool recycling

By default IIS recycles application pools on a fixed schedule, which can cause slow first requests and lost in-memory state. Prefer recycling at a quiet time of day, or on memory thresholds, and enable overlapped recycling so a new worker starts before the old one stops.

The IIS metrics that matter

Windows performance counters and the IIS logs cover nearly everything; collect them with the OpenTelemetry Collector or the agent of your choice.

MetricSourceStarting alert
Current connectionsWeb Service \ Current ConnectionsFar above the usual
Requests queuedASP.NET \ Requests Queued (or HTTP Service Request Queues)Above zero for a minute
Request wait timeASP.NET \ Request Wait TimeRising
Application pool state and recyclesWAS events in the System logUnexpected recycles, rapid-fail protection stopping a pool
w3wp memory and CPUProcess counters per worker processMemory growing without bound, CPU near 100%
Time taken per requesttime-taken field in IIS logsp95 above your budget
5xx responsessc-status in IIS logsAbove 1% for 5 minutes

What the incidents look like

  • 503 Service Unavailable from HTTP.sys when rapid-fail protection stops an application pool after repeated crashes. The site returns 503 instantly; the cause is in the Application event log.
  • Recycles at the worst time: the default periodic recycle or a memory limit restarts the pool during traffic, and the first requests after it are slow. Schedule recycles off-peak and warm the application.
  • Requests queue when the application is blocked on a slow database or a synchronous call, long before CPU is busy.
  • Failed Request Tracing shows where one slow request spent its time when a trace is not available.

Add OpenTelemetry for .NET to see each request as a trace, and an external uptime check to catch a stopped pool within a minute.

Frequently asked questions

Why are first requests slow after a while?

The application pool recycled or idled out, so the app restarts on the next request. Adjust idle timeout and recycling, or use Application Initialization to warm up.

What does 503 from IIS usually mean?

The application pool is stopped (often by rapid-fail protection after crashes) or a queue limit was reached. Check the substatus and the event log.

Check it now, free

  • PHP performance monitoring: Monitor PHP and Laravel apps: request latency, PHP-FPM worker saturation, OPcache hit rate, slow queries, external calls and errors.
  • Python performance monitoring: Monitor Python web apps: request latency per route, worker saturation, the GIL and CPU-bound code, database time, Celery queues and memory.
  • What is Apdex?: Apdex explained: the formula, how to pick the threshold T, a worked example, how to read the score, and why many teams now prefer SLOs and percentiles.
  • Java performance monitoring: Monitor Java and Spring applications: JVM heap and GC, thread pools, JDBC connection pools, request latency from traces.
  • Best APM tools: Choose an APM tool in 2026: the criteria that matter, from OpenTelemetry support to pricing models, well-known options compared and how to run a fair trial.
  • What is APM (application performance monitoring)?: APM explained: what application performance monitoring measures, how traces and spans work, why p95 beats averages, a worked example and how to start.

Watch your own site and services with VitalRix

Uptime checks, APM, logs, real-user monitoring, alerts and status pages in one place. Every product has a free tier and no credit card is needed.