According to several tutorials, the following should work:
Create a new user in MySQL.
$ mysql -uroot -p
> CREATE USER 'munin'@'localhost';
> exit;
Use that user in munin to access the database:
edit /etc/munin/plugin-conf.d/munin-node
. At [mysql*] set the following:
[mysql*]
env.mysqlopts -u munin
Strange thing, is that running
/usr/sbin/munin-node-configure --suggest | grep mysql
Which tells me that MySQL cannot access the database and that it tries to access the database using user root:
[DBI connect('mysql;mysql_connect_timeout=5','root',...) failed: Access denied for user 'root'@'localhost' (using password: NO)
This is a CentOS 5.5 machine.
Why should munin-node-configure ignore the setting in /etc/munin/plugin-conf.d/munin-node? Should I set this elsewhere? Reloading or restarting the munin-node deamon changes nothing either.