You are here

Some type of configuration issue

I have installed your MPM for Zabbix, but I am not getting any data into Zabbix. I have followed the troubleshooting steps at http://www.fromdual.com/mpm-installation-guide, and added some extra checks. I even set this up on a test server first (and had this working)

On the Zabbix server, Status is Monitored for Host, Availability is in the green, templates at Template_FromDual.MySQL.mpm, Template_FromDual.MySQL.mysql, Template_FromDual.MySQL.server, Template_FromDual.MySQL.slave

Monitoring the agent.

$ tail /var/log/zabbix/zabbix_agentd.log
1948:20130325:220353 Requested [FromDual.MySQL.check]
1948:20130325:220354 Before
1948:20130325:220354 Run remote command [/usr/local/mysql_performance_monitor_agent/FromDualMySQLagent.pl /usr/local/mysql_performance_monitor_agent/etc/FromDualMySQLagent.conf] Result [1] [1]...
1948:20130325:220354 Sending back [1]
1949:20130325:220403 Processing request.

QUESTION: Is a result of [1] correct or incorrect?

$ tail -30 /tmp/FromDualMySQLagent.log
6130:2013-03-25 22:04:53.206 - INFO: FromDual Performance Monitor for MySQL (0.9) run started.
6130:2013-03-25 22:04:53.276 - ERR : Load of cache file failed. rc=1301
6130:2013-03-25 22:04:54.358 - ERR : Load of cache file failed. rc=1301
6130:2013-03-25 22:04:54.435 - ERR : Load of cache file failed. rc=1301
6130:2013-03-25 22:04:54.469 - ERR : Load of cache file failed. rc=1301
6130:2013-03-25 22:04:54.528 - ERR : Load of cache file failed. rc=1301
6130:2013-03-25 22:04:54.613 - ERR : Load of cache file failed. rc=1301
6130:2013-03-25 22:04:54.687 - ERR : Load of cache file failed. rc=1301
6130:2013-03-25 22:04:54.757 - ERR : Load of cache file failed. rc=1301
6130:2013-03-25 22:04:54.826 - ERR : Load of cache file failed. rc=1301
6130:2013-03-25 22:04:54.829 - INFO: FromDual Performance Monitor for MySQL run finshed (rc=0).

I am feeling these cache file failed errors are not right, and probably the cause of the problem.

Queries are definitely being run on the DB:

130325 21:58:25 491 Connect zabbix@localhost on
491 Query set autocommit=1
491 Query SHOW GLOBAL VARIABLES
491 Query SHOW /*!50000 GLOBAL */ STATUS
491 Quit

However, I had to hack the code to add the socket directly.

$ tail /tmp/FromDualMySQLagent.log
2536:2013-03-25 21:47:04.383 - ERR : DBI connect with database=mysql, host=localhost, port=3306 and user=zabbix failed: Can't connect to local MySQL server through socket '/var/lib/mysql/mysql.sock' (2)
2536:2013-03-25 21:47:04.383 - DBG : Database connection failed (rc=2600).

I was forced to add mysql_socket to your .pm to get my connections to work in Perl. I can use the exact same connection string via mysql client and not have any issues needing to specify the socket (i.e. -u -p -h)

Other Checks. I can connect from server to agent manually

sudo -u zabbix zabbix_get --host=10.176.163.126 --source-address=10.181.225.66 --key="FromDual.MySQL.check"
1
sudo -u zabbix zabbix_get --host=10.176.163.126 --source-address=10.181.225.66 --key="FromDual.MySQL.mysql.Com_select"
ZBX_NOTSUPPORTED

But why, is the second one not supported? Is the key wrong?

zabbix_sender --zabbix-server=10.181.225.66 --host=10.176.163.12 --key=FromDual.MySQLmysql.Questions --value="123" --verbose
sent: 1; failed: 0; total: 1
$ zabbix_sender --zabbix-server=10.181.225.66 --host=10.176.163.12 --key=FromDual.MySQL.mysql.Questions --value="123" --verbose
sent: 1; failed: 0; total: 1

Is your example right, are you missing a . in MySQL.mysql (tried both).

I am at a loss? Any Help appreciated.