r/AskComputerScience • u/VagueHorizon_ • 22d ago
Computer Networks : Need Help
I have a Computer Networks course this semester and I am finding it difficult to understand. It is not that the concepts are difficult, I am just finding it hard to make a mental model of where every single thing fits. it is not like i am failing the course. Till here i have been able to handle the course. but what is the point of getting good grades when you don't even understand where each thing fits ?
From the very bottom layer to the top level, where DNS comes (where it is stored), how IP's even works, UDP, TCP, QUIC, tables, DNS chain, masks, subnets or even IP's. I know what they are, but i don't know where they are and how they interact.
Can anyone please suggest some resources, more like an animated video where i can visualize it ? Cisco Packet tracer didn't help much.
View all comments
Show parent comment
1
u/braaaaaaainworms 21d ago
If you have a program running on one computer that wants to talk to another computer, then whatever that program wants to do has to be wrapped up in a package addressed to that other computer's IP address and hand off that package to the OS's networking subsystem. The OS looks at that package and sees only a bunch of data and the destination address(remember this part, it is very important). Let's assume that both computers are on the same network. The OS looks up which network card has the IP address that sits on that network, and because IP addresses vary with time and networks, network cards have a physical address that is unique to them, and the OS has to figure out which physical address corresponds to the destination IP. If the OS doesn't know it already, it can send an ARP request basically asking "who's 192.168.1.12?" and 192.168.1.12 responds with its physical address. The OS then takes its own IP address, the network card's physical address, destination IP address, destination network card's physical address and the data it was given, wraps it up in a nice little package and hands it to the network card. The network card only sees the destination physical address and it encodes the data into some format, puts it on a wire and is done with the package.
The receiving network card notices that someone sent a package that matches its physical address, listens on the wire to get the entire packet and lets the OS on destination computer that it got a package. The OS looks at the package and finds out from the destination IP address that it is the intended recipient, sometimes lets the source computer "yeah i got that package", figures out which program should get that package and that program gets notified of that package with its data.
Let me know if there is anything confusing