You are here

Does MPM work with Zabbix 2.0?

Taxonomy upgrade extras: 

A customer asked:

I would like to know if the FromDual Performance Monitor for MySQL works with Zabbix 2.0?

We do not know yet (June 2012). This is a project for this summer... We do not expect any problem if the Zabbix 2.0 interfaces have not changed significantly.

This customer kindly tested MPM on Zabbix 2.0 for us.

The customer reported:

In relation to FromDual Performance Monitor for MySQL, I've started a test today and I can import the xml files without any problem with Zabbix 2.0
To be continued...

and a bit later:

I can confirm that mpm works with Zabbix 2.0!

Great work! A big thank you to our customer. So please feel free to use it with Zabbix 2.0 and report any issue to us.

When I run, I see the following: 30381:20131115:122820.012 item [HOSTNAME:FromDual.MySQL.check] became not supported: Received value [] is not suitable for value type [Numeric (unsigned)] and data type [Decimal] Suggestions?
willscomment

It looks for me like check delivers an empty string and expects an int or decimal. One has to check what check delivers exactly and why. Debugging in the mpm agent should help on this...
olicomment

Thank you! I was able to get past that issue, but now, I have a new one:

9704:2013-11-18 17:03:53.268 - INFO: FromDual Performance Monitor for MySQL (0.9.1) run started.
9704:2013-11-18 17:03:53.329 - WARN: util-zabbix1, 10051, util-mysql1
9704:2013-11-18 17:03:53.330 - WARN: Connection to zabbix server failed (rc=1305)!
9704:2013-11-18 17:03:53.339 - WARN: util-zabbix1, 10051, util-mysql1
9704:2013-11-18 17:03:53.339 - WARN: Connection to zabbix server failed (rc=1305)!
9704:2013-11-18 17:03:53.347 - WARN: util-zabbix1, 10051, util-mysql1
9704:2013-11-18 17:03:53.347 - WARN: Connection to zabbix server failed (rc=1305)!
9704:2013-11-18 17:03:53.368 - WARN: util-zabbix1, 10051, util-mysql1
9704:2013-11-18 17:03:53.368 - WARN: Connection to zabbix server failed (rc=1305)!
9704:2013-11-18 17:03:53.377 - WARN: util-zabbix1, 10051, util-mysql1
9704:2013-11-18 17:03:53.377 - WARN: Connection to zabbix server failed (rc=1305)!
9704:2013-11-18 17:03:53.378 - INFO: FromDual Performance Monitor for MySQL run finshed (rc=0).

I verified the connectivity between the two systems via telnet:

[root@util-mysql1 me]# telnet util-zabbix1 10051
Trying 10.20.80.27 ...
Connected to util-zabbix1.
Escape character is '^]'.

But it seems the Zabbix agent is not sending data to the server, and the server is not receiving any data. One thing that is interesting is that MPM agent is up, and displaying data.

Thoughts?

willscomment

Has this ever worked before (with < 2.2)?

Error 1305 means, that the agent cannot connect to the zabbix server. We verify: ZabbixServer, ZabbixPort and Hostname

And for hostname the following rule applies: "This MUST match Hostname in Zabbix!"

This is a typical configuration mistake. So I am wondering if it is a config mistake or if something in 2.2 has changed...

olicomment

Yes, it works in previous version of 1.8.x. I'm trying to migrate to 2.2 because of the VMware monitoring, but I can't do that until I get the FromDual configuration working on it.

Thanks for pointing out that issue. I made sure the server and agent hostnames are exactly the same all around (in config files, as well as Zabbix server). However, it seems the issue still stands. I did bounce the services to make sure that I'm not running into a Zabbix 2.2 idiosyncrasy.

willscomment

Figured it out. Currently, MPM is sending the data as such:

[root@util-mysql1 zabbix]# /usr/bin/zabbix_sender --zabbix-server util-zabbix1.domain.pvt --port 10051 --host 'util-mysql1.domain.pvt' --key ‘FromDual.MySQL.innodb.Innodb_buffer_pool_pages_dirty’ --value '1384890233' -vv
zabbix_sender [5450]: DEBUG: answer [{
"response":"success",
"info":"processed: 0; failed: 1; total: 1; seconds spent: 0.000040"}]
info from server: "processed: 0; failed: 1; total: 1; seconds spent: 0.000040"
sent: 1; skipped: 0; total: 1

However, with 2.2, the syntax seems to be a bit different, with success:

[root@util-mysql1 zabbix]# /usr/bin/zabbix_sender -z util-zabbix1.domain.pvt -p 10051 -s 'util-mysql1.domain.pvt' -k 'FromDual.MySQL.innodb.Innodb_buffer_pool_pages_dirty' -o '1384890233' -vv
zabbix_sender [5246]: DEBUG: answer [{
"response":"success",
"info":"processed: 1; failed: 0; total: 1; seconds spent: 0.000198"}]
info from server: "processed: 1; failed: 0; total: 1; seconds spent: 0.000198"
sent: 1; skipped: 0; total: 1

And this data gets trapped and recorded on the Zabbix server! At least I know it isn't incompatible ;-)

willscomment

One more time. Some debugging, and I've identified a possible source of the issue: checkConnectionToZabbixServer in sendData.pm

Commenting out the following fixes the issue:
$rc = &FromDualMySQLagent::checkConnectionToZabbixServer($main::gParameter{'ZabbixServer'}, $main::gParameter{'ZabbixServerPort'}, $main::gParameter{'Hostname'});

willscomment

Message 9704:2013-11-18 17:03:53.377 - WARN: Connection to zabbix server failed (rc=1305)! appears because of a bug in lib/FromDualMySQLagent.pm in function checkConnectionToZabbixServer. In this function, FromDual agent tries to send a trapper to Zabbix as follow: /usr/bin/zabbix_sender -z XXXX -p 10051 -s 'vbbcmdb1' -k FromDual.server.check -o '1' Unfortunatly, item 'FromDual.server.check' doesn't exist in any provided template, which makes check fail. Also, zabbix_sender options are OK here. You can use either short or long version
jbfavrecomment