Page 1 of 1

Continuous errors on httpd/error.log

Posted: Tue Apr 07, 2020 1:54 pm
by IGDCMont
Hi Team,

Getting following errors on httpd/error.log. Could you please help on this.

Code: Select all

[Tue Apr 07 12:48:00 2020] [error] [client xx.xx.xx.xx] PHP Warning:  Invalid argument supplied for foreach() in /usr/local/nagiosxi/html/includes/components/nagiosim/nagiosim.inc.php on line 491, referer: http://xx.xx.xx.xx/nagiosxi/dashboards/
[Tue Apr 07 12:48:02 2020] [error] [client xx.xx.xx.xx​] PHP Warning:  Invalid argument supplied for foreach() in /usr/local/nagiosxi/html/includes/components/nagiosim/nagiosim.inc.php on line 491, referer: http://xx.xx.xx.xx/nagiosxi/dashboards/dashboard.php?&=
[Tue Apr 07 12:48:02 2020] [error] [client xx.xx.xx.xx​] PHP Warning:  Invalid argument supplied for foreach() in /usr/local/nagiosxi/html/includes/components/nagiosim/nagiosim.inc.php on line 491, referer: http://xx.xx.xx.xx/nagiosxi/dashboards/dashboard.php?&=
[Tue Apr 07 12:48:02 2020] [error] [client x.xx.xx.xx​] PHP Warning:  Invalid argument supplied for foreach() in /usr/local/nagiosxi/html/includes/components/nagiosim/nagiosim.inc.php on line 491, referer: http://xx.xx.xx.xx/nagiosxi/dashboards/dashboard.php?&=
[Tue Apr 07 12:48:02 2020] [error] [client xx.xx.xx.xx​] PHP Warning:  Invalid argument supplied for foreach() in /usr/local/nagiosxi/html/includes/components/nagiosim/nagiosim.inc.php on line 491, referer: http://xx.xx.xx.xx/nagiosxi/dashboards/dashboard.php?&=
[Tue Apr 07 12:48:02 2020] [error] [client xx.xx.xx.xx​] PHP Warning:  Invalid argument supplied for foreach() in /usr/local/nagiosxi/html/includes/components/nagiosim/nagiosim.inc.php on line 491, referer: http://xx.xx.xx.xx/nagiosxi/dashboards/dashboard.php?&=
[Tue Apr 07 12:48:02 2020] [error] [client xx.xx.xx.xx​] PHP Warning:  Invalid argument supplied for foreach() in /usr/local/nagiosxi/html/includes/components/nagiosim/nagiosim.inc.php on line 491, referer: http://xx.xx.xx.xx/nagiosxi/dashboards/dashboard.php?&=
[Tue Apr 07 12:48:02 2020] [error] [client xx.xx.xx.xx​] PHP Notice:  Use of undefined constant Servicegroup - assumed 'Servicegroup' in /usr/local/nagiosxi/html/includes/components/bbmap/bbmap.inc.php on line 195, referer: http://xx.xx.xx.xx/nagiosxi/dashboards/dashboard.php?&=
[Tue Apr 07 12:48:02 2020] [error] [client xx.xx.xx.xx​] PHP Notice:  Use of undefined constant Servicegroup - assumed 'Servicegroup' in /usr/local/nagiosxi/html/includes/components/bbmap/bbmap.inc.php on line 195, referer: http://xx.xx.xx.xx/nagiosxi/dashboards/dashboard.php?&=
[Tue Apr 07 12:48:02 2020] [error] [client xx.xx.xx.xx​] PHP Notice:  Use of undefined constant Servicegroup - assumed 'Servicegroup' in /usr/local/nagiosxi/html/includes/components/bbmap/bbmap.inc.php on line 195, referer: http://xx.xx.xx.xx/nagiosxi/dashboards/dashboard.php?&=

Re: Continuous errors on httpd/error.log

Posted: Tue Apr 07, 2020 3:44 pm
by jbrunkow
One of those errors is coming from the Nagios IM component, which is deprecated. It can be safely deleted using the command below.

Code: Select all

rm -rf /usr/local/nagiosxi/html/includes/components/nagiosim
USE CAUTION WHEN DELETING ( rm -rf _____ )

The other error message is merely a PHP Notice, and is not critical. A notice is considered a minor error in PHP. You can turn notices off by changing your display_errors to 0 in your php.ini configuration file.
https://stackoverflow.com/questions/286 ... hp-notices

If you do want to look in to the issue further, it looks like those errors are pointing to the nagiosim and bbmap components, specifically lines 491 and 195 of the nagiosim.inc and bbmap.inc PHP files respectively. If we can look at those lines in the files, we may be able to determine what "Invalid arguments" were supplied, or what "constant Servicegroup" is undefined.