[Solved] Can't connect to the web page

Support forum for Nagios Core, Nagios Plugins, NCPA, NRPE, NSCA, NDOUtils and more. Engage with the community of users including those using the open source solutions.
jbruyet
Posts: 235
Joined: Wed Dec 28, 2011 12:14 pm

Re: Can't connect to the web page

Post by jbruyet »

Sorry for the long delay. I did a fresh install of CentOS 6.5, installed Nagios using the link listed in an earlier post, tried to access the web page and chrome gave me this (with and without /nagios):

Code: Select all

Oops! Google Chrome could not connect to 192.168.2.25
I have several httpd processes running:

Code: Select all

[root@FreeNag ~]# ps aux | grep httpd
root      6823  0.0  0.1 235276  8292 ?        Ss   May13   0:00 /usr/sbin/httpd
apache    6865  0.0  0.0 235276  5504 ?        S    May13   0:00 /usr/sbin/httpd
apache    6866  0.0  0.0 235276  5504 ?        S    May13   0:00 /usr/sbin/httpd
apache    6867  0.0  0.0 235276  5504 ?        S    May13   0:00 /usr/sbin/httpd
apache    6868  0.0  0.0 235276  5504 ?        S    May13   0:00 /usr/sbin/httpd
apache    6869  0.0  0.0 235276  5504 ?        S    May13   0:00 /usr/sbin/httpd
apache    6870  0.0  0.0 235276  5504 ?        S    May13   0:00 /usr/sbin/httpd
apache    6871  0.0  0.0 235276  5504 ?        S    May13   0:00 /usr/sbin/httpd
apache    6872  0.0  0.0 235276  5504 ?        S    May13   0:00 /usr/sbin/httpd
root     14853  0.0  0.0 103256   824 pts/0    S+   09:18   0:00 grep httpd
[root@FreeNag ~]#
Selinux has been disabled:

Code: Select all

[root@FreeNag ~]# getenforce
Disabled
[root@FreeNag ~]#
and the only open port is 22:

Code: Select all

Nmap scan report for freenag.domain.com (192.168.2.25)

Host is up (0.0013s latency).

Not shown: 65534 filtered ports

PORT   STATE SERVICE

22/tcp open  ssh

MAC Address: 00:19:BB:33:AD:BA (Hewlett-Packard Company)
Is there a "common knowledge" step for getting port 80 open that I may be missing? I won't view ANY responses as condescension so please feel free to "post 'em if you got 'em."

Thanks,

Joe b
jbruyet
Posts: 235
Joined: Wed Dec 28, 2011 12:14 pm

Re: Can't connect to the web page

Post by jbruyet »

From what I'm seeing everything should be working, this and previous diagnostic steps:

Code: Select all

[root@FreeNag ~]# netstat -l | grep http
tcp        0      0 *:http                      *:*                         LISTEN
[root@FreeNag ~]#
Hmmm...

Thanks,

Joe B
User avatar
lmiltchev
Bugs find me
Posts: 13589
Joined: Mon May 23, 2011 12:15 pm

Re: Can't connect to the web page

Post by lmiltchev »

Run:

Code: Select all

iptables -I INPUT -p tcp -m state --state NEW --dport 80 -j ACCEPT
service iptables save
Check iptables to make sure the rule was added:

Code: Select all

iptables -L -n
Be sure to check out our Knowledgebase for helpful articles and solutions!
jbruyet
Posts: 235
Joined: Wed Dec 28, 2011 12:14 pm

Re: Can't connect to the web page

Post by jbruyet »

YES!!!!!! Thank you lmiltchev, that did the trick! I thought it had to be firewall-related but I didn't realize iptables was active by default. Now I can get on with my install.

Thanks again,

Joe B
Locked