We are on a RHEL9 server running NagiosXI 2024R1.2. Things were working prior to the last round of patching. Now Nagios appears to be running okay, and I can login to Core okay, but the login.php for XI does not work. I have so far been unable to find any kind of error message or a log that contains a clue as to what is failing.
Any suggestions are much appreciated.
NagiosXI login page stopped working after OS patching
Re: NagiosXI login page stopped working after OS patching
Hello @BenCowan,
So you're saying that you are unable to log in, but there are no indicators that anything is wrong?
Does the page do nothing when you try to log in?
Can you check the console in developer tools? Can you check /usr/local/nagiosxi/var/cmdsubsys.log?
So you're saying that you are unable to log in, but there are no indicators that anything is wrong?
Does the page do nothing when you try to log in?
Can you check the console in developer tools? Can you check /usr/local/nagiosxi/var/cmdsubsys.log?
Actively advancing awesome answers with ardent alliteration, aptly addressing all ambiguities. Amplify your acumen and avail our amicable assistance. Eagerly awaiting your astute assessments of our advice.
Re: NagiosXI login page stopped working after OS patching
I did find this in /var/log/httpd/ssl_error_log:
[Wed Oct 02 13:17:25.413992 2024] [php:warn] [pid 1428808:tid 1428808] [client 207.197.39.4:52933] PHP Warning: session_start(): open(/var/lib/php/session/sess_bnuetr7pvtlpt0td8096cblfpq, O_RDWR) failed: Permission denied (13) in /app/nagios/nagiosxi/html/includes/utils.inc.php on line 133, referer: https://nagios.scs.nevada.edu/nagiosxi/login.php
[Wed Oct 02 13:17:25.414031 2024] [php:warn] [pid 1428808:tid 1428808] [client 207.197.39.4:52933] PHP Warning: session_start(): Failed to read session data: files (path: /var/lib/php/session) in /app/nagios/nagiosxi/html/includes/utils.inc.php on line 133, referer: https://nagios.scs.nevada.edu/nagiosxi/login.php
[Wed Oct 02 13:17:25.413992 2024] [php:warn] [pid 1428808:tid 1428808] [client 207.197.39.4:52933] PHP Warning: session_start(): open(/var/lib/php/session/sess_bnuetr7pvtlpt0td8096cblfpq, O_RDWR) failed: Permission denied (13) in /app/nagios/nagiosxi/html/includes/utils.inc.php on line 133, referer: https://nagios.scs.nevada.edu/nagiosxi/login.php
[Wed Oct 02 13:17:25.414031 2024] [php:warn] [pid 1428808:tid 1428808] [client 207.197.39.4:52933] PHP Warning: session_start(): Failed to read session data: files (path: /var/lib/php/session) in /app/nagios/nagiosxi/html/includes/utils.inc.php on line 133, referer: https://nagios.scs.nevada.edu/nagiosxi/login.php
Re: NagiosXI login page stopped working after OS patching
I’ve had similar issues before after updates. Have you tried clearing your browser cache or using a different one? That sometimes does the trick. Also, check the Apache error logs in /var/log/httpd/—they might give you some hints about what’s going wrong. And don't forget to look at the file permissions for Nagios XI; sometimes patches can mess those up, and a reset might help.
Re: NagiosXI login page stopped working after OS patching
Yes, I've tried all the browser cache clearing and various browsers. The only error message I've found in the logs is the one I mentioned above. There does appear to be a permissions problem on the sess directory or file in /var/lib/php/session/sess*, but I can't make sense of it, or something has changed that makes ../includes/utils.inc.php not function properly. 
Re: NagiosXI login page stopped working after OS patching
BenCowan,
This reads like XI doesn't have permission to write a session file. If you can't start a session, you can't login.
Does your XI have write permissions to the /tmp directory? That's the default session write location for PHP. I'm not 100% sure that's what XI will use, but it's the first place I'd look. I'll dig in on our end to determine if we don't use the default location.
Best Regards,
Cory Norell
This reads like XI doesn't have permission to write a session file. If you can't start a session, you can't login.
Does your XI have write permissions to the /tmp directory? That's the default session write location for PHP. I'm not 100% sure that's what XI will use, but it's the first place I'd look. I'll dig in on our end to determine if we don't use the default location.
Best Regards,
Cory Norell
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.
- jmichaelson
- Posts: 375
- Joined: Wed Aug 23, 2023 1:02 pm
Re: NagiosXI login page stopped working after OS patching
what are the owner/group and permissions on the /var/lib/php/session/ directory?
Please let us know if you have any other questions or concerns.
-Jason
-Jason
Re: NagiosXI login page stopped working after OS patching
drwxrwx---. 2 root root 4096 Jul 31 00:18 session
I tested changing to 0777 and that worked, so then changed back to 0770, but changed the group owner to apache and that works also. So I think I'm good.
I tested changing to 0777 and that worked, so then changed back to 0770, but changed the group owner to apache and that works also. So I think I'm good.
RESOLVED: NagiosXI login page stopped working after OS patching
BenCowan,
Glad to hear you got this resolved. I'm going to mark the thread as such and lock the topic. If you need anything else don't hesitate to open a new thread.
Best Regards,
Cory Norell
Glad to hear you got this resolved. I'm going to mark the thread as such and lock the topic. If you need anything else don't hesitate to open a new thread.
Best Regards,
Cory Norell
As of May 25th, 2018, all communications with Nagios Enterprises and its employees are covered under our new Privacy Policy.