Overview of the data link layer
Position data link layer
The main function of the data link layer
The main function is to strengthen the function of physical layer transmit the original bit stream, the physical layer may be changed to the physical connection error error-free data logical link, so the performance of the network layer is an error-free link
Interface 1. The network layer provides services for the
Provides the following services to the network layer
- Unacknowledged connectionless service
- There acknowledged connectionless service
- Confirmation of connection-oriented service
2. Link Management
Data link layer connection establishment, maintenance and release
3. The frame alignment, frame synchronization, and transparent transmission
Framing package
The data link layer is the front end ip datagrams and adds a header and trailer to indicate the beginning and end ip packet header and trailer are represented by 8-bit binary numbers, as may be different.
Frame delimiting: determining the boundaries of the frame
Frame synchronization: receiving party can identify the start frame from the received binary bit stream and ends in
Transparent transmission: data is transmitted regardless of what bit combination, should be transmitted on the link
4. Flow Control
We look at the following link hop. Send send data sent to the recipient, if the sender sends 100 packets per second, the recipient can only handle one second package 50, what will happen then? The recipient will be accepted by a large number of caches in the cache packets until the buffer is full. What happens after is full? Then there will be the most intolerable situation, buffer overflow, which is the phenomenon of packet loss. Therefore, the recipient must inform the sender in the buffer nearly full time for him to lower the transmission rate, which is the flow control link layer. Flow control is used to ensure data does not cover the receiving entity sends the received data entities.
Reprinted from https://blog.csdn.net/hanzhen7541/article/details/79012113
5. Error Control
While it is possible to distinguish between the frame synchronization start and end of each data frame, but have not solved the problem of data both transmitted correctly: First, if there is a frame error occurs? Second, if the frame is missing? This is the data link layer ensures reliable data transmission service to solve the problem to the network layer, data link layer is the error control function.
The method is generally found by the CRC error check code cyclic, automatic repeat request ARQ retransmission of error frames