grep munin-cron /etc/cron.*/*
If only one record found, than rm -rf /var/run/munin/munin-update.lock && /etc/init.d/munin-node restart
grep munin-cron /etc/cron.*/*
If only one record found, than rm -rf /var/run/munin/munin-update.lock && /etc/init.d/munin-node restart
cat /usr/local/apache/logs/error_log | grep munin-cgi-graph
rm -rf /var/run/munin/munin-update.lock
next:
su – munin –shell=/bin/bash
munin-cron
vi /etc/nginx/conf.d/default.conf
Add to server section:
location /munin {
alias /var/www/html/munin/;
index index.html;
}
yum reinstall rrdtool perl-rrdtool rrdtool-devel
Fix.
su – munin
vi ~/.bash_profile
export LD_LIBRARY_PATH=$PATH:/usr/local/cpanel/3rdparty/lib64/mysql
munin-run mysql_connections
but this works only from curret shell session, so you need:
vi /etc/ld.so.conf.d/munin.conf
/usr/local/cpanel/3rdparty/lib64/mysql
ldconfig
/etc/init.d/munin-node restart
You are missing some munin tun time data in /var/lib/munin/
you need reinstall munin
munin-check
vi /etc/munin/plugin-conf.d/munin-node
[exim_*]
group mail
wget https://github.com/kjellm/munin-mysql/archive/master.zip
yum install munin-node
yum install DBI DBD::mysql Module::Pluggable
vi Makefile
vi mysql.conf
make install
nginx -V 2>&1 | grep -o with-http_stub_status_module
vi /etc/nginx/nginx.conf
location /nginx_status {
stub_status on;
access_log off;
allow 127.0.0.1;
allow your_IP;
deny all;
}
service nginx reload
vi /etc/munin/plugin-conf.d/nginx_
[nginx*]
env.url http://localhost/nginx_status
cd /etc/munin/plugins/
sudo ln -sf /usr/share/munin/plugins/nginx_* .
service munin-node restart
yum –enablerepo=epel -y install munin munin-node
vi /etc/httpd/conf/httpd.conf:
Alias /munin /var/www/html/munin
Options FollowSymLinks
AllowOverride None
Order allow,deny
Allow from all
/etc/init.d/httpd restart
chkconfig –levels 235 munin-node on
/etc/init.d/munin-node start
# Save this to /etc/munin/plugin-conf.d/mysql_
[mysql_*]
env.mysqlconnection DBI:mysql:mysql;host=127.0.0.1;port=3306
env.mysqluser munin
env.mysqlpassword pass
mysql> CREATE USER [email protected] IDENTIFIED BY ‘pass’;
mysql> GRANT SUPER,PROCESS ON *.* TO [email protected];
mysql> GRANT SELECT ON mysql.* TO [email protected];
mysql> FLUSH PRIVILEGES;
yum install perl-Cache-Cache
munin-node-configure –suggest 2>&1 | grep mysql
(munin-node-configure –shell 2>&1 | grep mysql | /bin/bash); service munin-node restart
check:
munin-run mysql_connections
max_connections.value 151
Max_used_connections.value 3
Aborted_clients.value 2
Aborted_connects.value 1
Threads_connected.value 3
Connections.value 36
telnet localhost 4949
Trying 1.2.3.4…
Connected to localhost.
Escape character is ‘^]’.
# munin node at localhost
fetch mysql_connections
max_connections.value 151
Max_used_connections.value 3
Aborted_clients.value 2
Aborted_connects.value 1
Threads_connected.value 3
Connections.value 38
.
quit
Connection closed by foreign host.
munin-check
and
su – munin –shell=/bin/bash
munin-cron –debug