Hi all
I have a script located in /home/zabbix, very simple:
There are two files in /home/zabbix that receipt two values by the script. It is very easy. Then in zabbix_agentd.conf I have:
I know maybe it is not the better way but I always have used UserParemeter way to obtain non-standard zabbix info. Im surprised because I have no way to obtain this values properly. I have created two items in zabbix (decimal, float, whatever, i tried everything). I link template to a host, and then I can see two new items in host. But, after some minutes, two items status changes to "Non supported". I have restarted zabbix_agentd lot of times and I have change Debug to level 4 to view if there is something wrong:
But there is no value..???
Im sure it is not the better way, I know...but this is so simple tha Im frustated :S
ANy ideas gurus?
Thanks a lot
PS:
no output, with and without quotes :S
I have a script located in /home/zabbix, very simple:
Code:
#!/bin/bash ZABBIX_DIR="/home/zabbix" /bin/cat /etc/httpd/conf/httpd.conf |grep MaxClients |head -n1|cut -c 18-20 > $ZABBIX_DIR/apache_max.txt /bin/netstat -alntp | grep :80 | wc -l > $ZABBIX_DIR/apache_clients.txt
Code:
UserParemeter=apache.maxclients,cat /home/zabbix/apache_max.txt UserParemeter=apache.clients,cat /home/zabbix/apache_clients.txt
Code:
-bash-3.2# cat /tmp/zabbix_agentd.log |grep apache -bash-3.2# cat /tmp/zabbix_agentd.log |grep apache 22145:20101117:154242.936 cfg: para: [UserParemeter] val [apache.maxclients,cat /home/zabbix/apache_max.txt] 22145:20101117:154242.936 cfg: para: [UserParemeter] val [apache.clients,cat /home/zabbix/apache_clients.txt] 22149:20101117:154633.590 Requested [apache.maxclients] 22147:20101117:154634.310 Requested [apache.clients]
Im sure it is not the better way, I know...but this is so simple tha Im frustated :S
ANy ideas gurus?
Thanks a lot
PS:
Code:
# ./zabbix_get -s127.0.0.1 -p10050 -k"system.cpu.load[all,avg1]"
Comment