Code Monkey home page Code Monkey logo

azure-demo-ai-extension-agent's Introduction

Demo application to demonstrate usage for virtual machines using Application Insights Agent (.NET framework)

Demo app to demonstrate usage for virtual machines using Application Insights Agent (.NET framework) to demonstrate functionalities like auto instrumentation approach, advanced SQL tracking to get full SQL query, etc.

How to install the agent, you can use GUI from Azure Portal (more information here) or using PowerShell steps.

AI Agent diagnostics

If agent doesn't collect data or there are some challenges with getting SQL data, then you can try a few steps to mitigate the challenge:

  1. make sure, that status monitor is sending data to Azure (check Live Stream in Application Insights) or run the query in logs section in Application Insights (dependencies | where timestamp > ago(1d) | summarize count() by cloud_RoleInstance, sdkVersion) - if the data prefix is rddf, instead of rddp, advanded logs (like SQL commands) is not sending

AI Agent Logs Information

  1. try to correct permissions to have rights to write to temp data and to app data local

Powershell:

icacls $env:WINDIR\Temp /t /c /grant IIS_IUSRS:'(OI)(CI)M'

icacls $env:WINDIR\System32\config\systemprofile\AppData\Local /t /c /grant IIS_IUSRS:'(OI)(CI)M'

  1. do IIS restart (iisreset via Powershell) (or stop / start from IIS manager)

If that doesn't work, make sure you you have rigth pre-prequisite in place:

Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope Process -Force

Install-Module -Name Az.ApplicationMonitor -AllowPrerelease -AcceptLicense

If you receive an error, that module doesn't exists, install nuget and powershellget module:

Set-ExecutionPolicy -ExecutionPolicy RemoteSigned -Scope Process -Force

Install-PackageProvider -Name NuGet -MinimumVersion 2.8.5.201 -Force

Set-PSRepository -Name "PSGallery" -InstallationPolicy Trusted

Install-Module -Name PowerShellGet -Force

Before you continue, restart PowerShell session (run the PowerShell as admin again).

Enable JUST the instrumentation engine:

Enable-InstrumentationEngine

And do IIS reset (as defined in step 3 above).

If you do that, you should see the results in the Application Insights in Azure Portal blade via end-to-end transaction details as defined below:

END to END transaction details with full SQL query

You can check all of this solutions in more details on StackOverFlow thread from respective authors.

azure-demo-ai-extension-agent's People

Contributors

bovrhovn avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.