We started by discussing compaction and the advantages of LFS. I've addded these notes to the last lecture
A network is a collection of computers (sometimes called hosts) that communicate with each other. A network could be a small group of computers that communicate directly with each other (a local area network or LAN), or a wide-area network (WAN): a collection of local area networks that communicate with each other (so that communication between two hosts passes through many other hosts).
The protocols that control network communication are organized in a "stack", with each layer of the stack using the properties of the lower layers to provide features to higher layers.
We have already discussed the physical and link layers; these sit at the bottom of the stack. With only link layer protocols, a machine can send a fixed-size packet of data to another machine on the same local area network.
The network (or internet) layer sits above the link layer and connects together multiple local area networks. With the network layer, a machine can send a packet to another machine anywhere on the internet.
The transport layer uses the network layer and provides the ability for processes on different machines to communicate with each other. The transport layer may also provide reliable, in-order delivery of data.
The session layer gives applications the ability to establish and tear down connections with other processes. It is closely tied to the transport layer.
The presentation layer defines the translation from abstract concepts (such as "integers") to concrete arrays of bytes. For example, the presentation layer might specify the endianness of integers contained in messages, or how strings are encoded. The presentation layer is closely tied to the application layer.
The application layer is the application-specific protocol that individual clients and servers use to communicate.
In the coming lectures, we will make our way up the network stack, discussing the operation of each layer.
It helps to have analogies for the different layers. Note that this is not one big analogy: to talk to someone on the phone, you don't write down what you're saying on a bunch of postcards; different parts of the network stack are easier to visualize on different size or time scales.
The physical layer is analogous to the sound waves in the room when you are talking to someone, or the mechanics of putting some graphite on some paper when you are sending a postcard.
The link layer is analogous to the social rules about starting conversations. For example, if two people start talking at the same time, how do you back off so that they are intelligable? Different social settings have different link layer protocols (for example, a classroom vs. bumping into someone vs. a meeting).
The network layer is analogous to the postal system. If I'm not the same room as someone, I can write down a message on a postcard and give it to a postal worker who is in the same room as me, and they will hand it to another postal worker, who will eventually hand it to a recipient.
The transport layer is a bit like the telephone system: you can establish a connection to someone by calling them; you can then send and receive data from them in a continuous stream.
Continuing the telephone analogy, the session layer is a bit like the buttons on your phone: to establish a connection with someone, you punch in their phone number and press send; to hang up you press end.
The presentation layer is analogous to the language you are speaking in a conversation.
The application layer is analogous to the actual discussion we are having; the set of things we can ask for in any given conversation and the rules defining how the parties will respond.
We discussed a few strawmen for the design of a physical layer:
Fully connected topology: connect every host to every other. Prohibitively expensive: each host needs to be connected to n-1 other hosts.
Star topology: designate one host as the hub, connect every other host to the hub. The hub is expensive and complicated, and is a single point of failure.
Ring topology: organize the hosts into a ring, and connect each to the next one (and possibly the one after that). Pros: decentralized. Cons: Data needs to be forwarded n times, and if any host fails, network can become disconnected.
Bus topology: connect all of the hosts to a single, simple bus. Cons: if two hosts communicate at the same time, we'll get garbage.
The Bus topology turns out to be what is used in practice: it's extremely cheap and simple. We'll handle collisions at the link layer.