There are several ways to short out this issue,
fist we should check the dns whether the internet is working or not
second we should check the server port whether it open or not
# netstat -ntlp | grep 80
tcp 0 0 0.0.0.0:3306 0.0.0.0:* LISTEN 1802/mysqld
tcp 0 0 127.0.0.1:80 0.0.0.0:* LISTEN 5391/httpd
fist we should check the dns whether the internet is working or not
second we should check the server port whether it open or not
# netstat -ntlp | grep 80
tcp 0 0 0.0.0.0:3306 0.0.0.0:* LISTEN 1802/mysqld
tcp 0 0 127.0.0.1:80 0.0.0.0:* LISTEN 5391/httpd
from above example shows the server open the port 80 only for localhost, so we not able to reach the site from globally
so we need to change that apache configuration
# vi /etc/httpd/conf/httpd.conf //find port 80
#Listen 80
Listen 127.0.0.1:80
#Listen 0.0.0.0:80
#Listen [::]:80
//simply change in to
#Listen 80
#Listen 127.0.0.1:80
Listen 0.0.0.0:80
#Listen [::]:80
# service httpd restart
Stopping httpd: [ OK ]
Starting httpd: httpd: Could not reliably determine the server's fully qualified domain name, using 127.0.0.1 for ServerName
[ OK ]
# netstat -ntlp | grep 80
tcp 0 0 0.0.0.0:3306 0.0.0.0:* LISTEN 1802/mysqld
tcp 0 0 0.0.0.0:80 0.0.0.0:* LISTEN 5585/httpd
now the problem shorted out
No comments:
Post a Comment