Closed atmarosi closed 3 years ago
One glimmer of a sign of why it's failing to work - a 401 in the httpd ssl_access_log: [13/Oct/2020:18:06:06 -0700] "GET /nagios/nagiostv/ HTTP/1.1" 200 2171 [13/Oct/2020:18:06:06 -0700] "GET /nagios/nagiostv/static/css/main.7ec8fbb9.chunk.css HTTP/1.1" 200 12996 [13/Oct/2020:18:06:06 -0700] "GET /nagios/nagiostv/static/js/main.e459ee68.chunk.js HTTP/1.1" 200 90262 [13/Oct/2020:18:06:06 -0700] "GET /nagios/nagiostv/static/js/2.aae1ef69.chunk.js HTTP/1.1" 200 1122319 [13/Oct/2020:18:06:07 -0700] "GET /nagios/nagiostv/client-settings.json?v=1602637567000 HTTP/1.1" 200 1156 [13/Oct/2020:18:06:07 -0700] "GET /nagios/nagiostv/favicon.ico HTTP/1.1" 200 3870 [13/Oct/2020:18:06:07 -0700] "GET /nagios/nagiostv/manifest.json HTTP/1.1" 401 381
NagiosTV accesses the built in JSON cgi files within Nagios web UI to get the data. Change 1.1.1.1 to your Nagios IP address and try loading these URLS
http://1.1.1.1/nagios/cgi-bin/statusjson.cgi?query=servicelist&details=true http://1.1.1.1/nagios/cgi-bin/statusjson.cgi?query=hostlist&details=true
See if those are loading properly. The JSON will be more readable if you test with Firefox since it has JSON pretty printing built in.
Another thing to check is to open Developer Tools -> Network -> XHR in the browser then refresh the page. You should see NagiosTV try to load those and will see if there are errors loading.
The manifest.json 404 is not an issue. We are not using that file
Thanks Chris. Here's the results: https://1.1.1.1/nagios/cgi-bin/statusjson.cgi?query=servicelist&details=true { "format_version": 0, "result": { "query_time": 1603483810000, "cgi": "statusjson.cgi", "user": "USERNAMEHERE", "query": "servicelist", "query_status": "released", "program_start": 1603440009000, "last_data_update": 1603483809000, "type_code": 0, "type_text": "Success", "message": "" }, "data": { "selectors": { }, "servicelist": { } } }
https://1.1.1.1/nagios/cgi-bin/statusjson.cgi?query=hostlist&details=true { "format_version": 0, "result": { "query_time": 1603483916000, "cgi": "statusjson.cgi", "user": "USERNAMEHERE", "query": "hostlist", "query_status": "released", "program_start": 1603440009000, "last_data_update": 1603483909000, "type_code": 0, "type_text": "Success", "message": "" }, "data": { "selectors": { }, "hostlist": { } } }
hm so the APIs are working and you get a response but the hostlist and servicelist are just empty. It seems like something changed maybe with access rights. With that same username you can log in and view the built-in nagios UI and everything is there? Can you try logging in with the main account nagiosadmin
and see if that works?
Logging in with nagiosadmin provides the same qty/numbers/stats: Oct 23, 2020 3:22:06 PMNagiosTV Dash Settings NagiosTV v0.5.7 Charts Filter Monitoring 0 hosts All 0 hosts are UP 0 of 0 hosts are UP (0 hidden) Monitoring 0 services All 0 services are OK 0 of 0 services are OK (0 hidden) Alert History No alerts
Using nagiosadmin or the same account I used in the test from earlier today - is the same account I typically use to not only view but also manage services/hosts/etc. in Nagios. Thanks!
Since the APIs are working but not reporting any host or service data, it seems like some issue with Nagios itself. Since I do not own Nagios XI I cannot use their support forums. Can you check those forums and post about these APIs not returning data and share the URLs you are fetching.
Just submitted a 'ticket' via the forums! Will update as they come in. Thanks for the help!
For whatever reason they had me try with nagiosadmin creds and now it loads just fine. I could have sworn I tried that and it didn't work - more than once.... sigh
Great! Can you close this issue if you are back in business?
Go for it. Thanks!
On Nov 10, 2020, at 18:45, Chris Carey notifications@github.com wrote:
Great! Can you close this issue if you are back in business?
— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.
Not sure where to look but nothing loads in TV. Tried going back prior versions that were working but seems like a XI update broke TV. Not sure when due to the lack of use during COVID....
TV shows: Monitoring 0 hosts All 0 hosts are UP 0 of 0 hosts are UP (0 hidden) Monitoring 0 services All 0 services are OK 0 of 0 services are OK (0 hidden) Alert History No alerts
Where as Nagios shows:
15 | 15 | 2120
Where should I look to help troubleshoot? Thanks!