Authentication problem
Re: Authentication problem
</virtualhost> instead </VirtualHost> is a transcription error, in the nagios.conf file is </VirtualHost>
I have modified www.mydomain.it/nagios in nagios.mydomain.it and works, but don't ask user e password and appear "Logged in as ?", when click to host and services "It appears as though you do not have permission to view information for any of the services you requested..."
Same error....
I have modified www.mydomain.it/nagios in nagios.mydomain.it and works, but don't ask user e password and appear "Logged in as ?", when click to host and services "It appears as though you do not have permission to view information for any of the services you requested..."
Same error....
-
sreinhardt
- -fno-stack-protector
- Posts: 4366
- Joined: Mon Nov 19, 2012 12:10 pm
Re: Authentication problem
If you didn't have to login, apache would be unable to pass a user variable to the cgi's. Is this the only virtual host defined for port 80 on your system? Do you still have a separate htaccess file, or has that been entirely removed? Sorry if I missed that one, just want to be 100% sure we are on the same page. Otherwise your nagios.cfg for apache looks great!
Nagios-Plugins maintainer exclusively, unless you have other C language bugs with open-source nagios projects, then I am happy to help! Please pm or use other communication to alert me to issues as I no longer track the forum.
Re: Authentication problem
Not have .htaccess file in nagios directory and only one domain in registered in port 80
-
scottwilkerson
- DevOps Engineer
- Posts: 19396
- Joined: Tue Nov 15, 2011 3:11 pm
- Location: Nagios Enterprises
- Contact:
Re: Authentication problem
Can we see the current nagios.conf
Re: Authentication problem
Code: Select all
<VirtualHost *:80>
ServerAdmin webmaster@localhost
ServerName nagios.mydomain.it
ServerAlias nagios.mydomain.it
DocumentRoot /usr/local/nagios/share
ErrorLog /var/log/httpd/error_nagios.log
ScriptAlias /nagios/cgi-bin "/usr/local/nagios/sbin"
<Directory "/usr/local/nagios/sbin">
# SSLRequireSSL
Options ExecCGI
AllowOverride None
Order allow,deny
Allow from all
# Order deny,allow
# Deny from all
# Allow from 127.0.0.1
AuthName "Nagios Access"
AuthType Basic
AuthUserFile /usr/local/nagios/etc/htpasswd.users
Require valid-user
</Directory>
Alias /nagios "/usr/local/nagios/share"
<Directory "/usr/local/nagios/share">
# SSLRequireSSL
Options None
AllowOverride None
Order allow,deny
Allow from all
# Order deny,allow
# Deny from all
# Allow from 127.0.0.1
AuthName "Nagios Access"
AuthType Basic
AuthUserFile /usr/local/nagios/etc/htpasswd.users
Require valid-user
</Directory>
</VirtualHost>
-
scottwilkerson
- DevOps Engineer
- Posts: 19396
- Joined: Tue Nov 15, 2011 3:11 pm
- Location: Nagios Enterprises
- Contact:
Re: Authentication problem
and you are accessing this host via http://nagios.mydomain.it/nagios/ correct? Not via IP...
Re: Authentication problem
yes, nagios.mydomain.it or nagios.mydomain.it/nagios not ip, is a virtual host
Re: Authentication problem
This is getting stranger and stranger. I hate to sound like we're passing you off, but have you posted about this on one of the Apache support forums?
http://www.apachelounge.com/
http://www.webmasterworld.com/apache/
We're happy to keep trying here, but you honestly might have better luck in a forum dedicated to Apache where they would know these configs inside and out.
http://www.apachelounge.com/
http://www.webmasterworld.com/apache/
We're happy to keep trying here, but you honestly might have better luck in a forum dedicated to Apache where they would know these configs inside and out.
Former Nagios employee
Re: Authentication problem
I'm looking at your Apache httpd.conf and your nagios.conf and they both look okay to me, but I see one line that I don't like. It's not wrong, I just wonder if it might be causing problem.
Whatever your main IP address is ("ifconfig" will show you), then change this line:
To this line:
But replace IPADDRESS with your real IPADDRESS. It shouldn't matter, but I just want to remove variables. I would also like to see the output of the command (as root):
All that being said, I think you're getting way out of Nagios land here as @tmcdonald said. If you can't get it working, I'd say spin up a new EC2 instance, do a yum upgrade, and then install Nagios from source again. It really isn't hard to get it working.
Whatever your main IP address is ("ifconfig" will show you), then change this line:
Code: Select all
NameVirtualHost *:80Code: Select all
NameVirtualHost IPADDRESS:80Code: Select all
httpd -V
httpd -lEric Loyd • http://everwatch.global • 844.240.EVER • @EricLoyd
I'm a Nagios Fanatic! • Join our public Nagios Discord Server!
Re: Authentication problem
httpd -V
httpd -l
ifconfig show the private IP, i enter the private IP or public?
Code: Select all
Server version: Apache/2.2.15 (Unix)
Server built: Feb 7 2012 09:50:11
Server's Module Magic Number: 20051115:24
Server loaded: APR 1.3.9, APR-Util 1.3.9
Compiled using: APR 1.3.9, APR-Util 1.3.9
Architecture: 64-bit
Server MPM: Prefork
threaded: no
forked: yes (variable process count)
Server compiled with....
-D APACHE_MPM_DIR="server/mpm/prefork"
-D APR_HAS_SENDFILE
-D APR_HAS_MMAP
-D APR_HAVE_IPV6 (IPv4-mapped addresses enabled)
-D APR_USE_SYSVSEM_SERIALIZE
-D APR_USE_PTHREAD_SERIALIZE
-D SINGLE_LISTEN_UNSERIALIZED_ACCEPT
-D APR_HAS_OTHER_CHILD
-D AP_HAVE_RELIABLE_PIPED_LOGS
-D DYNAMIC_MODULE_LIMIT=128
-D HTTPD_ROOT="/etc/httpd"
-D SUEXEC_BIN="/usr/sbin/suexec"
-D DEFAULT_PIDLOG="run/httpd.pid"
-D DEFAULT_SCOREBOARD="logs/apache_runtime_status"
-D DEFAULT_LOCKFILE="logs/accept.lock"
-D DEFAULT_ERRORLOG="logs/error_log"
-D AP_TYPES_CONFIG_FILE="conf/mime.types"
-D SERVER_CONFIG_FILE="conf/httpd.conf"Code: Select all
Compiled in modules:
core.c
prefork.c
http_core.c
mod_so.c