Author Topic: Installing munin for monitoring  (Read 10114 times)

0 Members and 1 Guest are viewing this topic.

Offline
*
Installing munin for monitoring
« on: January 12, 2018, 02:17:13 PM »
While looking for help installing Munin (https://en.wikipedia.org/wiki/Munin_(software)) on CWP I made a few notes. I thought of sharing them here in case they're useful (plus I'll be able to find them in the future).

This applies to CWP on CentOS6; it uses YUM so it may work on CentOS7 but I can't test it.

Install munin and munin-node:

Code: [Select]
yum -y install munin munin-node
I leave all the paths as they're defaults and munin will actually work now, but it makes sense to change some settings. Edit /etc/munin/munin.conf and change [localhost] to [your.hostname.com]. Not changing this will list your server as 'localhost' and changing this in the future will cause the accumulated history to be dropped.

Start munin-node and set it to start automatically (this is different on CentOS7):

Code: [Select]
service munin-node start
chkconfig munin-node start

The easiest way to get Munin accessible is to add it as an alias. Edit /usr/local/apache/domain-redirects.conf and append the last line:

Code: [Select]
RewriteEngine On
Alias /webftp /usr/local/apache/htdocs/webftp_simple
Alias /WebFTP /usr/local/apache/htdocs/webftp_simple
Alias /webftp_simple /usr/local/apache/htdocs/webftp_simple
Alias /munin /var/www/html/munin

Restart Apache:

Code: [Select]
service httpd restart
Visit any domain with the directory /munin and you should now get the Munin page. Cron is used to update the charts every five minutes and it takes a while - about a day - for the charts to become meaningful.

Optionally, the pages can be password protected using a standard .htaccess and .htpasswd file saved in the /var/www/html/munin directory.

If you get any problems they will most likely be paths or permissions. Check /etc/munin/munin.conf for the paths, or view the log files in /var/log/munin/.

Offline
*
Re: Installing munin for monitoring
« Reply #1 on: January 17, 2018, 03:14:04 PM »
To correct a mistake: chkconfig uses 'on' not 'start'

Start munin-node and set it to start automatically (this is different on CentOS7):

Code: [Select]
service munin-node start
chkconfig munin-node on

Offline
*
Re: Installing munin for monitoring
« Reply #2 on: January 13, 2021, 08:55:19 AM »
This NOT work on Centos7 and present CWP version (01.2021). Cant provide valid installation method as I myself didnt get it working correctly.
Maybe advanced CWP configuration with Apache/Varnish/ngnix prevent munin from working?