OpenNMS graphs for Apache HTTP Server

User Rating: 5 / 5

Star ActiveStar ActiveStar ActiveStar ActiveStar Active

Graphing Apache HTTP Server in OpenNMS

This page describes how you easily can get nice graphs in OpenNMS for Apache HTTP Server.

You can either let OpenNMS define the data collection and graphs from the SNMP MIB file, or you can use the datacollection and graph files that I have customized, to provide fewer graphs with more items per graph and to not collect all data.



Is is assumed that you have already enabled the Apache module and the NetSNMP module for getting Apache HTTP Server statistics using SNMP, you can read about how you do that in Monitoring Apache HTTP Server in OpenNMS.

The graphs and data collection is used on a OpenNMS installation running version 1.12. It should most likely also work on older versions, but it has only been tested on 1.12.

The OpenNMS installation is running on Debian 7, so if you are running another distribution, you might have to place the files in other directories.


Data collection

You can download a customized data collection file for Apache HTTP Server, and after download you put it on your OpenNMS server at /etc/opennms/datacollection

You also have to edit your /etc/opennms/datacollection-config.xml, by adding a line

"<include-collection dataCollectionGroup="APACHE2-MIB"/>" 

towards the end of the file.

My datacollection file has been customized in three ways.

Mainly, I added a section to tell OpenNMS that NetSNMP is providing the data for this data collection, by adding the following section at the end of the file

 <systemDef name="Apache Web Server - Net-SNMP">

Secondly, I have modified the resource type for virtual server, so that the servername is used for storage and display. This should keep your data consistent even if you add or remove virtual hosts.

<resourceType name="apache2MIBvserverEntry"
                    label="Apache HTTP Server Virtual host" 
      <parameter key="sibling-column-name" value="vserverName" />

To make that work, I also had to change the type for the vserverName attribute from octetstring to string , so it looks like this

<mibObj oid="." 


Thirdly, I have removed collection of some data, for example server ports, because these do not change normally, and I do not find it interesting to record and graph.


Graph properties

You can download the graph properties file for Apache HTTP Server, and after download you put it on your OpenNMS server at /etc/opennms/

This graph properties file differs a great deal from the one you can generate from the MIB directly. My file contains fewer graphs, but each graph has more items. For example, I have made one graph showing all Mime type response codes, instead of having 6 different graphs each showing one image type.



Here are some examples from a low traffic web site using these graphs to monitor Apache HTTP server.


HTTP requests

Bytes served and received


HTTP response codes

HTTP content-type text

HTTP content-type image


Additional information