Hello,
I am trying to get values into my discovered items

I have a script locally on my agent that outputs the following:
inside /etc/zabbix/zabbix_agentd.conf we have:
My zabbix template has the discovery item as so:

Along with the item prototype as so:

This as shown in the 1st screenshot creates the discovered lanes.
I want the value of `#POSLANESTATUS` to be there but not sure what I'm doing wrong. In other words, I want pos_lane_X with a value of pos_lane_X_status
Im certain it has to do with my zabbix template setup but not sure what...
any input is much appreciated!!
Thank you,
Dave
I am trying to get values into my discovered items
I have a script locally on my agent that outputs the following:
Code:
[root@tamu46668 ~]# ./zabbix-lane-status.sh
{"data":[
{"{#POSLANE}":"tamu46668_lane_1_pos","{#POSLANESTA TUS}":"down"},
{"{#POSLANE}":"tamu46668_lane_2_pos","{#POSLANESTA TUS}":"offline"},
{"{#POSLANE}":"tamu46668_lane_3_pos","{#POSLANESTA TUS}":"down"},
{"{#POSLANE}":"tamu46668_lane_4_pos","{#POSLANESTA TUS}":"idle"},
{"{#POSLANE}":"tamu46668_lane_5_pos","{#POSLANESTA TUS}":"total"},
{"{#POSLANE}":"tamu46668_lane_6_pos","{#POSLANESTA TUS}":"offline"},
{"{#POSLANE}":"tamu46668_lane_7_pos","{#POSLANESTA TUS}":"offline"},
{"{#POSLANE}":"tamu46668_lane_8_pos","{#POSLANESTA TUS}":"down"},
{"{#POSLANE}":"tamu46668_lane_9_pos","{#POSLANESTA TUS}":"offline"},
{"{#POSLANE}":"tamu46668_lane_10_pos","{#POSLANEST ATUS}":"offline"},
{"{#POSLANE}":"tamu46668_lane_11_pos","{#POSLANEST ATUS}":"offline"},
{"{#POSLANE}":"tamu46668_lane_12_pos","{#POSLANEST ATUS}":"idle"},
{"{#POSLANE}":"tamu46668_lane_13_pos","{#POSLANEST ATUS}":"idle"},
{"{#POSLANE}":"tamu46668_lane_14_pos","{#POSLANEST ATUS}":"down"},
{"{#POSLANE}":"tamu46668_lane_15_pos","{#POSLANEST ATUS}":"idle"},
{"{#POSLANE}":"tamu46668_lane_16_pos","{#POSLANEST ATUS}":"offline"},
{"{#PRINTERLANE}":"tamu46668_lane_1_printer","{#PRINTERLANESTATUS}":"offline"},
{"{#PRINTERLANE}":"tamu46668_lane_2_printer","{#PRINTERLANESTATUS}":"offline"},
{"{#PRINTERLANE}":"tamu46668_lane_3_printer","{#PRINTERLANESTATUS}":"offline"},
{"{#PRINTERLANE}":"tamu46668_lane_4_printer","{#PRINTERLANESTATUS}":"online"},
{"{#PRINTERLANE}":"tamu46668_lane_5_printer","{#PRINTERLANESTATUS}":"online"},
{"{#PRINTERLANE}":"tamu46668_lane_6_printer","{#PRINTERLANESTATUS}":"offline"},
{"{#PRINTERLANE}":"tamu46668_lane_7_printer","{#PRINTERLANESTATUS}":"offline"},
{"{#PRINTERLANE}":"tamu46668_lane_8_printer","{#PRINTERLANESTATUS}":"offline"},
{"{#PRINTERLANE}":"tamu46668_lane_9_printer","{#PRINTERLANESTATUS}":"offline"},
{"{#PRINTERLANE}":"tamu46668_lane_10_printer","{#PRINTERLANESTATUS}":"offline"},
{"{#PRINTERLANE}":"tamu46668_lane_11_printer","{#PRINTERLANESTATUS}":"offline"},
{"{#PRINTERLANE}":"tamu46668_lane_12_printer","{#PRINTERLANESTATUS}":"online"},
{"{#PRINTERLANE}":"tamu46668_lane_13_printer","{#PRINTERLANESTATUS}":"online"},
{"{#PRINTERLANE}":"tamu46668_lane_14_printer","{#PRINTERLANESTATUS}":"offline"},
{"{#PRINTERLANE}":"tamu46668_lane_15_printer","{#PRINTERLANESTATUS}":"online"},
{"{#PRINTERLANE}":"tamu46668_lane_16_printer","{#PRINTERLANESTATUS}":"offline"}
]}
Code:
UserParameter=jbrain.pos.lane.discovery,/usr/local/bin/zabbix-lane-status.sh
Along with the item prototype as so:
This as shown in the 1st screenshot creates the discovered lanes.
I want the value of `#POSLANESTATUS` to be there but not sure what I'm doing wrong. In other words, I want pos_lane_X with a value of pos_lane_X_status
Im certain it has to do with my zabbix template setup but not sure what...
any input is much appreciated!!
Thank you,
Dave
Comment