Can no longer access localhost with IP.

Hi Experts,

I used to be able to access my localhost via http://localhost or http://mylocalip

Recently I changed my router with my Internet company, but made sure that I set my IP to Reserved, and when I do ipconfig, I use the correct IP address that I was using, but I cannot access my localhost anymore with my IP.

I am not sure if this happened with my router change, or something else, but I would appreciate any help.
APD TorontoSoftware DeveloperAsked:
Who is Participating?
I wear a lot of hats...

"The solutions and answers provided on Experts Exchange have been extremely helpful to me over the last few years. I wear a lot of hats - Developer, Database Administrator, Help Desk, etc., so I know a lot of things but not a lot about one thing. Experts Exchange gives me answers from people who do know a lot about one thing, in a easy to use platform." -Todd S.

timgreen7077Exchange EngineerCommented:
In the cmd prompt type IPCONFIG, and see what the IP address of your local host is showing. If your local host has a DHCP address then it might have changed with the new router, but if it's a static address then it will remain the same.
0

Experts Exchange Solution brought to you by

Your issues matter to us.

Facing a tech roadblock? Get the help and guidance you need from experienced professionals who care. Ask your question anytime, anywhere, with no hassle.

Start your 7-day free trial
APD TorontoSoftware DeveloperAuthor Commented:
In the new router I set it to reserved, then I checked ipconfig it shows the proper IP.

I am not sure what you mean re DHCP, I am not a network person.
0
timgreen7077Exchange EngineerCommented:
what is the local host you are referring to? Is it a computer or router or what?
0
The Ultimate Tool Kit for Technolgy Solution Provi

Broken down into practical pointers and step-by-step instructions, the IT Service Excellence Tool Kit delivers expert advice for technology solution providers. Get your free copy for valuable how-to assets including sample agreements, checklists, flowcharts, and more!

APD TorontoSoftware DeveloperAuthor Commented:
localhost is a computer
0
timgreen7077Exchange EngineerCommented:
Ok, so what are you attempting to access using http://localhost or http://mylocalip, do you have an IIS server running on the computer or anything? This will not show you anything unless you have some type of web service running.
0
Martin MillerCTOCommented:
Can check your hosts file, and confirm you have a localhost entry pointing to 127.0.0.1.

Note: 127.0.0.1 is known as a loopback address, to yourself.
1
Wayne88Commented:
Agree with Martin, you should check your host file.  It doesn't make sense for localhost to not work by changing the router.

" used to be able to access my localhost via http://localhost"

There is a difference being able to communicate with localhost and accessing localhost via http.  

First, ensure you can ping localhost and get a reply.  If you do get a reply then the problem is with the HTTP service/server.  Make sure the we service and website is running.

If you don't get a reply then the problem should be with the host file as stated above.
0
APD TorontoSoftware DeveloperAuthor Commented:
Below is my hosts file, and I uncommented the last 2 lines, but still I cannot access http://192.168.2.200

http://localhost and http://127.0.0.1 work.

The reason why I need http://192.168.2.200 is because I am a web developer and need to test from different devices. This used to work up until 2 weeks ago.

# Copyright (c) 1993-2009 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

# localhost name resolution is handled within DNS itself.
	127.0.0.1       localhost
	::1             localhost

Open in new window

0
APD TorontoSoftware DeveloperAuthor Commented:
It was my Avast Firewall

Thank you!
0
Wayne88Commented:
Glad you got it solved and thanks for getting back.  Cheers!
0
It's more than this solution.Get answers and train to solve all your tech problems - anytime, anywhere.Try it for free Edge Out The Competitionfor your dream job with proven skills and certifications.Get started today Stand Outas the employee with proven skills.Start learning today for free Move Your Career Forwardwith certification training in the latest technologies.Start your trial today
Routers

From novice to tech pro — start learning today.