Understanding Computer Networks by Analogy - Part 1 - Networks and subnets
There are many ways to learn something new and no approach is best. But, what works best for me is a combination of
trial and error and learning by
first principles. But, as someone once said:
Knowledge is only valuable when it leads to taking action on an idea.
And as long as you share that knowledge you are taking action on an idea.
Just one big question is: how to share them? I find that analogies are a great tool to do that. They let you group together many ideas and present them as a whole to new audiences in a very fun way.
In this series of posts I propose a not so perfect analogy for computer networks represented as buildings.
Networks or “The buildings”
This building represents a “network” of “connected rooms”.
Think of each room as a computer with a room number as an IP address.
room + room number == computer + ip address
In this network, each room can communicate directly to any other room using network protocols that will be represented as a
But now you are wondering… I don’t want to send packages to all my neighbors…I just want to communicate with specific ones.
Subnets or “The floors”
By dividing your building into floors you can now isolate the communication between them. Neighbors in the 6th floor cannot communicate with neighbors in the 9th floor.
This is called a subnet
You can identify the rooms by the room number or IP address.
Example room 69 can be idenfied as:
floor 6, room 9
or as an IP address:
This room number is unique to your building but the next building can have a room 69 in its building as well (I will cover this in a later post about private vs public IPs).
Computers or “The rooms”
In reality, your room number is not tied to the physical space in the building but to the door that allows access to it.
Which means that your room can have many doors with different properties:
- A door for maintenance,
- A door for guests,
- And so on.
Within the floor (subnet) your door have a unique number called MAC address
In other words, your room is identified by an door number rather than a room number within a subnet.
room -> door 1 -> room 69
or as a relation between Computer, MAC and IP
computer interface eth0 -> ff:ff:ff:ff:ff:ff -> 192.168.6.9
- Networks and subnets or building layouts
- Switches and Routers or how rooms can communicate between floors
- Network protocols or how rooms communicate
- Internet, public IPs, NAT, DNS or how to connect rooms between buildings
- High performance networking or how to speed up the communication between rooms using high speed roads and other techniques
- SDN or dynamic floor arrangement
If you want contribute, please send a pull request or open an issue to this repo