Munin Automated Script for CentOS


#!/bin/bash

Updating System
yum -y update

64 Bit
wget http://download.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm
rpm -ivh epel-release-6-8.noarch.rpm

32 Bit
wget http://download.fedoraproject.org/pub/epel/6/i386/epel-release-6-8.noarch.rpm
rpm -ivh epel-release-6-8.noarch.rpm

Installation Apache
yum install httpd

Install Munin Packages
yum –enablerepo=epel install munin munin-node rrdtool

Configuring Apache web server /etc/httpd/conf.d/munin.conf
echo “<Directory /var/www/html/munin>
Options FollowSymLinks
AllowOverride None
Order allow,deny
Allow from all
</Directory>
<directory /var/www/html/munin>
AuthUserFile /etc/munin/munin-htpasswd
AuthName “admin”
AuthType Basic
require valid-user
ExpiresActive On
ExpiresDefault M310
</directory>
ScriptAlias /munin-cgi/munin-cgi-graph /var/www/cgi-bin/munin-cgi-graph” >> /etc/httpd/conf.d/munin.conf

Configuring Munin server Add/Modify
echo “dbdir /var/lib/munin
htmldir /var/www/html/munin
logdir /var/log/munin
rundir /var/run/munin
tmpldir /etc/munin/templates
includedir /etc/munin/conf.d
graph_strategy cron
cgiurl_graph /munin-cgi/munin-cgi-graph
html_strategy cron
[localhost]
address 127.0.0.1
use_node_name yes” >> /etc/munin/munin.conf

Create Password For Munin Admin User
htpasswd -c /etc/munin/munin-htpasswd admin

Start Apache & Munin Services
service munin-node start
service httpd start

Installation Completed
http://IP-Address/munin

Advertisements

Leave a Reply

Please log in using one of these methods to post your comment:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s