cpatte7372
asked on
How to change 'localhost' ip address on workstation
Hello Experts
This is a very easy one.
Can someone please show me how to change the ip address of the 'localhost' on my pc.
I believe there is somekind of 'host' or 'winhost' file that I need to change.
At the moment if I ping localhost it comes up with 127.0.0.1, which we all know is the loopback address. I want to change it to specific ip address.
Cheers
Carlton
This is a very easy one.
Can someone please show me how to change the ip address of the 'localhost' on my pc.
I believe there is somekind of 'host' or 'winhost' file that I need to change.
At the moment if I ping localhost it comes up with 127.0.0.1, which we all know is the loopback address. I want to change it to specific ip address.
Cheers
Carlton
edit your hosts file and change localhost to point to where you want. (you need admin permissions)
I recommend against changing localhost to any other IP address. You don't know how many other applications depend on that. Instead, find the IP address of your machine and use that. Here are two methods of finding your IP address: http://www.ehow.com/how_5621076_ip-address-windows-7.html
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Doesn't it work the other way around, ping -a will resolve names to IPs but not the other way around? On this machine, 'localhost' resolves to '::1' which is the IPV6 version.
No... DNS resolves names to IPs.
Names are not needed at all to run a ping... when you ping a domain name it gets the IP from DNS and every hop along the path actually uses the IP address, not the name.
If you ping a reachable IP address no domain name is displayed; ping -a essentially does a reverse DNS lookup.
Names are not needed at all to run a ping... when you ping a domain name it gets the IP from DNS and every hop along the path actually uses the IP address, not the name.
If you ping a reachable IP address no domain name is displayed; ping -a essentially does a reverse DNS lookup.
what are you actually trying to achieve here, please?
Localhost is *supposed* to be the loopback address:
http://en.wikipedia.org/wiki/Localhost
If you can describe the actual problem, we can widen the scope of the answers.
Localhost is *supposed* to be the loopback address:
http://en.wikipedia.org/wiki/Localhost
If you can describe the actual problem, we can widen the scope of the answers.
ASKER
Cheers