Operating System - HP-UX
1827453 Members
4805 Online
109965 Solutions
New Discussion

simple apache server confirmation

 
Jason Miñoza
Advisor

simple apache server confirmation

guys/gals,

having problem confirming apache web server is running...
was trying to check it via http://localhost but i always get the ISP's page instead of apache local page...
i have the httpd.conf as follows:
Servername localhost
Listen :80

jason
friends get u places
6 REPLIES 6
harry d brown jr
Honored Contributor

Re: simple apache server confirmation

What kind of server are you running apache on, and when you say ISP, do you mean your internet providers home page, or an Apache page?
Live Free or Die
Jason Miñoza
Advisor

Re: simple apache server confirmation

ISP's page...Internet Service Providers page
its running alright via servername..
my problems is via http://localhost...
i already have /etc/hosts localhost....and no proxy on "localhost"...
but i still get Meridians(ISP) page instead my local apache test page whenever i hit localhost....
friends get u places
Bernd Reize
Trusted Contributor

Re: simple apache server confirmation

In my eyes i doesn't look like an Apache problem, but like a network problem:
if your apache doesn't run, you would simply get NO page under http://localhost, but if you get a completly different (from your ISP) page, it looks more like a wrong localhost setting.

Your can verify it via 'ping localhost' to see if it is really 127.0.0.1, or the other way, try http://127.0.0.1

To verify if apache is running try
'ps -ef | grep httpd' to see if there are any apache processes and 'netstat' to see if there is anyone listening on port 80.
Bill Thorsteinson
Honored Contributor

Re: simple apache server confirmation

/etc/hosts is usually set up at the last place to look for
ip addresses. Check /etc/resolve to see what DNS
may be appending to localhost. If you have domain
or search defined these will be added to localhost
and a lookup attempted. Note: localhost.com resolves
to 63.231.68.113. Partial entries may be attempted.

Assuming your domain is mydomain.com try
nslookup localhost.mycomain.com
nslookup localhost.com
nslookup localhost

The first and last should both return 127.0.0.1. Your
DNS entries should include an entry for
localhost.mydomain.com.

Try using http://127.0.0.1, http://localhost., or
http://myserver.mydomain.com to see if your sever is up.
If you have the server-status page enabled you can
determine the status from
http://127.0.0.1/server-status
This gives status info on all processes.
Jason Miñoza
Advisor

Re: simple apache server confirmation

looks like a DNS problem!
i can see the apache test page via its local ip address....this confirms apache is running..
PROBLEM! whenever i hit "localhost", check server name prompts. seems like its always accessing the DNS of our ISP.
could find any /etc/resolve file....
how do i check DNS properties?
friends get u places
linuxfan
Honored Contributor

Re: simple apache server confirmation

Hi Jason,

Look at your /etc/nsswitch.conf, it may be pointing to your DNS first, change it to look at files and then DNS

-HTH
Ramesh

They think they know but don't. At least I know I don't know - Socrates