Main Page Content
What Goes On Under The Hood Of The Internet
Like so many articles do, this one has origins in a thread on thelist. Having a few spare moments, and the experience of esplaining this before , here you go. My take on "What goes on under the hood of the Internet?"
Down at the data level, and at email and WWW levels, a Cafe modelworks here. Yup. Let's check it out:- 1) You connect to your ISP
- Out through your phone line, your computer is joining a table at a cafe. Sitting at this table are possibly hundreds of other people connected through their phone lines. Now, considering there is no way the cafe couldever have a table big enough for everyone at this table, there is a limit to the number of seats. So when you 'sit down,' you're sitting in a chair someone else might have had not ten minutes ago. --This is your dynamic IPaddress; your designated seat (IP) at this table (ISP) in this cafe(Internet).
- 2) How traffic gets out
- All of the tables in our cafe are connected via 'magic seats' (for lack of a better term, I should just call them routers --that's what they are). As you are talking at the table, everything you say (packet) has attached to it your table+seat number (IP address), and the table+seatnumber you want to talk to. Talking to a seat at your table is like placing the mustard on a lazy susan and spinning it. The correct seat will pick it up when it comes by. As it spins, you pick up anything that has your seatnumber on it. --Though you could 'see' what others at your table are passingaround, you ignore it. (Someone who eavesdrops is called a packet sniffer).
If the seat happens to be at another table, the 'magic seat' at your table passes your mustard along to the next. He also keeps an eye on the next table's lazy susan looking for anything that belongs at your table. Here iswhere classic routing algorithms come into play, as each table (ISP) can be connected to multiple other tables. The 'magic seats' (routers) maintain intelligent information to determine which table to send your mustard to.You pass something, and it gets passed table-by-table to the right seat, where a reply is created and it comes back (more or less) the same way. Slow tables happen ;).
Since your table+seat number is attached to everything you pass around, the other tables know how to find you. --Its like a return address on a piece of mail. Performing a 'ping' tests how fast the table+seat you want to talk to can get back to you; 'traceroute' shows which tables are used and how fast they can pass things along. - 3) Email & WWW
- Some seats at your table have specific duties. When you say "email my mom at table 23" to the email chair (server) at your table, it asks where 'table 23' is, and the email chair it needs to talk to. This is by asking the DNS chair, who converts 'table 23' into a table+seat number. Then it tries to send your email tothe email chair at table 23. If he's swamped with other email, or your email server has a hard time finding out where table 23 is (did they move it out to the patio??), it holds on to your message and tries again multiple times over certain intervals (this is human configurable, a common setting is to retry for 48 hrs). When the email is delivered, the email server at table 23 holds onto it until your mom asks it if she has any new mail.
More information is contained on the email envelope (email headers) than what is sent out above (packets). Your table+seat number for sure, but also information the email chairs use to talk amongst themselves, like "this came from Peter at table 1423," and "the email chair at table 56 was used to passit along at 2:53pm."
When you want to talk to a www chair (server), you ask for thetable+seat number (IP address), and then send a kind request for information (I'll call this the URL, though technically a URL encompasses the IP address). While you are waiting, your request is being passed along to thewww server at the far table. The www chair looks at your request, packages an answer, and sends it back. He's very curt, and has a bad case of amnesia.
He has to be able to handle lots of requests from lots of seats, so he only replies back with what you asked for, ends the conversation, and instantly forgets he talked to you. You have to ask him again if you want more, but trust me, he's forgotten all about you and you have to ask very specificallyand remind him who you are each time. Such is stateless communication.
If he likes you, he'll want to remember you by sending you some cookies. Sendingthem back triggers his memory and he's not so forgetful anymore. What he wants to remember about you determines what kind of cookies you get. Not everybody likes cookies, though. ;) - 4) You disconnect from your ISP
- Simple; you get up and leave the table (hang up the line). Ifthere's anything left on the lazy susan for you, it eventually gets thrown away because its been there too long.