In Part 1 and Part 2, I've explained how to download and install the DotNetNuke .NET application, configure System Center 2012 Operations Manager (SCOM) Application Performance Monitoring (APM) and detailed the creation of an APM monitor that will allow us to deep-dive into the application for troubleshooting and performance data. You will need to review both of these previous posts before continuing with this one as they form the foundation for configuring SCOM APM. It is also presumed that you have the SCOM Web Console with the APM Application Advisor and Application Diagnostics features deployed onto one of your Management Servers.
In this final blog post of the series, I will discuss the Client-Side Monitoring configuration of APM and will show how to generate alerts within your demo/lab environment to test the APM features of SCOM.
Client Side Monitoring
Click on the Monitoring tab on the SCOM console wunderbar, expand the Application Monitoring folder and then click on the ASP.NET Web Application Inventory view to see your applications listed.
We can use the ‘Check Client-Side Monitoring Compatibility’ task from the Tasks pane on the right hand side to verify that the web application can be safely monitored using client side monitoring.
I recommend running this task as part of your initial application monitoring configuration to confirm that it can be monitored without any issues. The screen below shows the output from this task
Once we have a successful return from the Client-Side monitoring compatibility task, we can then go ahead and add the client-side monitoring feature to the newly created APM monitor.
To do this, go back to the Authoring tab on the wunderbar, expand Management Pack Templates, click on the .NET Application Performance Monitoring view and then double click on your new APM monitor (in this case it’s the DotNetNuke one as below) and then select the Client-Side Monitoring tab from the resultant window
From the screen above, enable the check box beside your application component and then click on the Customize button over on the right hand side to review the various customizations that you can apply to your monitor
The screens below show examples of some of the customizations you can make to your APM monitor
Once you are happy with your changes, click on the OK button twice to return to the main SCOM console. This will now enable some additional views within the Monitoring tab of the console and we can click back over here to take a look at what we have now for our .NET application.
Staying in the Monitoring pane, scroll down the list of folders on the left hand side and expand the Operations Manager folder. Now expand the ‘APM Agent Details’ folder and take a look at some of the alerts that have been raised in here. These alerts will normally indicate that you need to restart IIS or recycle an application pool on the server that you have configured APM monitoring for. See below for an example of these alerts
With this knowledge, it’s a good time to logon to your IIS server that is hosting the .NET application and take a look in the ‘services.msc’ snap-in and you will notice that the ‘System Center Management APM’ service is now Started and set to Manual. This service is installed by default as Disabled and only changes to Started when you configure the Client-Side monitoring functionality of SCOM APM.
It would also be a good time now to restart IIS on this server if you can. I’ve simply opened the IIS Management Console, clicked on the Server Name and then chose the ‘Restart’ option from the Manage Server pane on the right hand side
So, what do you do if you have followed the steps in these posts to the letter and have configured your APM perfectly but there are no issues within your application to test if your setup is working or not?
Simple, we create a bogus page within our application that when called on, will throw up an error for SCOM APM to deal with!
(Thanks to Paul Keely - System Center Cloud and DataCenter Management MVP for this tip!)
Simply copy the text below into notepad and save it as test.aspx into the root folder directory of your .NET application:
<%@ Page language="c#" %>
<%@ Assembly Name="System.Data" %>
<%@ Import Namespace="System.Data.SqlClient" %>
<form id="Form1" action="Default.aspx" method="post" runat="server">
using (SqlConnection connection = new SqlConnection("Server=server;Database=database;User ID=user;Password=password;"))
The root folder of my .NET IIS based application is: C:\inetpub\wwwroot\dotnetnuke
When I copied the file to the above location, I simply browse to the following URL:
This will then throw up an error page like the one below
Which in turn, will manifest itself within SCOM as
If you click on the blue URL link within the alert, it will open up the AppDiagnostics console (which is installed when you deploy the SCOM Web Console), and you will see the results of the error diagnostics as below
You can also review Performance counters from the screen below
This concludes your configuration of the APM feature in System Center 2012 Operations Manager. Although we've covered a lot in these three posts, there's still a huge amount that wasn't talked about. If you've gotten to the point where you have APM working and at least a demo application being monitored, then you will be in a great position to explore deeper into the different thresholds and customisations that are available for your application monitoring.
Update March 2014: Check out the following links to some other posts that I've written if you want to learn more about APM:
SCOM 2012 - APM CSM vs. GSM and Web Application Monitoring....Confused?
SCOM 2012 - The APM Consoles Part 1 - Application Diagnostics
Application Insights Deep Dive - Getting Started