[From the previous episode: we can create a stackRelated to communications: A way of organizing parts of a complicated process (like communications) so that any task relies on tasks below it and feeds the tasks above it. Related to computing: A place in memory where you store “where was I?” information when you go from, say, one function into another. Before starting a new function, you store where you were in the old one so that, when the new function ends and you’re back in the old one, you can figure out where you were and continue on. that describes how a paper report can get from one office to another.]
Last week, we saw a stack describing how we might deliver a paper report to someone in another office. Of course, we’ve invented that stack, just to get used to the idea. No one actually uses that stack; we just did that to introduce the notion of a stack.
So let’s turn to real stacks used by electronic communication. The details of these stacks vary depending on what kind of communication you’re doing, but there’s a generic model stack that’s well recognized and adhered to more often than not. We refer to it as the “OSI model,” and it’s a seven-layer stack.
Sending an Email Through the Stack
Let’s trace the steps of your modern way of sending this report. No more hanging out in the copy room; no more stuffing envelopes. Just a bunch of cc’s and an attachment. And hit “Send.”
- We call the top layer the Application layer. An application is a program that you’re likely to be familiar with. Email is one; browsing is another. Most anything you deal with yourself would be an application. And you should want it that way: you should never have to bother with what’s going on underneath. As far as you’re concerned, it should feel like someone personally hand-carried your email straight over to your destinations along that top dotted line.
- We call the next layer the Presentation layer, and it mostly has to do with how to display information. It’s always useful to separate out the actual computing of information from how it’s going to look. That way you can take a given set of data and serve it up a bunch of different ways without worrying about how that data got there in the first place. Your email doesn’t really have to stop in this layer, so we’ll move on.
- We call the next layer the Session layer. If you’re doing something that requires a session – if you’re going to have a conversation instead of just sending one message – then someone has to be in charge of setting up, maintaining, and tearing down the session. It’s like when two world leaders want to talk, they don’t just dial each other up. Their administrators call each other and set everything up, and then they can simply have the leaders pick up their phones and talk. The electronic equivalent of this is done in this layer. But your email doesn’t really have to do anything here, so, again, on we go.
- Now we get somewhere more interesting: the Transport layer. This layer deals with ensuring (or not) that your email makes it to its final destination. Many kinds of communication require an acknowledgment that messages were received, for instance. More significantly, securityRefers to whether or not IoT devices or data are protected from unauthorized viewers. is a huge part of this; messages may be encryptedEncryption refers to encoding and decoding (or encrypting and decrypting) data so that it can't be read unless you have the right key. It's critical for good security. here. Think of it as where registered or certified mail would be handled if it were snailmail.
- Beneath Transport is a layer that may be familiar to you: the Network layer. This layer is responsible for figuring out how to address your email for its final destination. The Internet Protocol, or IPThis can mean two things (at least):
• The Internet Protocol. Governs the addresses of sources and destinations on a network (without worrying about what’s in between). Used on Layer 3 of the stack.
• "Intellectual property." This can have lots of meanings, but, in the computer-chip world, it refers to parts of a chip design that have been built and optimized by one company, which then sells them to other companies that don’t want to design those blocks themselves. They’re not selling actual chips; they’re selling the design of a block that will be used within a chip.
, is by far the most well-known actor here. With IP, each possible destination has an electronic address – the IP address that you’re probably familiar with. Since there are a lot of possible destinations, you might think that’s a lot of addresses, and you’d be right. In fact, the most prevalent version of IP (version 4, or IPv4) was running out of addresses. So they had to update it (IPv6) in a way that provides an enormous number of addresses while still recognizing old IPv4 messages (since not everyone is going to update their machinesIn our context, a machine is anything that isn't human (or living). That includes electronic equipment like computers and phones. at once). - We call the next layer down the Data Link layer. While the Network layer deals with the whole networkA collection of items like computers, printers, phones, and other electronic items that are connected together by switches and routers. A network allows the connected devices to talk to each other electronically. The internet is an example of an extremely large network. Your home network, if you have one, is an example of a small local network., the Data Link layer worries only about the “next hop.” Your email is going to bounce through many different routersAn electronic box that helps steer data on a network. For instance, you may have one in your home connecting your phone and computer and other devices to each other and to the internet. The data itself has information about where it's being sent; the router uses that information to send it in the right direction. At a really basic level, you can think of a router and a switch as being the same thing. If you want to get more technical, a switch creates a local subnetwork, and the router connects multiple subnetworks (or multiple networks). or serversA computer with a dedicated purpose. Older familiar examples are print servers (a computer that controls local printing) and file servers (a computer used for storing files centrally). More modern examples are web servers (the computers that handle your web requests when you use your browser) or application servers (computers dedicated to handling the computing needs of a specific application). Servers are often powerful, expensive machines since they have to handle a heavy load. in the network on its way to the final stop, just like an old-school envelope might stop in numerous cities en route. Your computer and every other router along the way will take your email and decide which stop to send it to next. Unlike our envelope example, no one maps out the whole route of an electronic message beforehand; it goes one hop at a time.
- Finally, we get to the Physical layer. This is where the rubber hits the road. It deals with what electrical signals will occur on the wires or in wireless transmissions. It also has to take care of “playing nice,” since, somewhere along the way, your email is going to be on wires or airspace that are shared with other stuff. Your cable, for instance, is shared with your neighbors. So when you want to put a message out, you have to see if anyone else is talking first. Kind of like old-fashioned telephone party lines, which consisted of a single phone line going to several houses. When you wanted to make a call, you picked up the phone and first listened to see if anyone else was talking. If so, you waited and tried again later; if not, you went ahead to make your call.In the electronic version, this happens at the physical layer as well, generally referred to as media access. The media access controller – MAC – handles it, and if anyone has ever asked you for the MAC address on your network card, that’s what the MAC is. (And yes, believe it or not, every device has a unique MAC address.)
In other words, delivering an email isn’t as different from delivering a package as you might think. Bundles of bitsThe smallest unit of information. It is a shortened form of "binary digit." Since it's binary, it can have only two values -- typically 0 and 1. are usually referred to as packets, so even engineers see the similarity. We’ll dive deeper into these layers later on.
The video below illustrates an email traveling through two intermediate stops before getting to its destination.
Leave a Reply