Query historical performance data

This is possible but not so easy to achieve :slight_smile:
and it is only working with the Enterprise Edition.

The part with the metrics is missing inside the Livestatus documentation.
Here a small example

GET services
Filter: host_name = <hostname>
Filter: service_description = <service_description>
Columns: rrddata:m1:<performance data name>.max,1,*:<start time>:<end time>:1
OutputFormat: json

As a one liner it looks like this.
lq "GET services\nFilter: host_name = HOSTNAME\nFilter: service_description = Uptime\nColumns: rrddata:m1:uptime.max,1,*:1592037600:1592066400:1\nOutputFormat: json"

2 Likes