Sidebar

manual:appendix:protocols:real_time_export

This is an old revision of the document!


5 Real-time export protocol

Real-time exporting of trigger events, item values and trends is supported in a newline-delimited JSON format. Exporting is done into files, where each line of the export file is a JSON object.

Trigger events

Examples

Problem:

{"hosts":["Host B","Zabbix Server"],"groups":["Group X","Group Y","Group Z","Zabbix servers"],"tags":[{"tag":"availability","value":""},{"tag":"data center","value":"Riga"}],"name":"Either Zabbix agent is unreachable on Host B or pollers are too busy on Zabbix Server","clock":1519304285,"ns":123456789,"eventid":42, "value":1}

Recovery:

{"clock":1519304345,"ns":987654321,"eventid":43,"p_eventid":42,"value":0}

Problem (multiple problem event generation):

{"hosts":["Host B","Zabbix Server"],"groups":["Group X","Group Y","Group Z","Zabbix servers"],"tags":[{"tag":"availability","value":""},{"tag":"data center","value":"Riga"}],"name":"Either Zabbix agent is unreachable on Host B or pollers are too busy on Zabbix Server","clock":1519304286,"ns":123456789,"eventid":43, "value":1}
{"hosts":["Host B","Zabbix Server"],"groups":["Group X","Group Y","Group Z","Zabbix servers"],"tags":[{"tag":"availability","value":""},{"tag":"data center","value":"Riga"}],"name":"Either Zabbix agent is unreachable on Host B or pollers are too busy on Zabbix Server","clock":1519304286,"ns":123456789,"eventid":43, "value":1}

Recovery:

{"clock":1519304346,"ns":987654321,"eventid":44,"p_eventid":43,"value":0}
{"clock":1519304346,"ns":987654321,"eventid":44,"p_eventid":42,"value":0}

Item values

Examples

Numeric (unsigned)

{"host":"Host B","groups":["Group X","Group Y","Group Z"],"applications":["Zabbix Agent","Availability"],"itemid":3,"name":"Agent availability","clock":1519304285,"ns":123456789,"value":1}

Numeric (float)

{"host":"Host B","groups":["Group X","Group Y","Group Z"],"applications":["CPU","Performance"],"itemid":4,"name":"CPU Load","clock":1519304285,"ns":123456789,"value":"0.1"}

Character, text

{"host":"Host B","groups":["Group X","Group Y","Group Z"],"applications":["Zabbix Agent","Installed software versions"],"itemid":2,"name":"Agent version","clock":1519304285,"ns":123456789,"value":"3.4.4"}

Log

{"host":"Host A","groups":["Group X","Group Y","Group Z"],"applications":["Log files","Critical"],"itemid":1,"name":"Messages in log file","clock":1519304285,"ns":123456789,"timestamp":1519304285,"source":"","severity":0,"logeventid":0,"value":"log file message"}
Examples

Numeric (unsigned)

{"host":"Host B","groups":["Group X","Group Y","Group Z"],"applications":["Zabbix Agent","Availability"],"itemid":3,"name":"Agent availability","clock":1519311600,"count":60,"min":1,"avg":1,"max":1}

Numeric (float)

{"host":"Host B","groups":["Group X","Group Y","Group Z"],"applications":["CPU","Performance"],"itemid":4,"name":"CPU Load","clock":1519311600,"count":60,"min":0.01,"avg":0.15,"max":1.5}