Tek-Tips is the largest IT community on the Internet today!

Members share and learn making Tek-Tips Forums the best source of peer-reviewed technical information on the Internet!

  • Congratulations Chriss Miller on being selected by the Tek-Tips community for having the most helpful posts in the forums last week. Way to Go!

problem resolving localhost

Status
Not open for further replies.

TerraSamba

Programmer
Aug 19, 2002
57
NL
Hi guys, maybe you can help me on this...

First of all, I am not 100% into this ip-DNS stuff, so correct me where I go wrong:

I am running Windows XP pro with the build-in IIS server, connected through the internet with a static ip adress.
IE does not take When I use the ip adress: 127.0.0.1 for localhost, it works fine. What can I do to get been resolved by IE?

Thanx for your help,
Terra

The gap between theory and practice is not as wide in theory as it is in practice.
 
You are misinformed. indicates a fully registered address to be resolved by your ISPs DNS servers. When in fact it is the reserved name for your own TCP/IP hardware level.

Try typing in IE simply http:\\localhost
 
Sorry, I did not mean localhost.COM but I meant to say that I cannot get the localhost to be resolved. Because http:\\localhost does not work either. When I substitue the localhost part with the ip 127.0.0.1 it works fine.

What could be the reaon of this?


The gap between theory and practice is not as wide in theory as it is in practice.
 
A bad entry or corrupted HOSTS file.

Look in c:\windows\system32\drivers\etc

You should see a file called simply HOSTS with no extension. You can edit the file with Notepad, but be careful it does not tack on a ".txt" extension. The default file looks as follows, and yours must have the localhost entry as shown below:

# Copyright (c) 1993-1999 Microsoft Corp.
#
# This is a sample HOSTS file used by Microsoft TCP/IP for Windows.
#
# This file contains the mappings of IP addresses to host names. Each
# entry should be kept on an individual line. The IP address should
# be placed in the first column followed by the corresponding host name.
# The IP address and the host name should be separated by at least one
# space.
#
# Additionally, comments (such as these) may be inserted on individual
# lines or following the machine name denoted by a '#' symbol.
#
# For example:
#
# 102.54.94.97 rhino.acme.com # source server
# 38.25.63.10 x.acme.com # x client host

127.0.0.1 localhost

 
Great, that did the trick. Thanx BCastner !!!

The gap between theory and practice is not as wide in theory as it is in practice.
 
Status
Not open for further replies.

Part and Inventory Search

Sponsor

Back
Top