PDA

View Full Version : Can't monitor MySQL, have an error "Not supported by ZABBIX agent".


ChomK9
23-06-2005, 10:41
Hi Forum,

I use ZABBIX 1.1alpha7. I can't monitor MySQL 4.0.17 on Fedora Core 2. I modified "zabbix_agentd.conf" (set -u<username> -p<password>) like these.


####### USER-DEFINED MONITORED PARAMETERS #######
# Format: UserParameter=<key>,<shell command>
# Note that shell command must not return empty string or EOL only

UserParameter=system[test],who|wc -l

### Set of parameter for monitoring MySQL server (v3.23.42 and later)
### Change -u<username> and add -p<password> if required

UserParameter=mysql[ping],mysqladmin -uzabbix -pzabxxx ping|grep alive|wc -l
UserParameter=mysql[uptime],mysqladmin -uzabbix -pzabxxx status|cut -f2 -d":"|cut -f1 -d"T"
UserParameter=mysql[threads],mysqladmin -uzabbix -pzabxxx status|cut -f3 -d":"|cut -f1 -d"Q"
UserParameter=mysql[questions],mysqladmin -uzabbix -pzabxxx status|cut -f4 -d":"|cut -f1 -d"S"
UserParameter=mysql[slowqueries],mysqladmin -uzabbix -pzabxxx status|cut -f5 -d":"|cut -f1 -d"O"
UserParameter=mysql[qps],mysqladmin -uzabbix -pzabxxx status|cut -f9 -d":"
UserParameter=version[mysql],mysql -V


On the Web-Console still show
http://www.dpim.go.th/test/zabbixMySQL.png

HELP ME, PLEASE :(

Alexei
23-06-2005, 10:57
Do the commands work fine from command line?

ChomK9
24-06-2005, 10:47
Do the commands work fine from command line?

Yes, your commands work fine from command line.


[root@myhost]# mysqladmin -uzabbix -pzabpass ping|grep alive|wc -l
1
[root@myhost]# mysqladmin -uzabbix -pzabpass status|cut -f2 -d":"|cut -f1 -d"T"
181884
[root@myhost]# mysqladmin -uzabbix -pzabpass status|cut -f3 -d":"|cut -f1 -d"Q"
26
[root@myhost]# mysqladmin -uzabbix -pzabpass status|cut -f4 -d":"|cut -f1 -d"S"
21324365
[root@myhost]# mysqladmin -uzabbix -pzabpass status|cut -f5 -d":"|cut -f1 -d"O"
6
[root@myhost]# mysqladmin -uzabbix -pzabpass status|cut -f9 -d":"
117.149
[root@myhost]# mysql -V
mysql Ver 12.22 Distrib 4.0.17, for pc-linux (i686)


P.S. I also changed "#define DELAY_ON_NETWORK_FAILURE 60" to "#define DELAY_ON_NETWORK_FAILURE 180" before done.

saulosilva
28-06-2005, 15:49
Hi ,

Did you fix that ? The Mysql UserParameters are working ?
Yes, your commands work fine from command line.


[root@myhost]# mysqladmin -uzabbix -pzabpass ping|grep alive|wc -l
1
[root@myhost]# mysqladmin -uzabbix -pzabpass status|cut -f2 -d":"|cut -f1 -d"T"
181884
[root@myhost]# mysqladmin -uzabbix -pzabpass status|cut -f3 -d":"|cut -f1 -d"Q"
26
[root@myhost]# mysqladmin -uzabbix -pzabpass status|cut -f4 -d":"|cut -f1 -d"S"
21324365
[root@myhost]# mysqladmin -uzabbix -pzabpass status|cut -f5 -d":"|cut -f1 -d"O"
6
[root@myhost]# mysqladmin -uzabbix -pzabpass status|cut -f9 -d":"
117.149
[root@myhost]# mysql -V
mysql Ver 12.22 Distrib 4.0.17, for pc-linux (i686)


P.S. I also changed "#define DELAY_ON_NETWORK_FAILURE 60" to "#define DELAY_ON_NETWORK_FAILURE 180" before done.

riegersteve
01-07-2005, 14:06
what version of mysql are you running

riegersteve
01-07-2005, 14:07
oops just noticed v 4.0

did you add the zabbx user with the --with-old-password option

if not give it a shot