php errors with Nagios XI on Debian
Posted: Mon Jan 10, 2011 11:06 pm
Hi All...
I know installing Nagios XI on Debian is not officially supported, but I've decided to have a go.
I have managed to install what I think are all of the required patches and execute the install scripts with a couple of modifications (apache user and a couple of paths in the init.sh file). What I currently have is an installation that I can login to and navigate through. If I want to make any changes to anything eg add a host or service, I work my way through the wizard and begin to get "Invalid Argument supplied" errors relating to the use of foreach() in a number of php files.
After a quick look, it appears that the php file is expecting data in the form of an array and it is not getting an array.
Some examples are:
On the Service Status page - Warning: Invalid argument supplied for foreach() in /usr/local/nagiosxi/html/includes/components/xicore/ajaxhelpers-servicestatus.inc.php on line 361
Step 5 of the Generic Network Device Monitoring Wizard in the Other Individual Contacts box - Warning: Invalid argument supplied for foreach() in /usr/local/nagiosxi/html/config/monitoringwizard.php on line 859
Step 5 of the Generic Network Device Monitoring Wizard in the Specific contact groups box - Warning: Invalid argument supplied for foreach() in /usr/local/nagiosxi/html/config/monitoringwizard.php on line 882
Step 6 of the Generic Network Device Monitoring Wizard in the Host Groups box - Warning: Invalid argument supplied for foreach() in /usr/local/nagiosxi/html/config/monitoringwizard.php on line 1182
Step 6 of the Generic Network Device Monitoring Wizard in the Service Groups box - Warning: Invalid argument supplied for foreach() in /usr/local/nagiosxi/html/config/monitoringwizard.php on line 1207
Step 6 of the Generic Network Device Monitoring Wizard in the Parent Host box - Warning: Invalid argument supplied for foreach() in /usr/local/nagiosxi/html/config/monitoringwizard.php on line 1233
Applying the new service - Warning: Invalid argument supplied for foreach() in /usr/local/nagiosxi/html/includes/configwizards/genericnetdevice/genericnetdevice.inc.php on line 243
I would greatly appreciate any assistance with overcoming these errors. I suspect it will be something simple for someone who knows the back end code.
Andrew Nicolson
http://www.fdc.net.nz
I know installing Nagios XI on Debian is not officially supported, but I've decided to have a go.
I have managed to install what I think are all of the required patches and execute the install scripts with a couple of modifications (apache user and a couple of paths in the init.sh file). What I currently have is an installation that I can login to and navigate through. If I want to make any changes to anything eg add a host or service, I work my way through the wizard and begin to get "Invalid Argument supplied" errors relating to the use of foreach() in a number of php files.
After a quick look, it appears that the php file is expecting data in the form of an array and it is not getting an array.
Some examples are:
On the Service Status page - Warning: Invalid argument supplied for foreach() in /usr/local/nagiosxi/html/includes/components/xicore/ajaxhelpers-servicestatus.inc.php on line 361
Step 5 of the Generic Network Device Monitoring Wizard in the Other Individual Contacts box - Warning: Invalid argument supplied for foreach() in /usr/local/nagiosxi/html/config/monitoringwizard.php on line 859
Step 5 of the Generic Network Device Monitoring Wizard in the Specific contact groups box - Warning: Invalid argument supplied for foreach() in /usr/local/nagiosxi/html/config/monitoringwizard.php on line 882
Step 6 of the Generic Network Device Monitoring Wizard in the Host Groups box - Warning: Invalid argument supplied for foreach() in /usr/local/nagiosxi/html/config/monitoringwizard.php on line 1182
Step 6 of the Generic Network Device Monitoring Wizard in the Service Groups box - Warning: Invalid argument supplied for foreach() in /usr/local/nagiosxi/html/config/monitoringwizard.php on line 1207
Step 6 of the Generic Network Device Monitoring Wizard in the Parent Host box - Warning: Invalid argument supplied for foreach() in /usr/local/nagiosxi/html/config/monitoringwizard.php on line 1233
Applying the new service - Warning: Invalid argument supplied for foreach() in /usr/local/nagiosxi/html/includes/configwizards/genericnetdevice/genericnetdevice.inc.php on line 243
I would greatly appreciate any assistance with overcoming these errors. I suspect it will be something simple for someone who knows the back end code.
Andrew Nicolson
http://www.fdc.net.nz