Home » Categories » Products » Nagios XI » Documentation » Developer Tools

Nagios XI - Configure PHP Development Environment

Overview

If you are going to develop addons for Nagiox XI you will need your PHP environment configured to help you with this. This document describes some setting to help you configure your environment to extend Nagios XI with PHP.

 

 

Editing Files

In many steps of this article you will be required to edit files. This documentation will use the vi text editor. When using the vi
editor:

  • To make changes press i on the keyboard first to enter insert mode
  • Press Esc to exit insert mode
  • When you have finished, save the changes in vi by typing :wq and press Enter

 

 

php.ini

When developing with PHP you will want to turn on some additional error reporting usually turned off. These changes need to be made to your php.ini file, to determine the location of this file execute the following command:

find /etc -name php.ini

If there are multiple results then the one in the apache directory is the one that needs changing.

 

Edit the file and make the following changes:

error_reporting = E_ALL
display_errors = On
ignore_repeated_errors = On

 

Once these changes are made you will have to restart apache for the changes to take effect using one of the commands below:

 

RHEL 7 | CentOS 7 | Oracle Linux 7

systemctl restart httpd.service

 

Debian | Ubuntu 16/18

systemctl restart apache2.service

 

You could also log php error to syslog and use Nagios Log server to monitor/capture your php errors.

 

 

Other PHP Resources

PHP php.ini documentation

 

 

Final Thoughts

For any support related questions please visit the Nagios Support Forums at:

http://support.nagios.com/forum/

0 (0)
Article Rating (No Votes)
Rate this article
  • Icon PDFExport to PDF
  • Icon MS-WordExport to MS Word
Attachments Attachments
There are no attachments for this article.
Related Articles RSS Feed
Nagios XI - Leveraging and Understanding Performance Data and Graphs - NWC13
Viewed 5244 times since Thu, Feb 4, 2016
Nagios Core - Writing Custom Nagios Plugins - NWC15
Viewed 5772 times since Mon, Feb 8, 2016
Nagios XI - Custom Wizards, Components and Dashlets - NWC12
Viewed 7945 times since Thu, Feb 4, 2016
Nagios Core - Debugging Nagios Plugins - NWC15
Viewed 4349 times since Mon, Feb 8, 2016
Nagios XI - How To Write Custom Components
Viewed 7106 times since Thu, Jan 28, 2016
Nagios XI - Creating Nagios XI Wizards
Viewed 15090 times since Tue, Feb 3, 2015
Nagios XI - JavaScript and jQuery Tips, Tricks and How-To - NWC14
Viewed 4771 times since Thu, Feb 4, 2016