MUNIN Plugin WARN: MySQL InnoDB free tablespace

Defected

Member
Dec 14, 2009
17
0
51
I see the same weird behavior in a couple of servers and also on fresh installed machines. In an older ticket i've opened about this, support said that it's probably a munin bug. They were able to reproduce this behavior.

[email protected] [/etc/munin/plugins]# ./mysql_innodb
ERROR 1045 (28000): Access denied for user 'munin'@'localhost' (using password: YES)

I think there is a case opened (case 48107), so a fix might be released. Keep an eye on the changelog. :)
 

fijumen

Member
Jun 10, 2010
10
0
51
Happened to me too, on a 2 new servers, must be a Munin bug, hope someone will update this thread after bug fix.
 

cPanelTristan

Quality Assurance Analyst
Staff member
Oct 2, 2010
7,607
38
248
somewhere over the rainbow
cPanel Access Level
Root Administrator
This warning should be disregarded. It is due to how Munin versus MySQL handle tablespace for InnoDB. By default, Munin throws a warning at 2GB free tablespace and critical alert at 1GB free tablespace. However, MySQL defaults to creating a 10MB autoexpanding tablespace. The tablespace can be verified with:

Code:
mysql -e "SHOW VARIABLES LIKE 'innodb_data_file_path'"
This means InnoDB will perpetually show <10MB of space (resulting in a permanent Munin warning) yet will always seamlessly autoextend as needed. The only "limit" in such a configuration is the partition that /var/lib/mysql is stored on. This render's the InnoDB free tablespace useless in an "autoextend" configuration.

The way to resolve is simply to disable the alerts. Create this file:

Code:
vi /etc/munin/plugin-conf.d/mysql_innodb
Place the following inside the file:

Code:
[mysql_innodb]
env.warning 0
env.critical 0
At that point, run the following commands:

Code:
/etc/init.d/munin-node restart
su munin -c /usr/bin/munin-cron
 

alphawolf50

Well-Known Member
Apr 28, 2011
186
2
68
cPanel Access Level
Root Administrator
Also, if you use innodb_file_per_table, there is no point even running this plugin. It is safe to:

Code:
# rm /etc/munin/plugins/mysql_innodb
This doesn't delete the actual plugin, only the symlink to the plugin. The actual plugin resides at:

/usr/share/munin/plugins/mysql_innodb.

Do not delete that one.

EDIT: after you've deleted the plugin, make sure you # service munin-node restart
 
Last edited:

kamm

Well-Known Member
Jan 17, 2004
46
1
158
Spain
cPanel Access Level
Root Administrator
I just installed munin using WHM > Manage Plugins. After the install I noticed the "MySQL InnoDB free tablespace" warning and have followed cPanelTristan's instructions in post #5.

Those commands ran OK until the last one...
su munin -c /usr/bin/munin-cron
which returns...
This account is currently not available.

Munin seems to be running OK and the warning has gone, but what about that last command? Perhaps something's changed since this post was written?
 

Daky

Well-Known Member
May 22, 2005
56
0
156
I am getting the same message.

Stopping Munin Node agents: [ OK ]
Starting Munin Node: [ OK ]
[email protected]*** [~]# su munin -c /usr/bin/munin-cron
This account is currently not available.

Please advise
 

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,913
2,201
363
Hello :)

You can run the following commands instead:

Code:
su - munin --shell=/bin/bash
/usr/local/cpanel/3rdparty/perl/514/bin/munin-cron
Thank you.
 

RobinF28

Active Member
Jun 27, 2015
39
8
8
Elgin, Scotland
cPanel Access Level
Root Administrator
Hi,

This worked for me, thanks.

No more warnings showing at the MUNIN graph InnoDB free.

To help anyone wondering about the command flow, my terminal screen was something like this, FYI:

[email protected] [~]# mysql -e "SHOW VARIABLES LIKE 'innodb_data_file_path'"
+-----------------------+------------------------+
| Variable_name | Value |
+-----------------------+------------------------+
| innodb_data_file_path | ibdata1:10M:autoextend |
+-----------------------+------------------------+

[email protected] [~]# vi /etc/munin/plugin-conf.d/mysql_innodb

[email protected] [~]# cat /etc/munin/plugin-conf.d/mysql_innodb
[mysql_innodb]
env.warning 0
env.critical 0

[email protected] [~]# /etc/init.d/munin-node restart
Stopping Munin Node agents: [ OK ]
Starting Munin Node: [ OK ]

[email protected] [~]# su munin -c /usr/bin/munin-cron
This account is currently not available.

[email protected] [~]# su - munin --shell=/bin/bash
Attempting to create directory /home/munin/perl5
[email protected] [~]# /usr/local/cpanel/3rdparty/bin/munin-cron
[email protected] [~]#

[email protected] [~]# logout
[email protected] [~]#
 
Last edited by a moderator:

cPanelMichael

Administrator
Staff member
Apr 11, 2011
47,913
2,201
363
I am happy to see you were able to address the issue. Thank you for updating us with the outcome.
 

jmcguirl

Registered
Jul 29, 2007
1
0
51
Hi,

This worked for me, thanks.

No more warnings showing at the MUNIN graph InnoDB free.

To help anyone wondering about the command flow, my terminal screen was something like this, FYI:

[email protected] [~]# mysql -e "SHOW VARIABLES LIKE 'innodb_data_file_path'"
+-----------------------+------------------------+
| Variable_name | Value |
+-----------------------+------------------------+
| innodb_data_file_path | ibdata1:10M:autoextend |
+-----------------------+------------------------+

[email protected] [~]# vi /etc/munin/plugin-conf.d/mysql_innodb

[email protected] [~]# cat /etc/munin/plugin-conf.d/mysql_innodb
[mysql_innodb]
env.warning 0
env.critical 0

[email protected] [~]# /etc/init.d/munin-node restart
Stopping Munin Node agents: [ OK ]
Starting Munin Node: [ OK ]

[email protected] [~]# su munin -c /usr/bin/munin-cron
This account is currently not available.

[email protected] [~]# su - munin --shell=/bin/bash
Attempting to create directory /home/munin/perl5
[email protected] [~]# /usr/local/cpanel/3rdparty/perl/514/bin/munin-cron
[email protected] [~]#

[email protected] [~]# logout
[email protected] [~]#
As this port gets older, the very last munin command should be changed to:

/usr/local/cpanel/3rdparty/bin/munin-cron

It is a symlink that always points to the latest version of munin-cron. Just my two cents.
 

kitchin

Member
Sep 18, 2011
24
0
51
cPanel Access Level
Root Administrator
As this port gets older, the very last munin command should be changed to:

/usr/local/cpanel/3rdparty/bin/munin-cron

It is a symlink that always points to the latest version of munin-cron. Just my two cents.
No symlink here. Just look for the latest perl in
/usr/local/cpanel/3rdparty/perl