Page 1 of 1
NagiosXI login page stopped working after OS patching
Posted: Wed Oct 02, 2024 3:29 pm
by BenCowan
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.
Re: NagiosXI login page stopped working after OS patching
Posted: Wed Oct 02, 2024 4:20 pm
by bbahn
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?
Re: NagiosXI login page stopped working after OS patching
Posted: Thu Oct 03, 2024 4:38 pm
by BenCowan
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
Re: NagiosXI login page stopped working after OS patching
Posted: Fri Oct 04, 2024 10:43 am
by irfansst
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
Posted: Fri Oct 04, 2024 2:41 pm
by BenCowan
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
Posted: Fri Oct 04, 2024 4:20 pm
by cnorell
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
Re: NagiosXI login page stopped working after OS patching
Posted: Fri Oct 04, 2024 4:29 pm
by jmichaelson
what are the owner/group and permissions on the /var/lib/php/session/ directory?
Re: NagiosXI login page stopped working after OS patching
Posted: Sat Oct 05, 2024 7:23 pm
by BenCowan
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.
RESOLVED: NagiosXI login page stopped working after OS patching
Posted: Thu Oct 10, 2024 9:34 am
by cnorell
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