Installation of Munin node/master
Table of Contents
- Installation on Debian/Ubuntu
- Installation on Red Hat Enterprise 3 (RHEL3)
- Installation on Red Hat Enterprise 4 (RHEL4)
- Installation on Red Hat Enterprise 5 (RHEL5)
- Installation on CentOS 5
- Installation on Fedora Core 4 (FC4)
- Installation on Fedora Core 6 (FC6)
- Munin on SuSE
- Munin on SuSE Linux Enterprise
- Munin on openSUSE
- Munin on SuSE Linux (Pro)
- Munin and SELinux
- Munin Without Apache
Remember: To do munin surveillance of a Munin master, you must be running munin-node on the master-server as well.
Installation on Debian/Ubuntu
If you are running Debian/Ubuntu, you are in luck.
Munin node
Since "Munin Node" is in the repositories, you can just type:
# apt-get install munin-node
Munin master
Since "Munin master" is in the repositories, you can just type:
# apt-get install munin
Installation on Red Hat Enterprise 3 (RHEL3)
Munin node
On my freshly installed RHEL3, the munin-node package require these dependecies:
# rpm -Uvh munin-node-1.2.5-1rhel3.noarch.rpm
error: Failed dependencies:
perl(Net::SNMP) is needed by munin-node-1.2.5-1rhel3
perl(Net::Server::Fork) is needed by munin-node-1.2.5-1rhel3
perl-Net-Server is needed by munin-node-1.2.5-1rhel3
sysstat is needed by munin-node-1.2.5-1rhel3
Suggested resolutions:
/var/spool/up2date/sysstat-5.0.5-5.rhel3.i386.rpm
Now, the "sysstat" package are located on disc 3 of the installation set, so that one is easy. The other packages can be downloaded from Dag Wieers excellent RPM repository. You migh want to head over there and download the latest versions or if you're running the x86_64 version of RHEL3:
- http://dag.wieers.com/rpm/packages/perl-Net-SNMP/
- http://dag.wieers.com/rpm/packages/perl-Crypt-DES/ (required by perl-Net-SNMP)
- http://dag.wieers.com/rpm/packages/perl-Socket6/ (required by perl-Net-SNMP)
- http://dag.wieers.com/rpm/packages/perl-Net-Server/
# rpm -Uvh sysstat-5.0.5-7.rhel4.i386.rpm Preparing... ########################################### [100%] 1:sysstat ########################################### [100%] # wget http://dag.wieers.com/rpm/packages/perl-Net-SNMP/perl-Net-SNMP-5.2.0-1.1.el3.rf.noarch.rpm # wget http://dag.wieers.com/rpm/packages/perl-Crypt-DES/perl-Crypt-DES-2.05-3.1.fc3.rf.i386.rpm # wget http://dag.wieers.com/rpm/packages/perl-Socket6/perl-Socket6-0.19-1.1.fc3.rf.i386.rpm # wget http://dag.wieers.com/rpm/packages/perl-Net-Server/perl-Net-Server-0.94-1.el3.rf.noarch.rpm # rpm -Uvh *.rpm Preparing... ########################################### [100%] 1:perl-Socket6 ########################################### [ 25%] 2:perl-Crypt-DES ########################################### [ 50%] 3:perl-Net-SNMP ########################################### [ 75%] 4:perl-Net-Server ########################################### [100%] 5:munin-node ########################################### [100%]
That's it! You will now most likly change the /etc/munin/munin.conf to accept connection from your Munin master.
Munin master
On my freshly installed RHEL3, the munin package require these dependecies:
# rpm -Uvh munin-1.2.5-1rhel3.noarch.rpm
error: Failed dependencies:
perl(HTML::Template) is needed by munin-1.2.5-1rhel3
perl(RRDs) is needed by munin-1.2.5-1rhel3
perl-HTML-Template is needed by munin-1.2.5-1rhel3
perl-Net-SNMP is needed by munin-1.2.5-1rhel3
perl-Net-Server is needed by munin-1.2.5-1rhel3
rrdtool is needed by munin-1.2.5-1rhel3
All of these packages can be downloaded from Dag Wieers excellent RPM repository. You migh want to head over there and download the latest versions or if you're running the x86_64 version of RHEL3:
- http://dag.wieers.com/rpm/packages/perl-HTML-Template/
- http://dag.wieers.com/rpm/packages/rrdtool/
- http://dag.wieers.com/rpm/packages/perl-Net-SNMP/
- http://dag.wieers.com/rpm/packages/perl-Net-Server/
# wget http://dag.wieers.com/rpm/packages/perl-HTML-Template/perl-HTML-Template-2.8-1.1.fc3.rf.noarch.rpm # wget http://dag.wieers.com/rpm/packages/rrdtool/perl-rrdtool-1.2.18-1.el3.rf.i386.rpm # wget http://dag.wieers.com/rpm/packages/rrdtool/rrdtool-1.2.18-1.el3.rf.i386.rpm # wget http://dag.wieers.com/rpm/packages/perl-Net-SNMP/perl-Net-SNMP-5.2.0-1.1.el3.rf.noarch.rpm # wget http://dag.wieers.com/rpm/packages/perl-Net-Server/perl-Net-Server-0.94-1.el3.rf.noarch.rpm # rpm -Uvh Preparing... ########################################### [100%] 1:perl-HTML-Template ########################################### [ 25%] 2:rrdtool ########################################### [ 50%] 3:perl-rrdtool ########################################### [ 75%] 4:perl-Net-SNMP ########################################### [ 75%] 5:perl-Net-Server ########################################### [100%] 6:munin ########################################### [100%]
That's it! You'll will now probably start by looking at /etc/munin/munin.conf
Installation on Red Hat Enterprise 4 (RHEL4)
Munin node
On my freshly installed RHEL4, the munin-node package require these dependecies:
# rpm -Uvh munin-node-1.2.5-1rhel4.noarch.rpm
error: Failed dependencies:
perl(Net::SNMP) is needed by munin-node-1.2.5-1rhel4.noarch
perl(Net::Server::Fork) is needed by munin-node-1.2.5-1rhel4.noarch
perl-Net-Server is needed by munin-node-1.2.5-1rhel4.noarch
sysstat is needed by munin-node-1.2.5-1rhel4.noarch
Suggested resolutions:
sysstat-5.0.5-7.rhel4.i386.rpm
Now, the "sysstat" package are easy - you'll find that on the installation CDs. The other packages can be downloaded from Dag Wieers excellent RPM repository. You migh want to head over there and download the latest versions or if you're running the x86_64 version of RHEL4:
- http://dag.wieers.com/rpm/packages/perl-Net-SNMP/
- http://dag.wieers.com/rpm/packages/perl-Crypt-DES/ (required by perl-Net-SNMP)
- http://dag.wieers.com/rpm/packages/perl-Socket6/ (required by perl-Net-SNMP)
- http://dag.wieers.com/rpm/packages/perl-Net-Server/
# rpm -Uvh sysstat-5.0.5-7.rhel4.i386.rpm Preparing... ########################################### [100%] 1:sysstat ########################################### [100%] # wget http://dag.wieers.com/rpm/packages/perl-Net-SNMP/perl-Net-SNMP-5.2.0-1.2.el4.rf.noarch.rpm # wget http://dag.wieers.com/rpm/packages/perl-Crypt-DES/perl-Crypt-DES-2.05-3.2.el4.rf.i386.rpm # wget http://dag.wieers.com/rpm/packages/perl-Socket6/perl-Socket6-0.19-1.2.el4.rf.i386.rpm # wget http://dag.wieers.com/rpm/packages/perl-Net-Server/perl-Net-Server-0.94-1.el4.rf.noarch.rpm # rpm -Uvh * Preparing... ########################################### [100%] 1:perl-Net-Server ########################################### [ 20%] 2:perl-Socket6 ########################################### [ 40%] 3:perl-Crypt-DES ########################################### [ 60%] 4:perl-Net-SNMP ########################################### [ 80%] 5:munin-node ########################################### [100%]
That's it! You will now most likly change the /etc/munin/munin.conf to accept connection from your Munin master.
Munin master
On my freshly installed RHEL4, the munin package require these dependecies:
# rpm -Uvh munin-1.2.5-1rhel4.noarch.rpm
error: Failed dependencies:
perl(HTML::Template) is needed by munin-1.2.5-1rhel4.noarch
perl(RRDs) is needed by munin-1.2.5-1rhel4.noarch
perl-HTML-Template is needed by munin-1.2.5-1rhel4.noarch
perl-Net-SNMP is needed by munin-1.2.5-1rhel4.noarch
perl-Net-Server is needed by munin-1.2.5-1rhel4.noarch
rrdtool is needed by munin-1.2.5-1rhel4.noarch
All of these packages can be downloaded from Dag Wieers excellent RPM repository. You migh want to head over there and download the latest versions or if you're running the x86_64 version of RHEL4:
- http://dag.wieers.com/rpm/packages/perl-HTML-Template/
- http://dag.wieers.com/rpm/packages/rrdtool/
- http://dag.wieers.com/rpm/packages/perl-Net-SNMP/
- http://dag.wieers.com/rpm/packages/perl-Net-Server/
# wget http://dag.wieers.com/rpm/packages/perl-HTML-Template/perl-HTML-Template-2.8-1.2.el4.rf.noarch.rpm # wget http://dag.wieers.com/rpm/packages/rrdtool/perl-rrdtool-1.2.18-1.el4.rf.i386.rpm # wget http://dag.wieers.com/rpm/packages/rrdtool/rrdtool-1.2.18-1.el4.rf.i386.rpm # wget http://dag.wieers.com/rpm/packages/perl-Net-SNMP/perl-Net-SNMP-5.2.0-1.2.el4.rf.noarch.rpm # wget http://dag.wieers.com/rpm/packages/perl-Net-Server/perl-Net-Server-0.94-1.el4.rf.noarch.rpm # rpm -Uvh * Preparing... ########################################### [100%] 1:perl-HTML-Template ########################################### [ 25%] 2:rrdtool ########################################### [ 50%] 3:perl-rrdtool ########################################### [ 75%] 4:perl-Net-SNMP ########################################### [ 75%] 5:perl-Net-Server ########################################### [100%] 6:munin ########################################### [100%]
That's it! You'll will now probably start by looking at /etc/munin/munin.conf
Installation on Red Hat Enterprise 5 (RHEL5)
The installation procedure should be the same as for RHEL4 and Dag Wieers repositories have RPM's for RHEL5
- http://dag.wieers.com/rpm/packages/perl-HTML-Template/
- http://dag.wieers.com/rpm/packages/rrdtool/
- http://dag.wieers.com/rpm/packages/perl-Net-SNMP/
- http://dag.wieers.com/rpm/packages/perl-Net-Server/
Installation on CentOS 5
The easiest way to go about this is to install a YUM repository that contains it. The two most popular are the EPEL YUM Repository from the Fedora Core team, and the Dag Wieers YUM repository
Once the repository is installed, just use YUM to install both the munin and munin-node RPMs as required.
Installing the EPEL YUM Repository
Just execute this command as root :
rpm -Uvh http://download.fedora.redhat.com/pub/epel/5/i386/epel-release-5-3.noarch.rpm
That is of course if you are running CentOS 5.3. Change the file name to 5.2 if you are running that release, and so on.
Installing the Dag Wieers YUM Repository
Just create the following file with the contents show : /etc/yum.repos.d/dag.repo
[dag] name=Dag RPM Repository for Red Hat Enterprise Linux baseurl=http://apt.sw.be/redhat/el$releasever/en/$basearch/dag gpgcheck=1 gpgkey=http://dag.wieers.com/rpm/packages/RPM-GPG-KEY.dag.txt enabled=1
Installing Client and Server
On the server, just do :
yum -y install munin
And on each client (or "node" as munin calls them) :
yum -y install munin-node
Note that the node install can take a really long time to complete - just be patient and it will.
Installation on Fedora Core 4 (FC4)
Since the third-party docs show installations on Debian, here are steps install Munin on Fedora Core 4:
Please note that munin is included in Fedora Extras (rrdtool is in fedora core) and can be installed with yum. These instructions are for people that wants a custom install.
Munin node
- You must run these commands as root.
/usr/sbin/useradd munin make install-node install-node-plugins /opt/munin/sbin/munin-node-configure --shell | sh perl -MCPAN -e "install Net::Server::Fork" echo allow ^123\.123\.123\.123$ >> /etc/opt/munin/munin-node.conf /opt/munin/sbin/munin-node
Munin master
- Start with the original commands in the INSTALL file included in the dist.
- You must run these commands as root.
perl -MCPAN -e "install HTML::Template"
- Install RRDtool http://oss.oetiker.ch/rrdtool/
- Install libart and freetype2
- You'll probably need to change these lines in the RRDtool configure script:
CPPFLAGS="$CPPFLAGS -I/usr/local/include/freetype2" CPPFLAGS="$CPPFLAGS -I/usr/local/include/libart-2.0"
- Add this line to the beginning of /opt/munin/bin/munin-cron (be sure to change to your version number)
export PERL5LIB=$PERL5LIB:/usr/local/rrdtool-1.2.15/lib/perl/5.X.X/i386-linux-thread-multi
- Add the binary to the munin user crontab:
*/5 * * * * /opt/munin/bin/munin-cron
Installation on Fedora Core 6 (FC6)
The installation on FC6 is a breeze.
Munin node
You can use yum to install munin-node:
# yum install munin-node Loading "installonlyn" plugin Setting up Install Process Setting up repositories Reading repository metadata in from local files Parsing package install arguments Resolving Dependencies --> Populating transaction set with selected packages. Please wait. ---> Downloading header for munin-node to pack into transaction set. munin-node-1.2.5-1.fc6.no 100% |=========================| 23 kB 00:02 ---> Package munin-node.noarch 0:1.2.5-1.fc6 set to be updated --> Running transaction check --> Processing Dependency: perl(LWP::Simple) for package: munin-node ...
Munin master
You an use "yum" to install munin:
# yum install munin Loading "installonlyn" plugin Setting up Install Process Setting up repositories Reading repository metadata in from local files Parsing package install arguments Resolving Dependencies --> Populating transaction set with selected packages. Please wait. ---> Downloading header for munin to pack into transaction set. munin-1.2.5-1.fc6.noarch. 100% |=========================| 10 kB 00:00 ---> Package munin.noarch 0:1.2.5-1.fc6 set to be updated --> Running transaction check ...
Munin on SuSE
Munin on SuSE Linux Enterprise
For SuSE Linux Enterprise, use the RPM packages provided at SourceForge.net
Munin on openSUSE
Munin is packaged for openSUSE (and previous versions of SuSE Linux) by the Packman project.
There are a number of methods for adding munin to openSUSE 10.2/10.3: # Use YaST -> Software -> Community Repositories and select Packman # Add Packman as an additional YaST Package Repository in YaST -> Software -> Software Repositories # Use 1 click install (installs both the munin and munin-node packages)
Install munin using the YaST -> Software -> Software Management or by using zypper:
# zypper in munin munin-node * Reading repository 'Packman Repository' cache * Reading repository 'openSUSE-10.3-FTP 10.3' cache * Reading repository 'openSUSE-10.3-Updates' cache * Reading installed packages [100%] The following NEW packages are going to be installed: munin munin-node Overall download size: 569.3 K. After the operation, additional 1.3 M will be used. Continue? [yes/no]: yes Downloading package munin-1.2.5-0.pm.1.noarch, 432.1 K (805.0 K unpacked) Downloading: munin-1.2.5-0.pm.1.noarch.rpm * Downloading [100%] * Installing: munin-1.2.5-0.pm.1 [100%] Downloading package munin-node-1.2.5-0.pm.1.noarch, 137.3 K (519.3 K unpacked) Downloading: munin-node-1.2.5-0.pm.1.noarch.rpm * Downloading [100%] * Installing: munin-node-1.2.5-0.pm.1 [100%]
Munin on SuSE Linux (Pro)
There are RPM packages for SuSE Linux 10.0 and 10.1 at SourceForge.net, or you can use the Packman build of the packages by adding Packman to your YaST -> Software -> Installation Source and install munin and munin-node as ordinary SuSE Linux packages in YaST.
Munin and SELinux
Running Munin alongside SELinux is no problem as long as the "tageted" policy are beeing used. The "targeted" policy protect only a limited set of exposed daemons (apache, bind, .. etc.). All other processes are running in a default security context (unconfined_t) which behaves as if SELinux was turned off.
Be sure to install munin, as described above, when SELinux is turned on. If not, you must "relabel" the security context on the newly installed files (and other files that may have been changed/written):
# restorecon -v -R /
Or, the recommended method:
# touch /.autorelabel
And reboot. This way the security context are changed in a early stage at the boot process. Be sure to set SELINUXTYPE=targeted in /etc/selinux/config before you reboot.
Munin Without Apache
If you don't run an Apache Web server you can still run Munin. I'm running with Resin (a Java web server from www.caucho.com) and the configuration is relatively simple. Here's a webapp definition:
<web-app>
<display-name>Munin</display-name>
<description>Monitoring Server Based on RRD Tool</description>
<welcome-file-list>index.html</welcome-file-list>
<!-- optional access control -->
<authenticator>
<type>com.caucho.server.security.XmlAuthenticator</type>
<init>
<user>username:password:munin</user>
<password-digest>none</password-digest>
</init>
</authenticator>
<login-config>
<auth-method>basic</auth-method>
</login-config>
<security-constraint url-pattern="/*" role-name="munin"/>
<servlet servlet-name="cgiservlet" servlet-class="com.caucho.servlets.CGIServlet" />
<servlet-mapping url-pattern="/cgi/munin-cgi-graph" servlet-name="cgiservlet" />
<path-mapping url-pattern="/*" real-path="/var/www/html/munin" />
</web-app>
