As R users we mostly perform analysis, produce reports and create interactive shiny applications. Those are rather one-time performances. Sometimes, however, the R developer enters the world of the real software development, where R applications should be distributed and maintained on many machines. Then one really appreciates the value of a proper applications monitoring. In this post I present my last package called RZabbix – the R interface to the Zabbix API data.
What is Zabbix?
According to procudct overview
With Zabbix it is possible to gather virtually limitless types of data from the network. High performance real-time monitoring means that tens of thousands of servers, virtual machines and network devices can be monitored simultaneously. Along with storing the data, visualization features are available (overviews, maps, graphs, screens, etc), as well as very flexible ways of analyzing the data for the purpose of alerting.
This Ultimate Enterprise-class Monitoring Platform was nominated for the 2nd time among world’s best monitoring solutions according to Gartner
Zabbix can be used to Monitor everything – servers, network devices and applications, gathering accurate statistics and performance data.
Connect from R with RZabbix Star
You can install the package with
and then connect to Zabbix API with
The authentication is required, because every other call need to use
auth parameter in its body.
Base information of the API version can be checked with
and the regular request to get history of an item of
item_id number can be done as below
The body parameter can be also passed as a JSON string – see example for getting event data for object with
Methods and params to Zabbix API can be found in Method reference. It is a great date, because few days ago new version of Zabbix (3.2) was released.
You can try to set your own Zabbix Server from Docker container or you can use public test Zabbix on zabbix.org. If you are not yet motivated for using Docker then read my post from May
R 3.3.0 is another motivation for Docker or join 10th Cracow R User Group meetup at the end of September where I will present Rocker: explanation and motivation for Docker containers usage in applications development (by R user, for R users)
Example of usage
You can contribute!
RZabbix is still a young package and many can be done. If you would like to contribute then fill free to Fork the RZabbix repository. I am currently looking for examples on how to create a SLA overview for a specific host, calculate the amount of diskspace used by all active hosts and filesystems and create a overview of the most active triggers and I am thinking about adding tests.