An improved address resolution device based on domestic operating system
By actively initiating ARP requests on the routing switching device and periodically refreshing the ARP table entry, the problem of error deletion of ARP table entry on the routing switching device of the domestic operating system is solved, and a stable communication connection is achieved.
Patent Information
- Application Number
- CN202310813130.6
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2023-07-04
- Publication Date
- 2025-09-05
- Estimated Expiration
- 2043-07-04
AI Technical Summary
When a domestic operating system is applied on a routing switching device, the error deletion of ARP table entry leads to communication interruption. The reason is that the data forwarding of the routing switching device is carried out on a dedicated hardware module, and the operating system cannot receive terminal data, resulting in the ARP table entry timeout deletion.
Before deleting the ARP table entry, the routing and switching device actively initiates the ARP request and periodically refreshes the ARP table entry through the address resolution protocol module to ensure the accuracy of the table entry and avoid incorrect deletion.
It solves the communication interruption problem caused by the routing switching equipment not receiving terminal information for a long time. It is compatible with the standard ARP protocol and does not require modification of the terminal equipment.
Smart Images

Figure CN116846861B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to an address resolution protocol (NOS-ARP) in a domestic operating system and can be widely used in routing and switching equipment in the field of communication networks. Background Art
[0002] Currently, most domestic operating systems are Linux-based products that have been adapted and modified, primarily for terminal devices such as computers and servers. Routing and switching equipment differ fundamentally from terminal devices in terms of both software and hardware structure. While data forwarding and protocol processing in terminal devices are performed in the operating system software, protocol processing in routing and switching equipment is performed in the operating system software, and data forwarding is typically performed in dedicated hardware modules. Therefore, when applying domestic operating systems to routing and switching equipment, the relevant protocol software must be modified specifically to meet the requirements of routing and switching equipment.
[0003] The Address Resolution Protocol is used to obtain the MAC address of the corresponding host based on the IP address. It is a basic protocol for terminal devices and routing switching devices. The ARP software of domestic operating systems is designed and operated according to the terminal device model. It maintains the ARP table in a soft state manner. If no data is received from a terminal within a certain time period, the corresponding ARP table entry is deleted. When domestic operating systems are applied to routing switching devices, because the data forwarding of routing switching devices is performed on dedicated hardware modules, even if a terminal is constantly sending data to the routing switching device, the domestic operating system will not receive any data, resulting in the corresponding ARP table entry being mistakenly deleted, causing communication interruption. Summary of the Invention
[0004] The present invention implements an improved address resolution device based on a domestic operating system. Using this method, the routing switch device proactively initiates an ARP request for the corresponding IP address before deleting an ARP entry. If no ARP response is received, indicating that the corresponding host has left the network, the ARP entry is deleted. If an ARP response is received, indicating that the corresponding host is still online, the ARP entry is retained unchanged. This method solves the problem of incorrectly deleting ARP entries when the routing switch device control module fails to receive terminal information for an extended period, leading to communication interruptions.
[0005] The technical problem to be solved by the present invention is achieved by the following technical solutions:
[0006] An improved address resolution device based on a domestic operating system, comprising a line receiving module 101, a hardware forwarding module 102, a domestic operating system module 103 and a line sending module 104;
[0007] The line receiving module 101 is used to perform PHY layer receiving processing on the received data, including optical-to-electrical conversion, line decoding, clock recovery and serial-to-parallel conversion, and then send the recovered clock and data to the hardware forwarding module 102;
[0008] The hardware forwarding module 102 is used to classify the data sent by the line receiving module 101 into two categories: control management data and ordinary data. The control management data is directly forwarded to the domestic operating system module 103. If the table lookup is successful, the ordinary data is sent to the line sending module 104. If the table lookup fails, it is sent to the domestic operating system module 103. The hardware forwarding module 102 is also used to send the control management data and ordinary data sent by the domestic operating system module 103 to the line sending module 104.
[0009] The domestic operating system module 103 is used to perform address resolution and routing interaction processing on the received control management data, and send the generated response information to the hardware forwarding module 102 in the form of control management data; it is also used to search the software forwarding table according to the data address for the table lookup failure data sent by the hardware forwarding module 102. If the table lookup is successful, the hardware forwarding table of the hardware forwarding module 102 is updated and the data is sent to the hardware forwarding module 102 again. If the table lookup fails, the data packet is discarded.
[0010] The line sending module 104 is used to perform PHY layer sending processing on the received data, including parallel-to-serial conversion, line coding and electrical-to-optical conversion.
[0011] Furthermore, the domestic operating system module 103 includes a routing protocol module 110, a software forwarding module 111 and an address resolution module 112;
[0012] The routing protocol module 110 is used to receive the routing protocol data in the control management data sent by the hardware forwarding module 102, perform the shortest route calculation and protocol information interaction, generate the forwarding table information and send it to the software forwarding module 111, and send the generated protocol interaction data as control management data to the hardware forwarding module 102;
[0013] The software forwarding module 111 is used to receive the forwarding table information sent by the routing protocol module 110, update the internal software forwarding table, and extract the address information from the ordinary data received by the hardware forwarding module 102, and use the address information as a keyword to perform a table lookup in the software forwarding table; if the table lookup is successful, the hardware forwarding table of the hardware forwarding module 102 is updated, the data is sent to the hardware forwarding module 102 again, and a table entry update message is generated and sent to the address resolution protocol module 112; if the table lookup fails, the data is discarded;
[0014] The address resolution protocol module 112 is used to run the ARP protocol, map the IP address to the MAC address, and periodically refresh the ARP table. If no update message of an ARP table entry is received from the software forwarding module 111 within a certain time period, an ARP request of the corresponding ARP table entry is initiated and sent to the hardware forwarding module 102 as control management data to be broadcasted to the entire network. If no ARP reply is received, it means that the host corresponding to the ARP table entry has left the network, and the corresponding ARP table entry is deleted. If an ARP reply is received, it means that the host corresponding to the ARP table entry is still running on the network, and the corresponding ARP table entry is retained. The ARP table entry remains unchanged; if an entry update message corresponding to an ARP table entry is received from the software forwarding module 111 within a specific time period, the corresponding ARP table entry remains unchanged; the address resolution protocol module 112 is also used to analyze the address resolution protocol data in the control management data received from the hardware forwarding module 102. If it is an address resolution message sent to itself, an address resolution response message is generated as control management data and sent to the hardware forwarding module 102; if it is an address resolution response message sent to itself, the ARP table is updated according to the message content; if it is not a message sent to itself, it is discarded.
[0015] Compared with the background technology, the present invention has the following advantages:
[0016] 1. The present invention uses the method of actively initiating ARP requests to solve the problem of incorrectly deleting ARP entries when the control module of the routing switching device in the hardware forwarding mode fails to receive terminal information for a long time, resulting in communication interruption.
[0017] 2. The present invention is compatible with the standard ARP protocol and does not require modification of the communication terminal equipment. BRIEF DESCRIPTION OF THE DRAWINGS
[0018] Figure 1 It is a principle logic block diagram of an embodiment of the present invention.
[0019] Figure 2 It is a principle logic block diagram of an embodiment of the line receiving module 101 of the present invention.
[0020] Figure 3 It is a principle logic block diagram of an embodiment of the hardware forwarding module 102 of the present invention.
[0021] Figure 4 It is a principle logic block diagram of an embodiment of the domestic operating system module 103 of the present invention.
[0022] Figure 5 It is a principle logic block diagram of an embodiment of the line sending module 104 of the present invention. DETAILED DESCRIPTION
[0023] Reference Figures 1 to 5The present invention is composed of a line receiving module 101, a hardware forwarding module 102, a domestic operating system module 103 and a line sending module 104.
[0024] Figure 1 This is a principle logic block diagram of the present invention, and the embodiments are as follows Figure 1 Connect related modules. The line receiving module 101 is used to perform PHY layer reception processing on the received data, including optical-to-electrical conversion, line decoding, clock recovery, and serial-to-parallel conversion, and then send the recovered clock and data to the hardware forwarding module 102;
[0025] The hardware forwarding module 102 is used to classify the data sent by the line receiving module 101 into two categories: control management data and ordinary data. The control management data is directly forwarded to the domestic operating system module 103. If the table lookup is successful, the ordinary data is sent to the line sending module 104. If the table lookup fails, it is sent to the domestic operating system module 103. The hardware forwarding module 102 is also used to send the control management data and ordinary data sent by the domestic operating system module 103 to the line sending module 104.
[0026] The domestic operating system module 103 is used to perform address resolution and routing interaction processing on the received control management data, and send the generated response information to the hardware forwarding module 102 in the form of control management data; it is also used to search the software forwarding table according to the data address for the table lookup failure data sent by the hardware forwarding module 102. If the table lookup is successful, the hardware forwarding table of the hardware forwarding module 102 is updated and the data is sent to the hardware forwarding module 102 again. If the table lookup fails, the data packet is discarded.
[0027] The line sending module 104 is used to perform PHY layer sending processing on the received data, including parallel-to-serial conversion, line coding and electrical-to-optical conversion.
[0028] Figure 2 This is a principle logic block diagram of the line receiving module 101 of the present invention. Figure 2 Connecting lines. The line receiving module 101 of the present invention performs line interface reception processing functions and primarily includes a media access module 105 and a line decoding module 106. The media access module 105 implements line interface functions such as optical-to-electrical conversion, clock recovery, and auto-negotiation. The line decoding module 106 performs serial-to-parallel conversion, channel decoding, and collision detection.
[0029] Figure 3 This is a principle logic block diagram of the hardware forwarding module 102 of the present invention. Figure 3Connecting lines. The hardware forwarding module 102 of the present invention completes the forwarding of various types of data such as LAN, IP, MPLS, etc. based on the hardware chip, and mainly includes a data exchange module 107, a lookup table storage module 108 and a data packet storage module 109. The data exchange module 107 is the core of the hardware forwarding module 102, and completes the forwarding of various types of data under the control of the domestic operating system module 103. The lookup table storage module 108 is mainly composed of TCAM and SRAM, and stores various lookup tables such as MAC address table, IP forwarding table, ACL table, etc. required for data forwarding. The data packet storage module 109 is mainly composed of DDR2SDRAM, and stores data packets received from the line receiving module 101 and the domestic operating system module 103.
[0030] Figure 4 This is a principle logic block diagram of the domestic operating system module 103 of the present invention. Figure 4 The domestic operating system module 103 of the present invention completes the control processing functions such as the address resolution protocol and the routing protocol, and provides the software forwarding function when the hardware forwarding module 102 fails to forward. It mainly includes a routing protocol module 110, a software forwarding module 111 and an address resolution protocol module 112.
[0031] The routing protocol module 110 is used to receive the routing protocol data in the control management data sent by the hardware forwarding module 102, perform the shortest route calculation and protocol information interaction, generate the forwarding table information and send it to the software forwarding module 111, and send the generated protocol interaction data as control management data to the hardware forwarding module 102;
[0032] The software forwarding module 111 is used to receive the forwarding table information sent by the routing protocol module 110, update the internal software forwarding table, and extract the address information from the ordinary data received by the hardware forwarding module 102, and use the address information as a keyword to perform a table lookup in the software forwarding table; if the table lookup is successful, the hardware forwarding table of the hardware forwarding module 102 is updated, the data is sent to the hardware forwarding module 102 again, and a table entry update message is generated and sent to the address resolution protocol module 112; if the table lookup fails, the data is discarded;
[0033] The address resolution protocol module 112 is used to run the ARP protocol, map the IP address to the MAC address, and periodically refresh the ARP table. If no update message of an ARP table entry is received from the software forwarding module 111 within a specific time period, an ARP request of the corresponding ARP table entry is initiated and sent to the hardware forwarding module 102 as control management data to be broadcasted to the entire network. If no ARP reply is received (the ARP reply is transmitted through the line interface via the line receiving module 101 and the hardware forwarding module 102), it means that the host corresponding to the ARP table entry has left the network, and the corresponding ARP table entry is deleted. If an ARP reply is received, it means that the corresponding host has left the network. If the host of the ARP table entry is still running on the network, the corresponding ARP table entry remains unchanged; if a table update message corresponding to a certain ARP table entry is received from the software forwarding module 111 within a specific time period, the corresponding ARP table entry remains unchanged; the address resolution protocol module 112 is also used to analyze the address resolution protocol data in the control management data received from the hardware forwarding module 102. If it is an address resolution message sent to itself, an address resolution response message is generated as control management data and sent to the hardware forwarding module 102; if it is an address resolution response message sent to itself, the ARP table is updated according to the message content; if it is not a message sent to itself, it is discarded.
[0034] Figure 5 This is a principle logic block diagram of the line sending module 104 of the present invention. Figure 5 Connecting lines. The line transmission module 104 of the present invention performs the PHY layer transmission processing functions specified in IEEE802.3, including parallel-to-serial conversion, line coding, and electro-optical conversion. It primarily includes a line coding module 113 and a media transmission module 114. The line coding module 113 performs functions such as channel coding and parallel-to-serial conversion, while the media transmission module 114 performs functions such as idle detection and electro-optical conversion.
Claims
1. An improved address resolution device based on a domestic operating system, characterized by: It includes a line receiving module (101), a hardware forwarding module (102), a domestic operating system module (103) and a line sending module (104); The line receiving module (101) is used to perform PHY layer receiving processing on the received data, including photoelectric conversion, line decoding, clock recovery and serial-to-parallel conversion, and then send the recovered clock and data to the hardware forwarding module (102); The hardware forwarding module (102) is used to classify the data into two categories, control management data and ordinary data, according to the address information in the data sent by the line receiving module (101). The control management data is directly forwarded to the domestic operating system module (103); if the ordinary data is successfully found in the table lookup, it is sent to the line sending module (104); if the table lookup fails, it is sent to the domestic operating system module (103); and it is also used to send the control management data and ordinary data sent by the domestic operating system module (103) to the line sending module (104); The domestic operating system module (103) is used to perform address resolution and routing interaction processing on the received control management data, and send the generated response information to the hardware forwarding module (102) in the form of control management data; it is also used to search the software forwarding table according to the data address for the table lookup failure data sent by the hardware forwarding module (102); if the table lookup is successful, the hardware forwarding table of the hardware forwarding module (102) is updated, and the data is sent to the hardware forwarding module (102); if the table lookup fails, the data packet is discarded; The line transmission module (104) is used to perform PHY layer transmission processing on the received data, including parallel-to-serial conversion, line coding and electro-optical conversion; Wherein, the domestic operating system module (103) includes a routing protocol module (110), a software forwarding module (111) and an address resolution module (112); The routing protocol module (110) is used to receive routing protocol data in the control management data sent by the hardware forwarding module (102), perform shortest route calculation and protocol information interaction, generate forwarding table information and send it to the software forwarding module (111), and send the generated protocol interaction data as control management data to the hardware forwarding module (102); The software forwarding module (111) is used to receive the forwarding table information sent by the routing protocol module (110), update the internal software forwarding table, and extract the address information from the ordinary data received by the hardware forwarding module (102), and use the address information as a keyword to perform a table lookup in the software forwarding table; if the table lookup is successful, the hardware forwarding table of the hardware forwarding module (102) is updated, the ordinary data is sent to the hardware forwarding module (102), and a table entry update message is generated and sent to the address resolution protocol module (112); if the table lookup fails, the data is discarded; The address resolution protocol module (112) is used to run the ARP protocol, perform mapping between IP addresses and MAC addresses, and periodically refresh the ARP table; if no table update message of a certain ARP table item is received from the software forwarding module (111) within a certain time period, an ARP request for the corresponding ARP table item is actively initiated and sent to the hardware forwarding module (102) as control management data to be broadcast to the entire network; if no ARP response is received, it means that the host corresponding to the ARP table item has left the network, and the corresponding ARP table item is deleted; if an ARP response is received, it means that the host corresponding to the ARP table item is still running on the network, and the corresponding ARP table item is retained unchanged; If a table entry update message corresponding to a certain ARP table entry is received from the software forwarding module (111) within a certain specific time period, the corresponding ARP table entry is retained unchanged; the address resolution protocol module (112) is also used to analyze the address resolution protocol data in the control management data received from the hardware forwarding module (102); if it is an address resolution message sent to itself, an address resolution response message is generated as control management data and sent to the hardware forwarding module (102); if it is an address resolution response message sent to itself, the ARP table is updated according to the message content; if it is not a message sent to itself, it is discarded.
Citation Information
Patent Citations
Method for dynamically updating host routing table entries of Ethernet switch and switch
CN103560961A
Method for automatically updating host routing table entries of Ethernet switch and switch
CN103560962A