f

Hang diagnostics

LeanSentry's Hang diagnostics help you stay in control of your website's performance by automatically troubleshooting IIS + ASP.NET performance problems. Hang diagnostics help you:
  1. Resolve website outages, poor performance, and queueing.
  2. Troubleshoot slow requests.
In addition to automatically recognizing most common IIS and ASP.NET performance problems, Hang diagnostic reports also provide you with guidance and recommendations on how to address them. Hang diagnostics: diagram showing the request processing flow during the hang How it works LeanSentry continuously monitors your websites for signs of common performance problems, with virtually no production overhead.
  1. When a problem is detected, LeanSentry confirms it with a lightweight analysis of active requests.
  2. If the hang is confirmed, LeanSentry performs a quick debugger-based analysis to diagnose the hang. This typically lasts 5-10 seconds.
  3. By default, once the analysis is complete, LeanSentry gracefully recycles your application pool to attempt to resolve the hang.
A detailed hang diagnostic report is then generated outlining the causes of the slowdown. Automatic insights We'll automatically send you hang diagnostic reports when they are interesting ... including major website outages, slowdowns that are getting worse, or are being caused by a new regression of your code. This helps make sure you can identify and resolve important causes of slowdowns quickly, often before they cause major outages. Hang diagnostics: automatic insights highlight important hangs and application changes causing slowdowns Using Hang diagnostic reports to resolve hangs You can access Hang diagnostic reports from insight emails, from the main dashboard, or by going to the "Hang diagnostics" link in the diagnostics sidebar. Each report breaks down the hang, and provides information on where requests were blocked as well as any other IIS and ASP.NET performance issues we identified. 1) The summary section will outline the key statistics and findings about the hang. Hang diagnostics: key IIS and ASP.NET performance statistics The findings will quickly explain what caused the hang, and list the relevant performance issues we detected. We'll detect and explain common problems such as concurrency limits, queueing, thread pool exhaustion, and so on. Hang diagnostics: key findings
TIP: LeanSentry inspects your configuration and the runtime conditions to identify dozens of performance problems.
2) Identify the application code causing the hang or request slowdowns. Click the "Functions blocking requests" or "Functions blocking threads" findings to view the application functions causing the hang.
HINT: Expand each function to view the full stack details with source code information.
Hang diagnostic: functions causing the hang We'll also automatically display additional details where applicable, such as SQL query being made by a SQL call, file being accessed for file IO operations, or HTTP request being made by an HTTP request call. 3) Review the blocking locations, and associated application functions Click the "Blocked requests" tab to view the blocked requests grouped by blocking location within your application's request processing pipeline. Expand each location to view the application functions causing the blocking (if available). Hang diagnostics: blocking locations with functions causing blocking You can also view the requests themselves blocked in each location by clicking "Show requests" at the bottom of the tab. Configuring Hang diagnostics You can enable and configure Hang diagnostics for your entire environment, or for a specific website. Click the "Hang diagnostics" link in the main dashboard's "Diagnostics" sidebar to view the environment level-settings, or chose the website on that page to configure the specific site. There, you can configure:
  • Minimum thresholds for diagnostics, in terms of the minimum # or % of blocked requests necessary to trigger the diagnostic - and how long they must be blocked for.
  • Limits on how often a diagnostic can run.
  • Diagnostic mode: whether we perform the full analysis, or a lightweight analysis only (no debugger/recycle, but often sufficient esp. for non-ASP.NET applications) .
TIP: You can use Hang diagnostics to troubleshoot slow requests without a site-wide hang. To do this, consider lowering the minimum blocked request thresholds and focusing the diagnostic on a specific url (IMPORTANT: keep limits low to avoid too many diagnostic attempts).
Hang diagnostics: configure triggers, limits, and more. You can also set advanced settings such as urls to focus on or ignore when determining the hang, and other advanced behaviors. Diagnosing on-demand To diagnose an application on-demand, click "Diagnose now" link next to "Hang diagnostics" on the main dashboard's right panel, or by opening the diagnostic settings for a specific website or process in the real-time "Websites and processes" tool.
NOTE: On-demand diagnostics can produce mixed results when triggered during a time when a hang is not taking place. It is better to let LeanSentry determine when a hang is taking place and automatically generate a diagnostic at that time.
Need help? Have a question or feedback on Hang diagnostics? Email us at support@leansentry.com.




More resources


Want to learn the best techniques for managing your IIS web server? Join our how-to newsletter.
Want to get the best tool for troubleshooting and tuning your web apps? .

Build your skills


Get performance best practices straight from our IIS & ASP.NET experts:


How-to newsletter: 1-2 emails/week with expert IIS & ASP.NET tips.