Page 2 of 2

Re: PNP4Nagios Install Error

Posted: Wed Jan 23, 2019 4:38 pm
by vivification
No problems, see the output below.


[root@localhost httpd]# cat /etc/httpd/conf.d/pnp4nagios.conf
# SAMPLE CONFIG SNIPPETS FOR APACHE WEB SERVER

Alias /pnp4nagios "/usr/local/pnp4nagios/share"

<Directory "/usr/local/pnp4nagios/share">
AllowOverride None
Order allow,deny
Allow from all
#
# Use the same value as defined in nagios.conf
#
AuthName "Nagios Access"
AuthType Basic
AuthUserFile /usr/local/nagios/etc/htpasswd.users
Require valid-user
<IfModule mod_rewrite.c>
# Turn on URL rewriting
RewriteEngine On
Options symLinksIfOwnerMatch
# Installation directory
RewriteBase /pnp4nagios/
# Protect application and system files from being viewed
RewriteRule "^(?:application|modules|system)/" - [F]
# Allow any files or directories that exist to be displayed directly
RewriteCond "%{REQUEST_FILENAME}" !-f
RewriteCond "%{REQUEST_FILENAME}" !-d
# Rewrite all other URLs to index.php/URL
RewriteRule "^.*$" "index.php/$0" [PT]
</IfModule>
</Directory>
[root@localhost httpd]#

Re: PNP4Nagios Install Error

Posted: Wed Jan 23, 2019 4:48 pm
by scottwilkerson
Based on this config, you would access the graphs at

Code: Select all

http://192.168.1.26/pnp4nagios
not

Code: Select all

http://192.168.1.26/nagios/pnp4nagios

Re: PNP4Nagios Install Error

Posted: Wed Jan 23, 2019 4:54 pm
by vivification
Thank you - if I change

Code: Select all

RewriteBase /pnp4nagios/


to

Code: Select all

RewriteBase /nagios/pnp4nagios/


Would that make it http://192.168.1.26/nagios/pnp4nagios ?

Re: PNP4Nagios Install Error

Posted: Wed Jan 23, 2019 4:59 pm
by scottwilkerson
as well as changing

Code: Select all

Alias /pnp4nagios "/usr/local/pnp4nagios/share"
to

Code: Select all

Alias /nagios/pnp4nagios "/usr/local/pnp4nagios/share"
then restarting httpd

Code: Select all

systemctl restart httpd

Re: PNP4Nagios Install Error

Posted: Wed Jan 23, 2019 5:05 pm
by vivification
Great thank you very much for your help. I really appreciate it.

Re: PNP4Nagios Install Error

Posted: Wed Jan 23, 2019 5:12 pm
by scottwilkerson
vivification wrote:Great thank you very much for your help. I really appreciate it.
May we lock the thread?

Re: PNP4Nagios Install Error

Posted: Wed Jan 23, 2019 5:17 pm
by vivification
Yes no problems thanks.

Re: PNP4Nagios Install Error

Posted: Wed Jan 23, 2019 5:19 pm
by scottwilkerson
vivification wrote:Yes no problems thanks.
Great! Locking