Page 5 of 6

Re: Web interface time out

Posted: Fri Jan 24, 2014 2:52 pm
by rlevick
[root@localhost ~]# httpd -S
VirtualHost configuration:
Syntax OK
[root@localhost ~]#

Re: Web interface time out

Posted: Fri Jan 24, 2014 3:04 pm
by abrist
Your apache server is not using *any* vhost files. Have you made any changes to the httpd.conf file? Or any changes to the apache configuration in general?

Re: Web interface time out

Posted: Fri Jan 24, 2014 3:32 pm
by rlevick
just the commands suggested earlier
usermod -a -G nagios apache
usermod -a -G nagios nagios

Re: Web interface time out

Posted: Mon Jan 27, 2014 11:53 am
by abrist
Are you including the vhost files in your httpd conf?

Code: Select all

grep Include /etc/httpd/conf/httpd.conf

Re: Web interface time out

Posted: Mon Jan 27, 2014 11:59 am
by scottwilkerson
Lets

Code: Select all

chown nagios:nagios /usr/local/nagios
also, lets make sure apache is part of the nagios group

Code: Select all

cat /etc/group|grep nagios

Re: Web interface time out

Posted: Mon Jan 27, 2014 4:38 pm
by rlevick
[root@localhost conf]# grep Include /etc/httpd/conf/httpd.conf
Include conf.d/*.conf
# Indexes Includes FollowSymLinks SymLinksifOwnerMatch ExecCGI MultiViews
# Options MultiViews Indexes SymLinksIfOwnerMatch IncludesNoExec
# (You will also need to add "Includes" to the "Options" directive.)
Options IncludesNoExec
AddOutputFilter Includes html
[root@localhost conf]# chown nagios:nagios /usr/local/nagios
[root@localhost conf]# cat /etc/group|grep nagios
nagios:x:501:apache,nagios
nagcmd:x:502:nagios,apache
[root@localhost conf]#

Re: Web interface time out

Posted: Tue Jan 28, 2014 1:43 pm
by abrist
I am running out of ideas. Can you curl the nagios page?

Code: Select all

curl 127.0.0.1/nagios
You should get "authorization required"

Re: Web interface time out

Posted: Wed Jan 29, 2014 9:24 am
by rlevick
[root@com-vfcmon-01 ~]# curl 127.0.0.1/nagios
<!DOCTYPE HTML PUBLIC "-//IETF//DTD HTML 2.0//EN">
<html><head>
<title>401 Authorization Required</title>
</head><body>
<h1>Authorization Required</h1>
<p>This server could not verify that you
are authorized to access the document
requested. Either you supplied the wrong
credentials (e.g., bad password), or your
browser doesn't understand how to supply
the credentials required.</p>
<hr>
<address>Apache/2.2.15 (CentOS) Server at 127.0.0.1 Port 80</address>
</body></html>
[root@com-vfcmon-01 ~]#

Re: Web interface time out

Posted: Wed Jan 29, 2014 11:15 am
by abrist
hmmm. So when you browse to:
http://<nagios server ip>/nagios/index.php
Do you get a password prompt?

Re: Web interface time out

Posted: Wed Jan 29, 2014 11:29 am
by rlevick
I found the problem. It was the firewall on the server. I added a line with the command:
iptables -I INPUT 5 -i eth0 -p tcp --dport 80 -m state --state NEW,ESTABLISHED -j ACCEPT

Even though I had the line in the iptable:
-A INPUT -p tcp -m state --state NEW -m tcp --dport 80 -j ACCEPT
It wasn't working.
Thanks for all the input.