OX munin scripts: Difference between revisions

From Open-Xchange
Line 25: Line 25:


jmx4perl (and its dependencies) can be easily installed with cpan if you have Perl installed:
jmx4perl (and its dependencies) can be easily installed with cpan if you have Perl installed:
You also need to have make installed.
Debian:
sudo apt-get install make


  $ perl -MCPAN -e shell
  $ perl -MCPAN -e shell
  Terminal does not support AddHistory.
  Terminal does not support AddHistory.
  cpan shell -- CPAN exploration and modules installation (v1.9205)
  cpan shell -- CPAN exploration and modules installation (v1.9205)
  ReadLine support available (maybe install Bundle::CPAN or Bundle::CPANxxl?)
  ReadLine support available (maybe install Bundle::CPAN or Bundle::CPANxxl?)
  cpan[1]> install JMX::Jmx4Perl
  cpan[1]> install JMX::Jmx4Perl
  ...
  ...
  ...
  ...

Revision as of 11:13, 7 March 2014

How to install Munin scripts for Open-Xchange

Support for Jolokia

By Version 7.4.0, Munin Scripts do support Jolokia as a bridge to get their information. This has been done to get less overhead and speak with the corresponding JMX-beans directly.

Prerequisites

Munin node and munin master must be installed and configured prior using the Munin scripts package for Open-Xchange. The installation for this core components differs on various linux distributions. For details, please visit:

http://munin-monitoring.org/

especially:

http://munin-monitoring.org/wiki/LinuxInstallation

open-xchange-munin-scripts

Install on OX AppSuite

Debian GNU/Linux 11.0

Add the following entry to /etc/apt/sources.list.d/open-xchange.list if not already present:

deb https://software.open-xchange.com/products/unsupported/repo/DebianBullseye/ /
# if you have a valid maintenance subscription, please uncomment the 
# following and add the ldb account data to the url so that the most recent
# packages get installed
# deb https://[CUSTOMERID:PASSWORD]@software.open-xchange.com/products/unsupported/repo/updates/DebianBullseye/ /

and run

$ apt-get update
$ apt-get install open-xchange-munin-scripts

Debian GNU/Linux 12.0

Add the following entry to /etc/apt/sources.list.d/open-xchange.list if not already present:

deb https://software.open-xchange.com/products/unsupported/repo/DebianBookworm/ /
# if you have a valid maintenance subscription, please uncomment the 
# following and add the ldb account data to the url so that the most recent
# packages get installed
# deb https://[CUSTOMERID:PASSWORD]@software.open-xchange.com/products/unsupported/repo/updates/DebianBookworm/ /

and run

$ apt-get update
$ apt-get install open-xchange-munin-scripts


open-xchange-munin-scripts-jolokia

Munin-scripts for Jolokia need an additional CPAN module.


jmx4perl (and its dependencies) can be easily installed with cpan if you have Perl installed: You also need to have make installed.

Debian:

sudo apt-get install make
$ perl -MCPAN -e shell
Terminal does not support AddHistory.
cpan shell -- CPAN exploration and modules installation (v1.9205)
ReadLine support available (maybe install Bundle::CPAN or Bundle::CPANxxl?)
cpan[1]> install JMX::Jmx4Perl
...
...
jmx4perl
========
jmx4perl is a command line utility for accessing Jolokia agents
(www.jolokia.org). It can be used for script based exploration 
and easy inspection of the JMX space.
Install 'jmx4perl' ? (y/n) [y ]
....

Configuring munin-node scripts for Open-Xchange

The configuration of the scripts is done automatically.

Note: The database pool monitoring script will get only configured if the Open-Xchange server is running and the database pools initialized when installing the open-xchange-munin-scripts package. That can be verified by e.g.:

# showruntimestats -x | grep "DB Pool"
com.openexchange.pooling:name=DB Pool 4,NumWaiting = 0
com.openexchange.pooling:name=DB Pool 4,PoolSize = 3
com.openexchange.pooling:name=DB Pool 4,NumBrokenConnections = 0
com.openexchange.pooling:name=DB Pool 4,NumActive = 0
com.openexchange.pooling:name=DB Pool 4,NumIdle = 3
com.openexchange.pooling:name=DB Pool 4,AvgUseTime = 4.948
com.openexchange.pooling:name=DB Pool 4,MaxUseTime = 16777
com.openexchange.pooling:name=DB Pool 4,MinUseTime = 0

Configuring for open-xchange-munin-scripts-jolokia

Munin Scripts for Jolokia do have some additional settings for jolokia.

vim /etc/munin/plugin-conf.d/ox

Key Default value Comment
env.oxJolokiaUrl http://localhost:8009/monitoring/jolokia base url for jolokia. this can differ, when using ajp. Possible ajp url could be http://apacheaddress/internal/ox1/monitoring/jolokia
env.oxJolokiaUser "" User used for authentication with HTTP Basic Authentication.
env.oxJolokiaPassword "" Password used for authentification,

Both, env.oxJolokiaUser and env.oxJolokiaPassword need to be set to the same value as set inside jolokia.properties

Supplementary notes for distributed munin clients

Munin node

The default munin node configuration only allows connections from localhost, which means that munin master has to run on the same host. If there already is a munin master running, that master IP has to be added to the file /etc/munin/munin-node.conf on each node:

# A list of addresses that are allowed to connect.  This must be a
# regular expression, since Net::Server does not understand CIDR-style
# network notation unless the perl module Net::CIDR is installed.  You
# may repeat the allow line as many times as you'd like

allow ^127\.0\.0\.1$

Munin master

Make sure the munin and apache packages are installed. If only localhost is going to be monitored, the default configuration is sufficient. Other munin nodes can be added in the /etc/munin/munin.conf file:

# a simple host tree
[localhost.localdomain]
    address 127.0.0.1
    use_node_name yes

By default, the munin monitoring web page is only reached from localhost, other hosts or networks can be added in /etc/apache2/conf.d/munin:

Allow from localhost 127.0.0.0/8 ::1    # the default setting
Allow from 10.99.0.0/8                  # added network

The munin webpage is located at http://yourhost_where_munin_is_running.org/munin.