Share →
Buffer
Andrew Clear (Mug Shot)

Over on visualstudio.com there is a pretty good walkthrough on installing the AI agent on your server, however there is one small caveat that it neglects to mention.

Issue

After installing the agent my server is listed in Application Insights, but no data is flowing. You can tell really quickly that this is happening from the Application Insights portal on the Overview => Servers tab as in the below screenshot.

image

Notice that one server is green (reporting) while the other is grey (not-reporting)?

 

Origination

After a while of searching I figured out what went wrong. After running through the wizard to install the agent, I clicked the “Finish” button and thought I was done.

image

So when this screen popped up, I just closed it without really thinking about it (not the best idea I’ve ever had, but I was trying to set up a demo in a hurry).

image

Bad idea. Basically I didn’t wait for the agent to actually start reporting any data. It was installed, but not actually monitoring anything. The same thing can also happen if you unclick this checkbox in the wizard.

image

Resolution

There are two options to start monitoring your applications.

To start monitoring all Sites

Go here: C:\Program Files\Microsoft Monitoring Agent\Agent\APMDOTNETAgent and run StartMonitoringAllApplications, wait for it to finish this time and you should be good to go.

 

 

image

To start monitoring a particular Site

Start => “monitor” run “Monitoring Agent PowerShell Prompt” as in the below screenshot.

image

 

Which will get you here.

image

Unfortunately the web site listed doesn’t, as of the time of writing this article, point to a page that has anything to do with this command line tool. So if you’re smart you’ll load the entire script into PowerShell and try and decipher what is going on. Or you can be like me and think that option #2 is what you’re looking for and brute force your way into realizing the command format is:

Start-WebApplicationMonitoring <sitename> <monitoringtype> cloud

Note that the “cloud” here is very important, as otherwise it will prompt you enter a local path. Doing so will set the reporting status to “local”. I’m not sure what exactly you can do with that, other than that it won’t report data externally if you have it set this way (I think…).

Print Friendly