Hi. I'm running the get object/status API call on a server that has 5451 services and it fails with the "{server} is currently unable to handle this request" error. This server has 12 CPUs and 32 GB of memory. I've tried using a browser and at the command line.
Another server with the same configuration has 15635 services and it completes.
Both systems are running RHEL 6 and Nagios is 5.4.4.
Any ideas on what to look for?
Thanks!
GET objects/servicestatus cnt 5451 fails 15635 works
-
scottwilkerson
- DevOps Engineer
- Posts: 19396
- Joined: Tue Nov 15, 2011 3:11 pm
- Location: Nagios Enterprises
- Contact:
Re: GET objects/servicestatus cnt 5451 fails 15635 works
You may need to increase the memory_limit in the php.ini and restart httpd
You should be able to confirm if this is the case by tailing the httpd/error_log while attempting to make the API request
You should be able to confirm if this is the case by tailing the httpd/error_log while attempting to make the API request
Code: Select all
tail -f /var/log/httpd/error_logRe: GET objects/servicestatus cnt 5451 fails 15635 works
Hi. It appears that the memory limit is the issue.
The value is currently 128M
Thanks
Code: Select all
[Wed Dec 04 14:35:36 2019] [error] [client 10.10.20.80] PHP Fatal error: Allowed memory size of 134217728 bytes exhausted (tried to allocate 64 bytes) in /usr/local/nagiosxi/html/backend/includes/xml2json.php on line 203
Thanks
-
scottwilkerson
- DevOps Engineer
- Posts: 19396
- Joined: Tue Nov 15, 2011 3:11 pm
- Location: Nagios Enterprises
- Contact:
Re: GET objects/servicestatus cnt 5451 fails 15635 works
I would try to bump this to 256M and restart httpd
Re: GET objects/servicestatus cnt 5451 fails 15635 works
I doubled it to 256. That worked. Thanks!
-
scottwilkerson
- DevOps Engineer
- Posts: 19396
- Joined: Tue Nov 15, 2011 3:11 pm
- Location: Nagios Enterprises
- Contact:
Re: GET objects/servicestatus cnt 5451 fails 15635 works
Great!awilson wrote:I doubled it to 256. That worked. Thanks!
Locking thread