I have installed Nagios Core 4.2.4 with Thruk integrated in it.I am trying to use the availability report feature in thruk through cli.Is there any API query I can use for that? Any help would be helpful and appreciated. Thanks in advance.
Asked
Active
Viewed 293 times
1 Answers
0
There are a few kinds of different reports in Thruk.
- if you are talking about the sla reports from the reports plugin, you have to create the report in the webui first, you can then trigger the report from the cli by
thruk report ...
. Thats the menu itemReporting
. - if you are talking about the
Availability
menu item, then you can simply create that report from the command line because every page in thruk can be triggered from cli. Simply runthruk url
to get a few examples.

sni
- 125
- 6
-
Thank you for your response. I was talking about "Availability " report. Can you give me an example how I can query the report through cli? – pradeep s Feb 25 '19 at 14:30
-
thruk -A thrukadmin -a 'url=avail.cgi?host=all&timeperiod=last7days&csvoutput=1' request failed: - The above query failed. – pradeep s Feb 26 '19 at 20:27
-
that command works for me, could you try with appending `--local -vvv` to get more details. – sni Mar 01 '19 at 15:55