Web App: Intermittent 502 and ERR_CONNECTION_TIMED_OUT Errors — Investigation and Troubleshooting Steps

mrogers-9631 0 Reputation points
2026-11-20T15:16:14.6433333+00:00

Problem description

I am experiencing intermittent 502 errors and ERR_CONNECTION_TIMED_OUT messages with my Linux Web App (atlas-redesign) hosted on Azure. These issues occur several times a day within 15-minute windows and impact my users' ability to access the application reliably.

Environment

Web App (Linux) hosted on Azure, East US.

What I've already tried

I have reviewed diagnostic information, including CPU and memory usage, and examined Azure Front Door metrics. I scaled the app from 2 to 4 instances to reduce CPU pressure. I also checked the App Service plan metrics for CPU percentage, request response times, and HTTP 5xx errors during the incident windows.

For 9-9:30 AM on 11/19 here is the CPU during the window:

and the AFD origin latency:

and the AFD percentage of 5XX:

The 5XX are not visible in the requests metrics or telemetry of our app service.

Current status

I am seeking guidance on how to verify if high CPU is truly the root cause, as claimed by support. I would appreciate any recommended diagnostic steps or best practices to identify the underlying issue.

Azure App Service
Azure App Service

Azure App Service is a service used to create and deploy scalable, mission-critical web apps.


1 answer

Sort by: Most helpful
  1. Walker Pollitt 480 Reputation points
    2026-11-22T11:18:54.4966667+00:00

    The most useful test of the high-CPU explanation is to trace one failed request. On the next HTTP 502, capture the X-Azure-Ref response header and UTC time from the browser’s Network tab. With Front Door access logging enabled, find that value in TrackingReference and inspect the same record’s ErrorInfo. A browser timeout that produces no HTTP response may have no header, so start with one of the actual 502s.

    If ErrorInfo shows DNSNameNotResolved or CertificateNameCheckFailed, you have a specific explanation for that request even if CPU was elevated at the same time. If it shows an origin timeout, compare that timestamp with per-instance CPU and response time. What ErrorInfo value do you see on one of the failed requests?

    Front Door access log fields

    Drafted with ChatGPT. Learning path · Observe and troubleshoot apps on Azure

    Was this answer helpful?

    0 comments No comments

Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.