History of network protocols - how we started and where are we going. Part 1

A quick history on how network protocols evolved and what is being used for AI.

Tech Stack

information

Overview

This is my first blog post in a 2 part series. At work I am having to learn about network performance for AI workloads, before that I was learning about TCP network performance and having to learn about these 2 related but unreleated worlds prompted me into writing this blog. I was interested in knowing how it all started and how did we end up where are so here we are.

The ancient king and still king. Ethernet - 1970s

3-10 Mbps (For the entire network)

Imagine you are in the 70s, your current computer is not connected to anything, not even the internet. Imagine you don’t have all the apps that you now have and you only have a text editor. While this will be useful to save information and keep a digital record, eventually you will probably need to print something. Since your computer doesn’t have a built in printer you will need to connect to a printer. Nowadays you connect via Wifi but since it’s 1970 and Wifi was not invented until 1996, you would have to connect via a cable. Ethernet wasn’t created specifically for printers, but it quickly became the dominant way computers and peripherals shared a local network. Ethernet allowed for one building to live under the same network but there was one caveat, every device would use the same cable. The problem? Collisions!

You have probably seen or crossed one lane bridges where if two cars are on the edges of the bridge, one of them needs to wait for the other to cross. But what happens if both drivers start to move at the same time and they find each other in the bridge? A collision! Some honks later, one of the drivers would need to hit reverse and let the other pass. The same applied with the first ethernet connections. If the cable was not being used, one endpoint of the cable might think that it was a good time to use the cable and send information but another endpoint might look at the cable at similar time and decide it can use the cable. When both endpoints sent a signal at the same time a collision would occur. During the 70s, this was considered an acceptable tradeoff but when networks become bigger, the probabilities of collisiones were higher.

Let’s understand each other, network protocols (TCP, UDP)

Late 70s

Networks needed a common understanding on what information looked when it was being sent. Who the information was from and who was it going to, where did the information start and where it ended. Network protocols were made to help this communication happen. In 1974, Vint Cerf and Bob Kahn described the protocol that would eventually be known as TCP/IP. The protocol gave software applications the ability to check for the network reliability by establishing retransmission signals when data was missing. TCP establishes that in order to start sending data, a connection must first be established, once established, data will start being sent in increments, if the receiver detects that some data was missed by keeping track of the counters that the sender would put in the packets, the receiver woud ask for a retransmission of the packet. This was vital for big networks where there would be multiple intermediaries between the client and the sender, if a packet was lost along the way, the receiver could ask for a retransmission to ensure data arrived complete.

UDP was proposed in 1980 and it offered a more flexible and faster way to send data without the reliability guarantee that TCP offered. In UDP if data loss happens it is just ignored and new data is received. In UDP packets are forwarded as fast as possible to the target destination, this specially useful for applications that need real time data, if a packet arrives late or is dropped, it’s better to continue on and keep listening for new incoming packets instead of asking for a retransmission. This protocol also allows for building on top of it since it does not have rigid rules like the 3-way handshake that TCP has.

The traffic officer. Switches (and full duplex) - TCP becomes the internet protocol - 1990s

10 - 100+ Mbps for each port

Switches arrived to solve the problem of having to share the bandwidth for the entire cable. Cables would connect to a switch and the switch would then forward the traffic to the right destination. This greatly reduced the amount of collisions since the cable was only used for traffic related to the endpoint it was connected to but this was still a one way highway. Full duplex cables would have dedicated bandwidth for download and upload allowing for higher speeds. If you add to this that there were improvements to the cable itself like switching from coppper to fiber (copper uses electricity which loses speed with larger distances and fiber uses glass to make light travel from point to point which is more efficient on larger distances and cheaper to make), it allowed for a better bandwidth utilization with zero collisions and the ability to grow the network larger.

Need higher throughput