No respond from API - Nagios XI
Posted: Thu Apr 17, 2025 1:46 am
Hello!
Week ago we found out on our daily jobs that our custom script to scheduling downtime do not work ok.
Its was not doing anything. I found out that API just... not work?
Even in "HELP" the example CURL request:
"curl -XGET "http://X.X.X.X/nagiosxi/api/v1/system/s ... X&pretty=1""
Giving me output like:
And the only which is looks like working is "objects/hoststatus"
But rest from "Config" and "System" Sections are empty after curl request or timeout.
curl -XGET "http://X.X.X.X/nagiosxi/api/v1/config/h ... X&pretty=1"
or
curl -XGET "http://X.X.X.X/nagiosxi/api/v1/config/h ... X&pretty=1"
Can someone point me where i can search what can be reason? Some log or whatever?
I dont know even where to start to searching an issue.
And of course before it was working as usually and it was our basic daily jobs.
Thanks for any respond!
Week ago we found out on our daily jobs that our custom script to scheduling downtime do not work ok.
Its was not doing anything. I found out that API just... not work?
Even in "HELP" the example CURL request:
"curl -XGET "http://X.X.X.X/nagiosxi/api/v1/system/s ... X&pretty=1""
Giving me output like:
Code: Select all
{
"instance_id": null,
"instance_name": "unassigned",
"status_update_time": null,
"program_start_time": null,
"program_run_time": null,
"program_end_time": null,
"is_currently_running": null,
"process_id": null,
"daemon_mode": null,
"last_command_check": null,
"last_log_rotation": null,
"notifications_enabled": null,
"active_service_checks_enabled": null,
"passive_service_checks_enabled": null,
"active_host_checks_enabled": null,
"passive_host_checks_enabled": null,
"event_handlers_enabled": null,
"flap_detection_enabled": null,
"process_performance_data": null,
"obsess_over_hosts": null,
"obsess_over_services": null,
"modified_host_attributes": null,
"modified_service_attributes": null,
"global_host_event_handler": null,
"global_service_event_handler": null
}But rest from "Config" and "System" Sections are empty after curl request or timeout.
curl -XGET "http://X.X.X.X/nagiosxi/api/v1/config/h ... X&pretty=1"
Code: Select all
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<html><head>
<title>504 Gateway Timeout</title>
</head><body>
<h1>Gateway Timeout</h1>
<p>The gateway did not receive a timely response
from the upstream server or application.</p>
</body></html>curl -XGET "http://X.X.X.X/nagiosxi/api/v1/config/h ... X&pretty=1"
Code: Select all
{
}I dont know even where to start to searching an issue.
And of course before it was working as usually and it was our basic daily jobs.
Thanks for any respond!