Skip to content

prashmeh/haproxy-monitoring-extension

 
 

Repository files navigation

AppDynamics HAProxy Monitoring Extension

This extension works only with the standalone machine agent.

##Use Case

HAProxy is an open source, high performance TCP/HTTP Load Balancer commonly used to improve the performance of web sites and services by spreading requests across multiple servers. The HAProxy Monitoring extension collects key metrics from HAProxy Load balancer of the underlying proxies/servers and presents them to the AppDynamics Metric Browser.

Notes: Works with HAProxy v 1.3 and above.

##Installation

  1. Run mvn clean install from the haproxy-monitoring-extension directory and find the HAProxyMonitor.zip in the "target" folder.
  2. Unzip as "HAProxyMonitor" and copy the "HAProxyMonitor" directory to <MACHINE_AGENT_HOME>/monitors
  3. In <MACHINE_AGENT_HOME>/monitors/HAProxyMonitor/, open monitor.xml and configure the HAProxy parameters.
	<argument name="host" is-required="true" default-value="demo.1wt.eu"/>
      <argument name="port" is-required="true" default-value="80"/>

      <!--URI of the haproxy CSV stats url. See the 'CSV Export' link on your haproxy stats page -->
      <argument name="csv-export-uri" is-required="true" default-value=";csv"/>

      <argument name="username" is-required="false" default-value=""/>
      <argument name="password" is-required="false" default-value=""/>

      <!--proxy names you wish to monitor as a comma separated values. If empty all the proxies are monitored -->
      <argument name="proxynames" is-required="false" default-value=""/>
      <!--HA Proxy stats as a comma separated values to be excluded from monitoring -->
      <argument name="excludeStats" is-required="false" default-value="pid,iid,sid"/>
      <argument name="metric-prefix" is-required="false" default-value="Custom Metrics|HAProxy|"/>
  1. Restart the Machine Agent.

In the AppDynamics Metric Browser, look for: Application Infrastructure Performance | <Tier> | Custom Metrics | HAProxy

##Password Encryption Support

To avoid setting the clear text password in the monitor.xml. Please follow the process to encrypt the password and set the encrypted password and the key in the monitor.xml

  1. Download the util jar to encrypt the password from https://github.com/Appdynamics/maven-repo/raw/master/releases/com/appdynamics/appd-exts-commons/1.1.2/appd-exts-commons-1.1.2.jar
  2. Encrypt password from the commandline java -cp "appd-exts-commons-1.1.2.jar" com.appdynamics.extensions.crypto.Encryptor myKey myPassword
  3. Add the following properties in the monitor.xml substituting the default password argument.
<argument name="password-encrypted" is-required="true" default-value="<ENCRYPTED_PASSWORD>"/>
<argument name="encryption-key" is-required="true" default-value="myKey"/>

Metrics

All the HA proxy metrics are shown. For the complete list of metrics please visit http://cbonte.github.io/haproxy-dconv/configuration-1.5.html#9

Custom Dashboard

##Contributing

Always feel free to fork and contribute any changes directly here on GitHub.

##Community

Find out more in the AppSphere community.

##Support

For any questions or feature request, please contact AppDynamics Support.

About

AppDynamics HAProxy Monitoring Extension

Resources

License

Stars

Watchers

Forks

Packages

No packages published

Languages

  • Java 100.0%