Review File Locations
There are a number of files that you should review, both their location and their content. It is important that you review these because if you change a file location you may have to modify a number of additional files that depend on that location.
An archives directory is created in /var/log/nagios3 and the main log is here:
The apache file contains the settings necessary for the web interface. The stylesheets provides css files that can be used to modify the settings for the web interface. These are found in /etc/nagios3/stylesheets. The password database the web interface will look for is htpasswd.users be sure to update the apache file if you change the name of that file.
# apache configuration for nagios 3.x
ScriptAlias /cgi-bin/nagios3 /usr/lib/cgi-bin/nagios3
ScriptAlias /nagios3/cgi-bin /usr/lib/cgi-bin/nagios3
Alias /nagios3/stylesheets /etc/nagios3/stylesheets
Alias /nagios3 /usr/share/nagios3/htdocs
Allow From All
AuthName “Nagios Access”
The cgi.cfg file contains the information used for authentication to the web interface. Note that the user who can view all of the information is “nagiosadmin”. Be sure create that user in your database(htpasswd.users) or change the user to meet your needs.
The directory /etc/nagios3/conf.d contains much of the information needed for modify objects.
Review the contents of each of these files. If you change the name of any you will need to make changes to at least the nagios.cfg, possibly others.
The commands.cfg includes some of the basic commands. However, Ubuntu places most of the definitions in a separate directory which you see listed. Many of the commands that you will want to use are located here and when you open each cfg up you will see specific examples of pre-created commands.
That covers the basic file locations, be sure to review these as they will be very important for your system development.