Azure Application Insights On-Prem Web Farm

On each of the nodes of the web farm with a shared config run the following commands.


Download: https://www.powershellgallery.com/packages/Az.ApplicationMonitor/

$pathToNupkg = "C:\temp\az.applicationmonitor.1.1.2.nupkg"
$pathToZip = ([io.path]::ChangeExtension($pathToNupkg, "zip"))
$pathToNupkg | rename-item -newname $pathToZip
$pathInstalledModule = "$Env:ProgramFiles\WindowsPowerShell\Modules\az.applicationmonitor"
Expand-Archive -LiteralPath $pathToZip -DestinationPath $pathInstalledModule


Enable-ApplicationInsightsMonitoring -InstrumentationKey xxxxx-xxx-xxx-xxxxx -IgnoreSharedConfig -EnableInstrumentationEngine

After the commands have been run go into IIS on one of the machines in the web farm and add a module with name ManagedHttpModuleHelper pointing to Microsoft.AppInsights.IIS.ManagedHttpModuleHelper.ManagedHttpModuleHelper in the dropdown box.

https://docs.microsoft.com/en-us/azure/azure-monitor/app/status-monitor-v2-overview

Leave a comment

Your email address will not be published.