Basic Network skills-network transmission (1)

Source: Internet
Author: User

Basic Network skills-network transmission (1)

Introduction

First, let's look at an example:

For example, the network server transmits data to the client:

Before describing the network transmission process in detail, let's take a look at the most common example to show the complete process of data transmission from a network server to a client:

1. The data to be transmitted is the HTML page of the network server.

2. Add the HTTP header of the application protocol to HTML data. The packet header information includes the HTTP Version Used by the server and the status code indicating that it contains the information sent to the network client.

3. The HTTP application layer protocol sends HTML webpage data to the transport layer. The TCP transport layer is used to manage sessions between network servers and clients.

4. Add the IP information before the TCP information. Specify the appropriate source and destination IP addresses. This information constitutes an IP packet.

5. After the Ethernet protocol is added to both ends of the IP Message, a data link frame is formed. The above frame is sent to the nearest vro on the path to the network client. The router removes the Ethernet information, observes the IP packet, determines the optimal path, inserts the packet into a new frame, and sends it to the next adjacent router in the target path. Each router removes and adds new data link layer information before forwarding.

6. Data is transmitted over an interconnected network. The interconnected network includes media and intermediate devices.

7. The client receives the data link frame containing the data, processes the protocol headers at each layer, and then removes the protocol headers in reverse order when adding the data. First, process and remove Ethernet information, followed by IP protocol information, followed by TCP information, and finally HTTP information.

8. Then, pass the webpage information to the client Web browser software.

I. Data encapsulation:

To transmit a message over the network, you must encode it and encapsulate it in a specific format. At the same time, you must encapsulate it appropriately to provide sufficient control and address information, to enable it to move from the sender to the receiver.

Message Size

Theoretically, the video or email information can be transmitted from the network source address to the destination address with a large non-interrupted stream, but this also means that other devices on the same network cannot receive or send messages at the same time. This large data stream causes significant latency. In addition, if the connection is disconnected during transmission, all data streams will be lost and need to be re-transmitted. Therefore, a better method is to take the data stream segment (segmentation) as a smaller segment for ease of management, which can bring two benefits:

(1) send small segments. multiple sessions can be staggered at the same time on the network. This process of cross-cutting different session segments on the network is called multiplexing ).

(2) segmentation can improve the reliability of network communication. Each message segment does not need to go through the same path from the source address to the target address. If one path is blocked or disconnected, other messages can go to the target address from the replacement path. If some messages cannot reach the destination address, you only need to re-transmit the Lost part.

Tags the segments to ensure the order and reorganization during receiving.

Protocol Data Unit (PDU)

The application layer data is transmitted along the protocol stack during transmission, and information is added to each layer of the Protocol. This is the encapsulation process.

A data segment is called a Protocol Data Unit (PDU) in the network structure of each layer ). During encapsulation, the next layer encapsulates the PDU received from the previous layer. In each phase of processing, PDU have different names to reflect its functions.

PDU follow the naming rules of the TCP/IP protocol:

** Data: A term commonly used in the application-layer PDU

** Segment: Transport Layer PDU

** Frame: Network-layer PDU

** Bit (Bits): The PDU used to physically transmit data on the media.

Encapsulation

Encapsulation refers to the process of adding additional protocol header information for data before transmission. In most data communication processes, the source data is encapsulated with a number-layer protocol before transmission. When a message is sent over the network, the protocol stack on the host is operated from top to bottom.

Taking the network server as an example, the HTTP application layer protocol sends HTML webpage data to the transmission layer, and the application layer data is divided into TCP segments. Each TCP segment is labeled as a header, indicating which process of the receiver should receive the message. It also contains information that allows the receiver to reorganize data in the original format.

The Transport Layer encapsulates the HTML data blocks of the webpage and sends them to the network layer to execute the IP layer protocol. The entire TCP segment is encapsulated into an IP packet, that is, the IP header label is added. The IP header includes the source and destination IP addresses, and the information required to send packets to the destination address.

Then, the IP packet is sent to the access layer and encapsulated as the frame header and end frame. Each frame header contains the Source and Destination physical addresses. The physical address uniquely specifies the device on the local network. The end of the frame contains error correction information. Finally, the server Nic transmits the bit encoding to the media.

Unencapsulate

The receiving host performs operations in the opposite way. Unencapsulate is the process of removing one or more protocol headers from the receiving device. Data is moved up in the protocol stack until the terminal application layer is unencapsulated.

2. Access Local resources:

Two types of addresses are required to access local network resources: the network layer address and the data link layer address. The network layer and data link layer are responsible for transmitting data from the sending device to the receiving device. Both the source and target addresses are supported, but the two addresses have different purposes.

Example: communication between client PC1 and FTP over the same IP Network


Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.