Ad Widget

Collapse

direct extract from database

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • rakotomandimby
    Junior Member
    • Jul 2009
    • 1

    #1

    direct extract from database

    I would like to make my own processing of some measurement (essentially ping from the server to some precise equippements).

    The measurement is already done by Zabbix, my goal is to get the raw data and compute it (we have an exotic SLA rule based of the max ping during some period of time...)

    I browsed the 'zabbix' MySQL database and the fields did not speak to me.

    I have access to the web interface of Zabbix.

    Would you know the meaning of all tables and how to extract some precise mesure from that?

    Thank you.
  • Calimero
    Senior Member
    • Nov 2006
    • 481

    #2
    You could use something like this:
    Code:
    SELECT FROM_UNIXTIME(hi.clock) AS when_, h.host, i.key_, hi.value
    FROM items AS i
    JOIN history_uint AS hi ON i.itemid = hi.itemid
    JOIN hosts AS h ON h.hostid = i.hostid
    WHERE i.key_ = 'icmpping'
    AND h.host = 'host name'
    ORDER BY hi.clock DESC
    You have to use history or history_uint depending on item data type (icmppingsec will probably be stored as float ==> table history).

    There's also the trends tables for long term/averaged hourly data.

    Comment

    Working...