1
votes

My team has a .NET MVC 4.6 application we deploy to Azure App Services. We are using the Agent-based application monitoring implementation, thus, we turn on Application Insights at the App Server level and it should just work.

Every time we deploy the application to Azure (using Azure DevOps); Application Insights while showing still enabled; no longer works.

  • Clicking on Live Metrics gives the screen saying the app is offline (although its very much online and accessible)
  • If you click on performance or bugs, there is no data

The only way to get Application Insights to work again is to Disable it; wait a few seconds and Re-Enable it. Then Live Metrics fires up and everything works fine.

This happens in our Dev, QA and Production environment. We are clearly missing something but unsure what to look for. We have the following configuration settings that Azure put there for us:

  • APPINSIGHTS_INSTRUMENTATIONKEY
  • APPINSIGHTS_PROFILERFEATURE_VERSION
  • APPINSIGHTS_SNAPSHOTFEATURE_VERSION
  • APPLICATIONINSIGHTS_CONNECTION_STRING
  • ApplicationInsightsAgent_EXTENSION_VERSION

I have validated the Instrumentation Key is correct.

1
can you post the code about how you configured itSajeetharan
Hi @Sajeetharan - I am not using any code to configure it; I am using the Agent-based application monitoring (ApplicationInsightsAgent). This method is the easiest to enable, and no advanced configuration is required. It is often referred to as "runtime" monitoring. For Azure App Services we recommend at a minimum enabling this level of monitoring, and then based on your specific scenario you can evaluate whether more advanced monitoring through manual instrumentation is needed.Flea
docs.microsoft.com/en-us/azure/azure-monitor/app/… has one interesting thing to look at - if your bin\ folder happens to contain certain DLLs, there could be conflicts with Application Insights.WaitingForGuacamole
@WaitingForGuacamole this article helped me resolve it! Turns out System.DiagnosticsSource.dll was in the bin directory. If you want to post this as the answer, I will mark it as the Answer for you!Flea

1 Answers

1
votes

The troubleshooting documentation for App Insights Agent at https://docs.microsoft.com/en-us/azure/azure-monitor/app/status-monitor-v2-troubleshoot points out that the existence of the following assemblies could cause conflicts with App Insights Agent:

  • Microsoft.ApplicationInsights.dll
  • Microsoft.AspNet.TelemetryCorrelation.dll
  • System.Diagnostics.DiagnosticSource.dll