How to I get the IP address of a given website,such as serverfault.com?
|
From a command-prompt:
Bear in mind that with load-balancers, geo-DNS systems, etc, that the IP address you get back might have no real relationship to the IP address actually assigned to the web server. |
|||||||||
|
|
on a linux or mac system you can also use the command
|
|||
|
|
Notice, that there could be hundreds or even thousands web sites "hiding" behind a single ip address if the web server serves named virtual hosts. See e.g. the |
||||
|
|
|
ping serverfault.com look for the IP address in the output.
|
|||||
|
|
you probably want the A record,
|
||||
|
|
|
In Windows, open a command prompt (Start->Run, type cmd) and run the command:
|
|||
|
|
|
|||
|
|
|
If you're on a host that only permits root to ping:
then you can use wget to check ip:
As a bonus you get to know if the server is up and running. |
|||
|
|
A web site may have more than one IP -- for instance, what is the IP address of www.google.com? Well, the answer is that it depends. For me it is an alias to www.l.google.com, which itself is either 64.233.161.147 or 64.233.161.104. But if I ask a different DNS server, I get 74.125.65.147 or 74.125.65.99 or 74.125.65.103 or 74.125.65.104. |
|||
|
|