500 error after upgrade to 5.4.10

This support forum board is for support questions relating to Nagios XI, our flagship commercial network monitoring solution.
Locked
krutaw
Posts: 60
Joined: Wed Jul 31, 2013 6:30 pm

500 error after upgrade to 5.4.10

Post by krutaw »

When upgrading NagiosXI 5.4.9 -> NagiosXI 5.4.10 on CentOS 7.4.1708, I encountered a 500 error listing the following errors in /var/log/httpd/ssl_error_log:

[Thu Sep 21 00:59:53.210883 2017] [:error] [pid 27058] [client 10.150.73.108:60598] PHP Warning: Unknown: failed to open stream: Permission denied in Unknown on line 0, referer: https://ashentlmon-d01.advisory.com/nag ... splash.php
[Thu Sep 21 00:59:53.210908 2017] [:error] [pid 27058] [client 10.150.73.108:60598] PHP Fatal error: Unknown: Failed opening required '/usr/local/nagiosxi/html/ajaxhelper.php' (include_path='.:/usr/share/pear:/usr/share/php') in Unknown on line 0, referer: https://ashentlmon-d01.advisory.com/nag ... splash.php
[Thu Sep 21 00:59:53.211571 2017] [:error] [pid 27059] [client 10.150.73.108:60600] PHP Warning: Unknown: failed to open stream: Permission denied in Unknown on line 0, referer: https://ashentlmon-d01.advisory.com/nag ... splash.php
[Thu Sep 21 00:59:53.211595 2017] [:error] [pid 27059] [client 10.150.73.108:60600] PHP Fatal error: Unknown: Failed opening required '/usr/local/nagiosxi/html/ajaxhelper.php' (include_path='.:/usr/share/pear:/usr/share/php') in Unknown on line 0, referer: https://ashentlmon-d01.advisory.com/nag ... splash.php
[Thu Sep 21 00:59:53.212217 2017] [:error] [pid 27554] [client 10.150.73.108:60599] PHP Warning: Unknown: failed to open stream: Permission denied in Unknown on line 0, referer: https://ashentlmon-d01.advisory.com/nag ... splash.php
[Thu Sep 21 00:59:53.212290 2017] [:error] [pid 27554] [client 10.150.73.108:60599] PHP Fatal error: Unknown: Failed opening required '/usr/local/nagiosxi/html/ajaxhelper.php' (include_path='.:/usr/share/pear:/usr/share/php') in Unknown on line 0, referer: https://ashentlmon-d01.advisory.com/nag ... splash.php

I managed to get this working, but figured I'd share for anyone who runs into the same problem. Here's how I fixed the issue:

In the directory where I unpacked the nagiosxi installation tar.gz, I edited install-templates (this was the last file executed before the error occurred) from:

# Reconfigure Nagios
(
cd "$proddir/scripts"
./reconfigure_nagios.sh
)


TO:

# Reconfigure Nagios
(
cd "$proddir/scripts"
chmod -R 755 /usr/local/nagiosxi/html *
service httpd restart
./reconfigure_nagios.sh
)

Now, of course this is sub-optimal, but indeed it did let me get past the actual error. Hope this helps someone. :)
scottwilkerson
DevOps Engineer
Posts: 19396
Joined: Tue Nov 15, 2011 3:11 pm
Location: Nagios Enterprises
Contact:

Re: 500 error after upgrade to 5.4.10

Post by scottwilkerson »

Thanks for sharing @krutaw! We will lookout for others affected by this.
Former Nagios employee
Creator:
Human Design Website
Get Your Human Design Chart
Locked