Page 1 of 2
Php error message on "Host and Services Status" pages
Posted: Wed Nov 23, 2016 7:34 am
by evisus
Hi.
I have updated a nagios XI version 2012R2.4 installed in a Centos 6.8, the update has been passing version by version until reaching Nagios XI 5.3.3. So far everything looks fine, there is only one php error message in the host and services status pages and in the apache error log:
"Undefined variable: url_target in /usr/local/nagiosxi/html/includes/utilsl.inc.php"
I will appreciate your help in identifying the problem.
Attached image
Data:
-General 6.8
-Php Version: 5.3.3
-Apache 2.2.15
-Mysql 14.14 Distrib 5.1.69
-postgres 8.4.13
Thank you
Re: Php error message on "Host and Services Status" pages
Posted: Wed Nov 23, 2016 12:27 pm
by mcapra
My best guess is that the message about enterprise license expiration is trying to be displayed, but causing an error for some reason. If you aren't noticing any issues, it's probably just a visual glitch.
I would re-download the latest XI tarball and pull the nagiosxi/basedir/html/includes/utilsl.inc.php file out and replace the corresponding file on your XI installation (/usr/local/nagiosxi/html/includes/utilsl.inc.php). Just in-case that file was missed in the upgrade process for some reason. Be sure to backup the original file before doing this.
Re: Php error message on "Host and Services Status" pages
Posted: Mon Nov 28, 2016 9:00 am
by evisus
thanks for your reply.
I have backed and replaced the php files and the error persists.
Will there be another cause?
Re: Php error message on "Host and Services Status" pages
Posted: Mon Nov 28, 2016 11:53 am
by evisus
A detail I have not mentioned:
The original installation is a vmware appliance, Nagios has been updated offline, the server does not have internet access
Re: Php error message on "Host and Services Status" pages
Posted: Mon Nov 28, 2016 2:36 pm
by ssax
Please run this command and send me the resulting
/tmp/files.zip:
Code: Select all
zip -r /tmp/files.zip /etc/httpd/conf/httpd.conf /etc/php.ini /usr/local/nagiosxi/html/includes/db.inc.php
Thank you
Re: Php error message on "Host and Services Status" pages
Posted: Mon Nov 28, 2016 3:37 pm
by evisus
attach the file
Thanks
Re: Php error message on "Host and Services Status" pages
Posted: Mon Nov 28, 2016 4:42 pm
by ssax
Please send me the output of this command:
Re: Php error message on "Host and Services Status" pages
Posted: Tue Nov 29, 2016 7:43 am
by evisus
Hi!!
this is the result
Code: Select all
display_errors=> STDOUT => STDOUT
display_startup_errors => Off => Off
error_append_string => no value => no value
error_log => no value => no value
error_prepend_string => no value => no value
error_reporting => 22527 => 22527
html_errors => Off => Off
ignore_repeated_errors => Of => Off
log_errors => On => On
Log_errors_max_len => 1024 => 1024
track_errors => Off => Off
xmlrpc_error_number => 0 => 0
xmlrpc_errors => Off => Off
mssql.min_error_severety => 10 => 10
Thanks
Re: Php error message on "Host and Services Status" pages
Posted: Tue Nov 29, 2016 1:13 pm
by evisus
I will appreciate your help.
Re: Php error message on "Host and Services Status" pages
Posted: Tue Nov 29, 2016 2:56 pm
by evisus
I have encountered other php errors like:
SNMP Wizard page:
"Warning: base64_decode () expects parameter 1 to be string, array given in /usr/local/nagiosxi/html/includes/utilsl.inc.php on line 3450"
On the "Operation Center" page when selecting a group:
"Notice: Undefined variable: host_ids in /usr/local/nagiosxi/html/includes/components/nocscreen/nocscreenapi.php on line 333 Warning: Invalid argument supplied for foreach() in /usr/local/nagiosxi/html/includes/components/nocscreen/nocscreenapi.php on line 333 Notice: Undefined variable: host_ids_str in /usr/local/nagiosxi/html/includes/components/nocscreen/nocscreenapi.php on line 343 Notice: Undefined variable: host_ids_str in /usr/local/nagiosxi/html/includes/components/nocscreen/nocscreenapi.php on line 437
Notice: Undefined variable: host_ids in /usr/local/nagiosxi/html/includes/components/nocscreen/nocscreenapi.php on line 146 Warning: Invalid argument supplied for foreach() in /usr/local/nagiosxi/html/includes/components/nocscreen/nocscreenapi.php on line 146 Notice: Undefined variable: host_ids_str in /usr/local/nagiosxi/html/includes/components/nocscreen/nocscreenapi.php on line 156
"
I will really be grateful for your support.