Take the 2-minute tour ×
Super User is a question and answer site for computer enthusiasts and power users. It's 100% free, no registration required.

When I do ping stackoverflow.com from command window in Windows, how does it get the ip address of stackoverflow. Basically how does the entire thing work ?

share|improve this question

migrated from serverfault.com Jul 15 '10 at 15:06

This question came from our site for professional system and network administrators.

4 Answers 4

up vote 15 down vote accepted

For @Evan (because I'm waiting for rm -rf to finish before i can do work):

Here is the process of ping resolving a website:

  1. An electrical signal in your brain generates what is known as an idea.
  2. This idea is converted to another electrical signal, that travels from your brain, down your spine and into the nerves in your hands where it is processed by the muscles in your fingers.
  3. Your fingers convert this electrical energy into mechanical energy which forces the proper key down on your keyboard.
  4. The depression of the switch on the keyboard triggers another electrical signal to travel down the wire (or over the airwaves) from your keyboard which triggers an interrupt at the hardware level.
  5. This interrupt alerts the operating system of a pending action it needs to take.
  6. The kernel process the signal from the keyboard and outputs feed back to the screen
  7. the light energy on the screen is converted into electrical energy by your eye and sent to the brain for processing
  8. Once the brain has processed and confirmed the readout from the screen is what you want, repeat steps 1-8 until you send the signal to depress the "enter" key
  9. The ping command then takes the input - in this case ping serverfault.com - and sends a signal to the Operating system to do a DNS LOOKUP
  10. The operating system sends a signal to the DNS subsystem, which generates a packet and sends it down the OSI model until it reaches the hardware
  11. an electrical signal is generated on the nic and sent out the ethernet cable (or whatever physical connectivity if fiber s/electrical/optical )
  12. The signal goes through intermediary network connectivity (switches/routes/etc) until it reaches the DNS SERVER
  13. The DNS SERVER processes the request and reverses steps 10-11 to get back to your machines where it is processed by the OS and passed back to ping.

(I skimped on a couple of places mostly because i ran out of juice and only have 1/2 a cup of coffee in me)

share|improve this answer

It is called DNS.

share|improve this answer

First it uses your local host file then it uses your primary dns server, if that fails it goes to the secondary dns server.

share|improve this answer

Take a look at the following...

http://en.wikipedia.org/wiki/Routing_table

http://compnetworking.about.com/od/hardwarenetworkgear/f/routing_table.htm

Also look up routing metric's

These are some fundemental networking

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.
{"cc_re__cc_re__cc_by_sa_3_0": ["        <li><a href=\"http://area51.stackexchange.com\" title=\"proposing new sites in the Stack Exchange network\">Area 51</a></li>\r\n                        <li><a href=\"http://careers.stackoverflow.com\">Stack Overflow Careers</a></li>\r\n                    \r\n                </ol>\r\n            </td>\r\n    </tr>\r\n</table>\r\n                </div>\r\n            </div>\r\n\r\n            <div id=\"copyright\">\r\n                site design / logo &#169; 2014 stack exchange inc; user contributions licensed under <a href=\"http://creativecommons.org/licenses/by-sa/3.0/\" rel=\"license\">cc by-sa 3.0</a> \r\n                with <a href=\"http://blog.stackoverflow.com/2009/06/attribution-required/\" rel=\"license\">attribution required</a>\r\n            </div>\r\n            <div id=\"svnrev\">\r\n                rev 2014.8.29.1807\r\n            </div>\r\n            \r\n        </div>\r\n    </div>\r\n    <noscript>\r\n        <div id=\"noscript-warning\">Super User works best with JavaScript enabled<img src=\"http://pixel.quantserve.com/pixel/p-c1rF4kxgLUzNc.gif\" alt=\"\" class=\"dno\"></div>\r\n    </noscrip"], "copyright__copyright__copyright": ["to the secondary dns server.\n\nshare|improve this answer\n\nTake a look at the following...\n\nhttp://en.wikipedia.org/wiki/Routing_table\n\nhttp://compnetworking.about.com/od/hardwarenetworkgear/f/routing_table.htm\n\nAlso look up routing metric's\n\nThese are some fundemental networking\n\nshare|improve this answer\n\nYour Answer\n\n\u00a0\ndiscard\n\nBy posting your answer, you agree to the privacy policy and terms of service.\n\nNot the answer you're looking for? Browse other questions tagged or ask your own question."]}