Fundamental of Data Communication and Networking : Part 2 (How Data Moves Through the Internet)
Saiful Islam Rasel
Senior Engineer, SDE @ bKash | Ex: AsthaIT | Sports Programmer | Problem Solver | FinTech | Microservice | Java | Spring-boot | C# | .NET | PostgreSQL | DynamoDB | JavaScript | TypeScript | React.js | Next.js | Angular
Previous Parts:
Story:
Once upon a time in a bustling digital city, there was two computer lets call them Computer-A and Computer-B and they lived in different location. Inside the Computer-A, there was some data in a email format. Let's call the data as Data-D.
Step-1: One day Computer-A wanted to send the Data-D to the Computer-B. Now to do so Data-D need the address of both computer otherwise there was a chance to lost the Data-D. So Data-D started his journey by resolving the source (where she came from) and destination (where she needed to go) computer address.
Step-2: Computer-A couldn't send Data-D directly to her destination. Instead, Data-D first had to visit a neighborhood. This neighborhood acted like a local post office. It checked Data-D's destination address and decided the best path for her to take.
Step-3: The neighborhood sent Data-D onto a super-fast highway connecting cities around the world. As Data-D traveled along this highway, she met other neighbors at various intersections. Each neighbors examined Data-D's address and forwarded her closer to her destination.
Step-4: Along the way, Data-D met others friends from different parts of the world. They all traveled together, guided by a special formula. This formula helped Data-D by ensuring she didn't get lost and that she arrived safely and in the correct order with her fellow friends.
Step-5: After a long journey, Data-D finally reached her destination Computer-B. The Computer-B, eagerly waiting for Data-D, received her along with her fellow friends.
Step-6: Inside the Computer-B, Data-D and all his friends reassembled to form the complete email message. Data-D was proud to have completed her journey, ensuring the user could read the message just as it was sent.
How Data Moves Through the Internet:
As you can understand from the above story, journey of data from a source to a destination over the network is not straight forward task and need a guided rule for successful transmission.
OSI model or TCP/IP model described in the previous part (Part 1) is the guided rule for this. This gives us a organized and self describing way for efficient data moving over the internet. Lets jump into the detail journey.
Starting Point:
The journey of a data begins with the address resolution of source and destination. This address is called IP address. Basically when a application like web browser or email client of source device also known as host device wants data transmission the OS resolve the destination address using a protocol called DNS resolution [will cover details in the next part of this series post]. So after resolving destination IP address by DNS resolution and source IP address by DHCP (Dynamic Host Control Protocol) [will cover details in the next part of this series post] the data is ready to move.
This process take place in Application Layer (Layer 7) of OSI model. In the above story Step-1 do this job.
Translation and Securing Data:
As internet is a open place to move means open network, so anyone can move anywhere without any restriction. In this scenario to protect our data we need a secret secure format so that only the source and destination can understand that. So at beginning of moving in the network, data need to convert in machine format called binary format and to secure it needs to encrypt and for faster delivery it needs to compress.
This process take place in Presentation Layer (Layer 6) of OSI model.
领英推荐
Keep the Relation Alive:
In real world, we introduce with someone and create relationship. This relationship or personal networking help us in future if we need some help or future interaction with them. The network also work like this. If we talk, visit, interact for data transmission with some other network/website/application there is a possibility to create a relationship for future smooth interaction. This relationship in networking called session.
The session layer manages the communication between applications by establishing, maintaining, and terminating sessions. It allows multiple applications to share the same network connection. This process take place in Session Layer (Layer 5) of OSI model.
Transporting and Service-to-Service Communication:
Channel or medium of data transmission system like wire or wireless has some limitation or bandwidth for data transmission. So large data can't transmit at a time. That's why we need to chunking or segmenting large data into smaller parts so that data can be effectively transmit through channel or medium.
The transport layer provides service-to-service communication between applications. It ensures that data is transmitted reliably and efficiently by breaking it up into smaller segments and reassembling them at the receiving end. It also provides error correction and flow control. This whole process is handled by a rule called TCP (transmission control protocol) or UDP (User Datagram Protocol) [will cover details in the next part of this series post]. This process take place in Transport Layer (Layer 4) of OSI model. In the above story portions of Step-4,5,6 do this job.
Routing and End-to-End Communication:
For end-to-end means source to destination communication, data needs to travel a long way. So data needs to find the best and shortest route to travel for faster and effective transmission. Network layer manages logical addressing and routing of data packets between networks (e.g., IP addresses). It works end-to-end and packeting data with L3 header.
The network layer is responsible for the routing of data across multiple networks. It decides the best route for data to take based on the destination address and network conditions. Here segments are converted into packets by adding IP addresses. This process take place in Network Layer (Layer 3) of OSI model. In the above story portions of Step-2,3 do this job.
Linking and Hop-to-Hop Communication:
Data Link Layer does not provide Host-to-Host delivery. Instead, there is Hop-to-Hop (node to node) delivery in Data Link Layer. Hop-to-Hop delivery in Data Link Layer can be delivery of packets from the host’s network interface card (NIC) to the router’s interface or it can be delivery of packets from one router’s interface to another router’s interface or it can be delivery of packets from one router’s interface to host’s network interface card (NIC). It does not directly deliver the packets from source to destination instead delivers them from one hop(node) to another.
It ensures reliable data transfer across the physical network, managing MAC addresses and error detection. It works hop-to-hop and framing data with L2 header.
The data link layer is responsible for the reliable transmission of data between two nodes on the same network. It ensures that data is transmitted without errors, and it provides error correction and flow control. Here packets are converted to the frame by adding the MAC address with the packets. This process take place in Data Link Layer (Layer 2) of OSI model.
Raw Data (bitstream) Transmission:
Finally the last stage deals with the physical transmission of data over the network, such as the cables, connectors, and other hardware. It defines the electrical and physical characteristics of the transmission medium, such as how data is transmitted and received. Here frame becomes bitstream for transmission through the media.
For example, the physical layer may use copper or fiber-optic cables to transmit the data, or it may use wireless transmission methods such as radio waves or infrared signals. This process take place in Physical Layer (Layer 1) of OSI model.
I had a detailed explanation article for OSI Model called Random Topic - 37 (OSI Model).
Summary:
In short data transmission or packet traveling performs according to the following mechanism:
This process ensures reliable and efficient transmission of data from the source to the destination across the internet.
Senior Engineer, SDE @ bKash | Ex: AsthaIT | Sports Programmer | Problem Solver | FinTech | Microservice | Java | Spring-boot | C# | .NET | PostgreSQL | DynamoDB | JavaScript | TypeScript | React.js | Next.js | Angular
4 个月Part 1: https://www.dhirubhai.net/pulse/fundamental-data-communication-networking-part-1-backbone-rasel-owkzc/