Data forwarding method and device
By introducing flexible forwarding mode and fault forwarding mode in network equipment, the problem of unutilized forwarding capacity of backup master control is solved, and data forwarding efficiency and equipment applicability are improved.
Patent Information
- Application Number
- CN202410364877.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-03-27
- Publication Date
- 2025-09-30
AI Technical Summary
The backup mode of the master control device in existing network equipment causes the forwarding capability of the standby master control to be in a backup state, thereby reducing the utilization rate of chip forwarding resources.
Provides multiple forwarding modes, including flexible forwarding mode and fault forwarding mode, allowing the main control device to flexibly call all interface boards to forward data, thereby improving data forwarding efficiency.
It can still effectively process and forward data in the event of a failure, which improves the data forwarding efficiency and applicable scenarios of network equipment and improves feasibility.
Smart Images

Figure CN120729705A_ABST
Abstract
Description
Technical Field
[0001] The embodiments of the present application relate to the field of communication technology, and in particular to a data forwarding method and device. Background Art
[0002] To achieve high reliability, existing network equipment data forwarding solutions typically employ two master forwarding chips in a 1:1 backup configuration. If the active master fails, the network device quickly switches to the backup master. In this scenario, since both the active and backup master remain active, the backup master's forwarding capabilities effectively function as a backup, reducing the network device's chip forwarding resource utilization. Summary of the Invention
[0003] The embodiments of the present application provide a data forwarding method and device, which can provide multiple forwarding modes and improve the data forwarding efficiency of network devices in flexible forwarding modes.
[0004] In a first aspect, an embodiment of the present application provides a data forwarding method, which is applied to a network device, wherein the network device includes a first network forwarding device and a second network forwarding device, the first network forwarding device includes at least one first forwarding chip and at least one first interface board, and the second network forwarding device includes at least one second forwarding chip and at least one second interface board. The method includes: obtaining forwarding mode information, the forwarding mode information indicates a mode in which the network device processes forwarded data, and the forwarding mode indicated by the forwarding mode information includes a flexible forwarding mode; determining a forwarding mode based on the forwarding mode information; receiving at least one first forwarding data through at least one first interface board, and receiving at least one second forwarding data through at least one second interface board; in a flexible forwarding mode, transmitting at least one first forwarding data to at least one first forwarding chip, and transmitting at least one second forwarding data to at least one second forwarding chip; in a flexible forwarding mode, transmitting at least one first forwarding data to at least one first interface board and at least one second interface board through at least one first forwarding chip, and transmitting at least one second forwarding data to at least one first interface board and at least one second interface board through at least one second forwarding chip.
[0005] In this possible implementation, the network device can provide a flexible forwarding mode. In the flexible forwarding mode, the first forwarding chip can call all interface boards of the network device to forward data, thereby improving the data forwarding efficiency of the network device.
[0006] In one possible implementation, when the forwarding mode information is a fault forwarding mode and at least one second forwarding chip fails, the method further includes: receiving at least one first forwarding data through at least one first interface board, and receiving at least one second forwarding data through at least one second interface board; transmitting at least one first forwarding data and at least one second forwarding data to at least one first forwarding chip; transmitting at least one first forwarding data and at least one second forwarding data to at least one first interface board and at least one second interface board through at least one first forwarding chip.
[0007] This possible implementation also provides a fault forwarding mode, which can process all forwarding data when a forwarding chip fails, thereby enhancing the applicable scenarios of the network device and improving the feasibility of the embodiments of the present application.
[0008] In one possible implementation, the forwarding mode information is a standard forwarding mode, and the standard forwarding mode indicates that the first forwarding chip processes the forwarding data, and the second forwarding chip serves as a backup. The method also includes: receiving at least one first forwarding data through at least one first interface board, and receiving at least one second forwarding data through at least one second interface board; transmitting at least one first forwarding data and at least one second forwarding data to at least one first forwarding chip; transmitting at least one first forwarding data and at least one second forwarding data to at least one first interface board and at least one second interface board through at least one first forwarding chip.
[0009] In this possible implementation, a standard forwarding mode is also provided, which enhances the applicable scenarios of the network equipment and improves the feasibility of the embodiments of the present application.
[0010] In one possible implementation, the first network forwarding device includes a first processor, the second network forwarding device includes a second processor, and obtaining forwarding mode information includes: obtaining first forwarding mode information through the first processor of the first network forwarding device, the first forwarding mode information indicating the mode in which the first network forwarding device processes forwarded data; obtaining second forwarding mode information through the second processor of the second network forwarding device, the second forwarding mode information indicating the mode in which the second network forwarding device processes forwarded data.
[0011] In the second aspect, an embodiment of the present application provides a data forwarding method, which is applied to a first network forwarding device, wherein the first network forwarding device includes at least one first forwarding chip and at least one first interface board, the method including: obtaining forwarding mode information, the forwarding mode information indicating the mode in which the first network forwarding device processes forwarded data, the forwarding mode indicated by the forwarding mode information including a flexible forwarding mode; determining the forwarding mode based on the forwarding mode information; receiving at least one first forwarding data through at least one first interface board; in the flexible forwarding mode, transmitting at least one first forwarding data to at least one first forwarding chip; in the flexible forwarding mode, transmitting at least one first forwarding data to at least one first interface board and at least one second interface board through at least one first forwarding chip, the second interface board being the interface board of the second forwarding device, and the network device including a first forwarding device and a second forwarding device.
[0012] In this possible implementation, the network forwarding device can provide a flexible forwarding mode. In the flexible forwarding mode, the first forwarding chip can call the interface board of other network forwarding devices to forward data, thereby improving the data forwarding efficiency of the network forwarding device.
[0013] In one possible implementation, when the forwarding mode information is a fault forwarding mode and at least one second forwarding chip fails, the above method also includes: receiving at least one first forwarding data through at least one first interface board; receiving at least one second forwarding data through the first forwarding chip; transmitting at least one first forwarding data to at least one first forwarding chip; transmitting at least one first forwarding data and at least one second forwarding data to at least one first interface board and at least one second interface board through at least one first forwarding chip.
[0014] In one possible implementation, the forwarding mode information is a standard forwarding mode, and the standard forwarding mode indicates that the first forwarding chip processes the forwarding data, and the second forwarding chip serves as a backup. The above method also includes: receiving at least one first forwarding data through at least one first interface board; receiving at least one second forwarding data through the first forwarding chip; transmitting at least one first forwarding data and at least one second forwarding data to at least one first forwarding chip; in the standard forwarding mode, transmitting at least one first forwarding data and at least one second forwarding data to at least one first interface board and at least one second interface board through at least one first forwarding chip.
[0015] In one possible implementation, the first network forwarding device includes a first processor, and the obtaining of the forwarding mode information includes: obtaining first forwarding mode information through the first processor of the first network forwarding device, where the first forwarding mode information indicates a mode in which the first network forwarding device processes forwarded data.
[0016] In a third aspect, an embodiment of the present application provides a network device, which includes a first network forwarding device and a second network forwarding device, the first network forwarding device including a first processor, at least one first forwarding chip and at least one first interface board, the second network forwarding device including a second processor, at least one second forwarding chip and at least one second interface board, wherein: the first processor and the second processor are used to obtain forwarding mode information, the forwarding mode information indicates the mode in which the network device processes forwarded data, and the forwarding mode indicated by the forwarding mode information includes a flexible forwarding mode; the first processor and the second processor are also used to determine the forwarding mode based on the forwarding mode information; at least one first interface board is used to receive at least one first forwarding data and transmit it to at least one first forwarding chip in a flexible forwarding mode; at least one second interface board is used to receive at least one second forwarding data and transmit it to at least one second forwarding chip in a flexible forwarding mode; at least one first forwarding chip is used to transmit at least one first forwarding data to at least one first interface board and at least one second interface board in a flexible forwarding mode, and at least one second forwarding chip is used to transmit at least one second forwarding data to at least one first interface board and at least one second interface board in a flexible forwarding mode.
[0017] In one possible implementation, when the forwarding mode information is a fault forwarding mode and at least one second forwarding chip fails, at least one first interface board is used to receive at least one first forwarding data and transmit it to at least one first forwarding chip; at least one second interface board is used to receive at least one second forwarding data and transmit it to at least one first forwarding chip; and at least one first forwarding chip is used to transmit at least one first forwarding data and at least one second forwarding data to at least one first interface board and at least one second interface board.
[0018] In one possible implementation, the forwarding mode information also includes a standard forwarding mode, and the standard forwarding mode indicates that the first forwarding chip processes the forwarding data, the second forwarding chip serves as a backup, at least one first interface board is used to receive at least one first forwarding data and transmit it to at least one first forwarding chip; at least one second interface board is used to receive at least one second forwarding data and transmit it to at least one first forwarding chip; at least one first forwarding chip is used to transmit at least one first forwarding data and at least one second forwarding data to at least one first interface board and at least one second interface board.
[0019] In a fourth aspect, an embodiment of the present application provides a network device, which includes: an acquisition module for acquiring forwarding mode information, the forwarding mode information indicating a mode in which the network device processes forwarding data, and the forwarding mode indicated by the forwarding mode information includes a flexible forwarding mode; a determination module for determining the forwarding mode based on the forwarding mode information; a receiving module for receiving at least one first forwarding data through at least one first interface board and at least one second forwarding data through at least one second interface board; a first transmission module for transmitting at least one first forwarding data to at least one first forwarding chip and at least one second forwarding data to at least one second forwarding chip in a flexible forwarding mode; a second transmission module for transmitting at least one first forwarding data to at least one first interface board and at least one second interface board through at least one first forwarding chip and at least one second forwarding data to at least one first interface board and at least one second interface board through at least one second forwarding chip in a flexible forwarding mode.
[0020] In one possible implementation, when the forwarding mode information is a fault forwarding mode and at least one second forwarding chip fails, the receiving module is specifically used to receive at least one first forwarding data through at least one first interface board and receive at least one second forwarding data through at least one second interface board; the first transmission module is specifically used to transmit at least one first forwarding data and at least one second forwarding data to at least one first forwarding chip; the second transmission module is specifically used to transmit at least one first forwarding data and at least one second forwarding data to at least one first interface board and at least one second interface board through at least one first forwarding chip.
[0021] In one possible implementation, the forwarding mode information is a standard forwarding mode, and the standard forwarding mode indicates that the first forwarding chip processes the forwarding data, and the second forwarding chip serves as a backup. The receiving module is specifically used to receive at least one first forwarding data through at least one first interface board and receive at least one second forwarding data through at least one second interface board; the first transmission module is specifically used to transmit at least one first forwarding data and at least one second forwarding data to at least one first forwarding chip; the second transmission module is specifically used to transmit at least one first forwarding data and at least one second forwarding data to at least one first interface board and at least one second interface board through at least one first forwarding chip.
[0022] In a fifth aspect, an embodiment of the present application provides a network device comprising: a processor and a memory. The processor is coupled to the memory; the memory is configured to store computer instructions, which are loaded and executed by the processor to enable the network device to implement any one of the methods provided in the first aspect.
[0023] In a sixth aspect, an embodiment of the present application provides a network forwarding device, comprising: a processor and a memory. The processor is coupled to the memory; the memory is configured to store computer instructions, which are loaded and executed by the processor to enable the network forwarding device to implement any one of the methods provided in the second aspect.
[0024] In the seventh aspect, an embodiment of the present application provides a chip, which includes: a processor and an interface circuit; the interface circuit is used to receive code instructions and transmit them to the processor; the processor is used to run the code instructions to execute any one of the methods provided in the first aspect.
[0025] In an eighth aspect, an embodiment of the present application provides a chip comprising: a processor and an interface circuit; the interface circuit is used to receive code instructions and transmit them to the processor; and the processor is used to run the code instructions to execute any one of the methods provided in the second aspect.
[0026] In a ninth aspect, an embodiment of the present application provides a computer-readable storage medium, which stores at least one computer program instruction, and the computer program instruction is loaded and executed by a processor to implement any one of the methods provided in the first aspect above.
[0027] In the tenth aspect, an embodiment of the present application provides a computer-readable storage medium, which stores at least one computer program instruction, and the computer program instruction is loaded and executed by a processor to implement any one of the methods provided in the second aspect above.
[0028] In the eleventh aspect, an embodiment of the present application provides a computer program product, comprising computer execution instructions, which, when the computer execution instructions are run on a computer, enable the computer to execute any one of the methods provided in the first aspect.
[0029] In a twelfth aspect, an embodiment of the present application provides a computer program product, comprising computer execution instructions, which, when the computer execution instructions are run on a computer, enable the computer to execute any one of the methods provided in the second aspect.
[0030] The technical effects brought about by any implementation method in the third aspect to the tenth aspect can be referred to the technical effects brought about by the corresponding implementation methods in the first aspect to the second aspect, and will not be repeated here. BRIEF DESCRIPTION OF THE DRAWINGS
[0031] Figure 1 A schematic diagram of a network device structure for a data forwarding method;
[0032] Figure 2 A schematic diagram of a scenario of a data forwarding method;
[0033] Figure 3A schematic diagram of the structure of a network device provided in an embodiment of the present application;
[0034] Figure 4 A flowchart of a data forwarding method provided in an embodiment of the present application;
[0035] Figure 5 A schematic diagram of a data forwarding method according to an embodiment of the present invention;
[0036] Figure 6 A schematic diagram of another data forwarding method provided in an embodiment of the present application;
[0037] Figure 7 A schematic diagram of another data forwarding method provided in an embodiment of the present application;
[0038] Figure 8A A schematic diagram of another data forwarding method provided in an embodiment of the present application;
[0039] Figure 8B A schematic diagram of a forwarding mode switching scenario provided in an embodiment of the present application;
[0040] Figure 9 A schematic diagram of the structure of a network device provided in an embodiment of the present application;
[0041] Figure 10 A schematic diagram of the structure of a network forwarding device provided in an embodiment of the present application;
[0042] Figure 11 A schematic diagram of the structure of another network device provided in an embodiment of the present application;
[0043] Figure 12 A schematic diagram of the structure of another network forwarding device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0044] In the description of this application, unless otherwise specified, " / " indicates that the objects associated before and after are in an "or" relationship, for example, A / B can represent A or B; "and / or" in this application is merely a description of the association relationship of associated objects, indicating that three relationships may exist, for example, A and / or B can represent: A exists alone, A and B exist at the same time, and B exists alone, where A and B can be singular or plural.
[0045] In the description of this application, unless otherwise specified, "plurality" means two or more than two. "At least one of the following" or similar expressions refers to any combination of these items, including any combination of single or plural items. For example, at least one of a, b, or c can mean: a, b, c, ab, ac, bc, or abc, where a, b, and c can be single or plural.
[0046] In addition, to facilitate the clear description of the technical solutions of the embodiments of the present application, in the embodiments of the present application, the words "first" and "second" are used to distinguish between identical or similar items with substantially the same functions and effects. Those skilled in the art will understand that the words "first" and "second" do not limit the quantity or execution order, and the words "first" and "second" do not necessarily mean different.
[0047] In the embodiments of this application, words such as "exemplary" or "for example" are used to indicate examples, illustrations, or descriptions. Any embodiment or design described as "exemplary" or "for example" in the embodiments of this application should not be construed as being preferred or advantageous over other embodiments or designs. Rather, the use of words such as "exemplary" or "for example" is intended to present the relevant concepts in a concrete manner to facilitate understanding.
[0048] It will be understood that the “embodiment” mentioned throughout the specification means that the specific features, structures or characteristics related to the embodiment are included in at least one embodiment of the present application. Therefore, the various embodiments throughout the specification do not necessarily refer to the same embodiment. In addition, these specific features, structures or characteristics can be combined in one or more embodiments in any suitable manner. It will be understood that in the various embodiments of the present application, the size of the sequence number of each process does not mean the order of execution. The execution order of each process should be determined by its function and internal logic, and should not constitute any limitation on the implementation process of the embodiment of the present application.
[0049] It is understood that some optional features in the embodiments of the present application may, in certain scenarios, be implemented independently of other features, such as the solution on which they are currently based, to solve corresponding technical problems and achieve corresponding effects. They may also be combined with other features in certain scenarios as needed. Accordingly, the devices provided in the embodiments of the present application may also implement these features or functions accordingly, which will not be described in detail here.
[0050] In this application, unless otherwise specified, the same or similar parts between the various embodiments can be referenced to each other. In this application, unless otherwise specified and there is no logical conflict between the various embodiments, the terms and / or descriptions between different embodiments are consistent and can be referenced to each other. Different embodiments can be combined to form new embodiments based on their inherent logical relationships. The following implementation methods of this application do not constitute a limitation on the scope of protection of this application.
[0051] When forwarding data, network devices can adopt either a distributed or centralized architecture. A distributed architecture integrates a hardware forwarding module into every interface card or line card in the network device. This hardware forwarding module can be an application-specific integrated circuit (ASIC) or a neural processing unit (NPU). Each line card can perform forwarding, even independently. This architecture is called a distributed architecture. Network devices no longer require a dedicated forwarding module to serve the forwarding function of the entire network device. Instead, each line card can perform Ethernet / routing table query and forwarding through the forwarding module / chip, enabling independent forwarding on the line card.
[0052] A centralized architecture means that the network device has a dedicated hardware forwarding module to forward data packets for the network device. This hardware forwarding module can be an ASIC or NPU. Each interface board / line card module of the switch, such as the peripheral component interconnect (PIC) or line processing unit (LPU), does not have Ethernet / routing processing capabilities. Data packets need to be sent from the line card to the centralized forwarding module to query the Ethernet / routing forwarding table for forwarding. The constraint of the centralized forwarding architecture is that the forwarding performance of the entire device is limited by the capabilities of the hardware forwarding module / chip on its centralized forwarding module. In the case of a centralized forwarding architecture, if the forwarding module fails, the forwarding capability of the entire switch device will be lost. Therefore, reliability needs to be ensured through redundancy of the forwarding module.
[0053] With the improvement of forwarding chip capabilities, centralized architecture is increasingly being applied in various scenarios and industries. Compared with distributed architecture, centralized architecture has the following advantages:
[0054] 1. The forwarding model is simple, the complexity is low, and the control plane has stronger processing performance;
[0055] 2. Line cards are simple, low cost, and have low failure rates;
[0056] 3. No need to exchange network cards, reducing failure points;
[0057] 4. The forwarding module supports 1:1 redundant backup and has high switching performance.
[0058] like Figure 1 As shown in the figure, for centralized frame-type network devices, the forwarding chip is typically located in the network device's main controller. To achieve high reliability, network devices typically use a 1:1 backup of the forwarding chips in two main controllers. If the active main controller fails, the network device quickly switches to the backup main controller. In this scenario, because both the active and backup main controllers are always active, the backup main controller's forwarding capability effectively operates in a backup forwarding state, reducing the network device's chip forwarding resource utilization.
[0059] For example Figure 2 As shown in the figure, the bandwidth capacity of the master forwarding chip is M Tbps. If the system has N slots, the maximum forwarding capacity is M Tbps when fully populated, and the average forwarding bandwidth per slot is M / N Tbps. Under normal operating conditions, the forwarding chips of the two MPUs are backed up in a 1:1 redundant backup, and the forwarding capacity of the backup master is not used, resulting in low overall chip forwarding resource utilization in the network device.
[0060] An embodiment of the present application provides a data forwarding method, which can provide multiple forwarding modes and has a forwarding mode that can improve forwarding bandwidth. The method includes: obtaining forwarding mode information, the forwarding mode information indicating a mode in which a network device processes forwarded data, the forwarding mode indicated by the forwarding mode information including a flexible forwarding mode; determining a forwarding mode according to the forwarding mode information; receiving at least one first forwarding data through at least one first interface board, and receiving at least one second forwarding data through at least one second interface board; in the flexible forwarding mode, transmitting at least one first forwarding data to at least one first forwarding chip, and transmitting at least one second forwarding data to at least one second forwarding chip; in the flexible forwarding mode, transmitting at least one first forwarding data to at least one first interface board and at least one second interface board through at least one first forwarding chip, and transmitting at least one second forwarding data to at least one first interface board and at least one second interface board through at least one second forwarding chip.
[0061] like Figure 3 As shown, the data forwarding method in the embodiment of the present application can be applied to Figure 3The network device shown includes a first main control board MPU1 (i.e., a first forwarding device) and a second main control board MPU2 (i.e., a second forwarding device). The first main control board includes a first processor CPU1, a first forwarding chip LSW1, a first interface board 1 and its corresponding first slot Slot1, a first interface board 2 and its corresponding second slot Slot2. The second main control board includes a second processor CPU2, a second forwarding chip LSW2, a second interface board 1 and its corresponding third slot Slot3, a second interface board 2 and its corresponding fourth slot Slot4.
[0062] The first processor CPU1 is used to control the corresponding first main control board to forward data, and the second processor CPU2 is used to control the corresponding second main control board to forward data.
[0063] The first forwarding chip LSW1 and the second forwarding chip LSW2 are used to forward received forwarding data according to a specified forwarding mode.
[0064] The first interface board 1 and the corresponding first slot Slot1, the first interface board 2 and the corresponding second slot Slot2, the second interface board 1 and the corresponding third slot Slot3, and the second interface board 2 and the corresponding fourth slot Slot4 are used to send and receive forwarding data.
[0065] It can be understood that the network device in the embodiment of the present application may include two main control boards. In addition, it may also include more main control boards, which is not limited here.
[0066] It can be understood that the main control board of the network device in the embodiment of the present application may include a forwarding chip. In addition, it may also include more forwarding chips. Each forwarding chip can forward data according to the indicated forwarding mode, which is not specifically limited here.
[0067] It can be understood that a main control board of the network device in the embodiment of the present application may include two interface boards, each interface board includes a corresponding slot, each slot may include multiple ports, and in addition, more interface boards and corresponding slots may be included, and each interface board and corresponding slot can send and receive forwarding data. The specific details are not limited here.
[0068] It is understood that in the embodiments of the present application, the execution subject may perform some or all of the steps in the embodiments of the present application. These steps or operations are merely examples, and the embodiments of the present application may also perform other operations or variations of various operations. In addition, the various steps may be performed in a different order than those presented in the embodiments of the present application, and it is possible that not all operations in the embodiments of the present application need to be performed.
[0069] It should be noted that the message names between the devices or the names of the parameters in the messages in the following embodiments of the present application are only examples. Other names may be used in specific implementations, and the embodiments of the present application do not specifically limit this.
[0070] like Figure 4 As shown, an embodiment of the present application provides a data forwarding method, the method comprising:
[0071] 401. The network device obtains forwarding mode information.
[0072] The network device obtains forwarding mode information, which indicates a mode for the network device to process received forwarding data. That is, the forwarding mode information indicates a forwarding mode, and the network device will forward the received forwarding data according to the forwarding mode.
[0073] In the embodiment of the present application, the forwarding mode information may include a flexible forwarding mode and a fault forwarding mode.
[0074] like Figure 5 As shown, this flexible forwarding mode can instruct the main control board in the network device to flexibly call all interface boards to forward received forwarding data. For example, forwarding data received by the first main control board can be sent out through the slot of the second main control board, or forwarded out through the slot of the first main control board.
[0075] like Figure 6 As shown, this fail-forwarding mode can indicate that a portion of the network device's forwarding functions has failed. The network device then processes received forwarding data using the remaining normal forwarding functions. For example, if the forwarding chip on the second main control board fails, the received forwarding data can be transmitted to the first main control board for processing. After receiving the forwarding data, the first main control board can use the slots of the first and second main control boards to perform forwarding processing.
[0076] like Figure 7 As shown, in addition to this, the forwarding mode information may also include other forwarding modes, for example, the forwarding mode information may also include a standard forwarding mode, which may instruct the network device to forward the received forwarding data according to a preset forwarding path. For example, the standard forwarding mode sets that all forwarding data received by the slot of the first main control board is transmitted to the forwarding chip of the first main control board, and the forwarding chip of the first main control board forwards all the received forwarding data through the slot of the first main control board. The same is true for the second main control board. All forwarding data received by the slot of the second main control board is transmitted to the forwarding chip of the second main control board, and the forwarding chip of the second main control board forwards all the received forwarding data through the slot of the second main control board.
[0077] Specifically, the network device may obtain the forwarding mode information by having a CPU of a main control board of the network device receive the forwarding mode information, where the forwarding mode information indicates a forwarding mode for the main control board to perform data forwarding. After receiving the forwarding mode information, the CPU of the main control board may send a forwarding mode control instruction to a forwarding chip of the main control board, where the forwarding mode control instruction instructs the forwarding chip to forward the forwarding data according to the forwarding mode indicated by the forwarding mode information.
[0078] In one possible implementation, the CPU of the main control board can send forwarding mode control instructions to the forwarding chip of the main control board. In addition, the CPU of the main control board can also directly send the received forwarding mode information to the forwarding chip of the main control board, and the forwarding chip forwards data according to the forwarding mode indicated by the forwarding mode information.
[0079] In an embodiment of the present application, the forwarding mode information received by the CPU of the main control board of the network device may be sent to the network device by other devices, or the user may perform related operations on the network device, and other modules of the network device may generate the forwarding mode information and transmit it to the CPU of the main control board of the network device. In addition to this, other acquisition methods may also be used, which are not limited here.
[0080] In the embodiments of the present application, it can be understood that the forwarding mode of the network device and the network forwarding device of the network device can be controlled by forwarding mode information.
[0081] 402. The network device receives first forwarded data and second forwarded data.
[0082] The network device receives the first forwarding data and the second forwarding data through the slot of the interface board.
[0083] Specifically, the network device in the embodiment of the present application includes two main control boards (i.e., network forwarding devices), and multiple slots (e.g., Slot 1 to Slot 4) of the two main control boards can receive forwarding data. For example, the first interface board 1 can receive first forwarding data, and the second interface board 1 can receive second forwarding data.
[0084] In the embodiments of the present application, forwarded data refers to data that needs to be forwarded by the network device. The forwarded data can be a single piece of data or a group of data; it can be forwarded in a packaged form or in batches, and the specific details are not limited here. Therefore, it can be understood that the network device receives the first forwarded data and the second forwarded data once or multiple times, and the specific details are not limited here.
[0085] In the embodiment of the present application, the network device receiving the first forwarding data and the second forwarding data is taken as an example for explanation. In addition, the network device can also receive one or more amounts of forwarding data, which is not specifically limited here.
[0086] 403. According to the forwarding mode, the interface board of the network device transmits the received first forwarding data and second forwarding data to the forwarding chip.
[0087] According to the forwarding mode indicated by the forwarding mode information, the interface board of the network device transmits the received first forwarding data and second forwarding data to the forwarding chip.
[0088] like Figure 5 As shown, specifically, when the forwarding mode indicated by the forwarding mode information is a flexible forwarding mode, the first interface board of the network device transmits the first forwarding data to the first forwarding chip; the second interface board of the network device transmits the second forwarding data to the second forwarding chip.
[0089] like Figure 6 As shown, specifically, when the forwarding mode indicated by the forwarding mode information is a fault forwarding mode, and the fault is a fault of the second forwarding chip, the first interface board of the network device transmits the first forwarding data to the first forwarding chip; the second interface board of the network device also transmits the second forwarding data to the first forwarding chip; thereby, the fault of the second forwarding chip does not affect the network device's forwarding of the second forwarding data.
[0090] Specifically, when the forwarding mode indicated by the forwarding mode information is a fault forwarding mode and the fault is a failure of the first forwarding chip, the second interface board of the network device transmits the second forwarding data to the second forwarding chip; the first interface board of the network device also transmits the first forwarding data to the second forwarding chip; thereby, the failure of the first forwarding chip does not affect the network device's forwarding of the second forwarding data.
[0091] like Figure 7 As shown, specifically, when the forwarding mode indicated by the forwarding mode information is the standard forwarding mode, the first interface board of the network device transmits the first forwarding data to the first forwarding chip; the second interface board of the network device transmits the second forwarding data to the second forwarding chip.
[0092] 404. According to the forwarding mode, the forwarding chip of the network device transmits the forwarding data to the interface board.
[0093] According to the forwarding mode, the forwarding chip of the network device transmits the received first forwarding data and second forwarding data to the first interface board and / or the second interface board, that is, the forwarding chip can call all slots of the network device to forward the first forwarding data and the second forwarding data.
[0094] Specifically, if Figure 5 As shown, when the forwarding mode is flexible, the first forwarding chip of the network device transmits the first forwarding data to the first interface board and / or the second interface board; the second forwarding chip of the network device transmits the second forwarding data to the first interface board and / or the second interface board. That is, in flexible forwarding mode, both the first and second forwarding chips can call on all interface boards of the network device to forward forwarding data. The first forwarding chip on the first main control board can call on the second interface board on the second main control board to forward data, and the second forwarding chip on the second main control board can also call on the first interface board on the first main control board.
[0095] like Figure 6 As shown, specifically, when the forwarding mode is the fault forwarding mode and the fault is the failure of the second forwarding chip, the network device will send all received forwarding data to the first forwarding chip, and then the first forwarding chip can call the first interface board and the second interface board to transmit the received first forwarding data and second forwarding data to the first interface board and / or the second interface board.
[0096] Specifically, when the forwarding mode is the fault forwarding mode and the fault is the failure of the first forwarding chip, the network device will send all received forwarding data to the second forwarding chip, and then the second forwarding chip can call the first interface board and the second interface board to transmit the received first forwarding data and second forwarding data to the first interface board and / or the second interface board.
[0097] like Figure 7 Specifically, when the forwarding mode is the standard forwarding mode, after the first forwarding chip receives the first forwarding data, it can call the first interface board to transmit the received first forwarding data to the first interface board. After the second forwarding chip receives the second forwarding data, it can call the second interface board to transmit the received second forwarding data to the second interface board.
[0098] In the implementation of this application, it can be understood that the forwarding chip of the network device transmits the forwarding data to the interface board, which is essentially calling the interface board and its slot to send the forwarding data to other devices. Therefore, after the interface board and its slot receive the forwarding data, they will send the forwarding data to other devices.
[0099] In the embodiment of the present application, the slots corresponding to the first forwarding chip LSW1 include the first slot Slot1 and the second slot Slot2. Each slot can include multiple ports. That is, all ports in the first slot Slot1 and the second slot Slot2 are ports corresponding to the first forwarding chip LSW1. It is understood that all ports in the third slot Slot3 and the fourth slot Slot4 are ports corresponding to the second forwarding chip LSW2.
[0100] In addition, the ports in each slot can also partially correspond to the first forwarding chip LSW1 and partially correspond to LSW2. For example, the first slot Slot 1 includes eight ports, port 1 through port 8. In the first slot Slot 1, ports 1 through port 4 correspond to LSW1, and ports 5 through port 8 correspond to LSW2. The ports in other slots can also be similar to the ports in the first slot, with some corresponding to the first forwarding chip LSW1 and others corresponding to LSW2.
[0101] In the case where part of the port in each slot corresponds to the first forwarding chip LSW1 and the other part corresponds to LSW2, since the ports corresponding to LSW1 include the ports from the first slot Slot1 to the fourth slot, and the ports corresponding to LSW2 also include the ports from the first slot Slot1 to the fourth slot, the data forwarding method of the embodiment of the present application can be distinguished by the specific port in actual execution. Port 1 of the first slot Slot1 may execute the forwarding method of LSW1, and port 2 of the first slot Slot1 may execute the forwarding method of LSW1. Specifically, Figure 8A As shown in the figure, the first slot Slot1 includes 6 ports, port 1 to port 6. Ports 1 to port 3 are the ports corresponding to LSW1, and ports 4 to port 6 are the ports corresponding to LSW2. In flexible forwarding mode, ports 1 to port 3 will transmit the received data to LSW1, and ports 4 to port 6 will transmit the received data to LSW2. LSW1 can transmit the received data to all ports of the first slot Slot1, and LSW2 can also transmit the received data to all ports of the first slot Slot1. Figure 8B As shown, in the embodiment of the present application, the network device can provide multiple forwarding modes including flexible forwarding mode and standard forwarding mode in normal working state, and the network device can flexibly switch between these forwarding modes. Figure 8B As shown, the network device can switch between the flexible forwarding mode and the standard forwarding mode. It is understandable that for multiple network forwarding devices in a network device, the network device can control them to switch forwarding modes, and the specific implementation method will not be repeated.
[0102] The embodiment of the present application provides a network device 900. In the embodiment of the present application, the network device 900 can be divided into functional modules according to the above method example. For example, each functional module can be divided according to each function, or two or more functions can be integrated into one processing module. The above-mentioned integrated module can be implemented in the form of hardware or in the form of software functional modules. It should be noted that the division of modules in the embodiment of the present invention is schematic and is only a logical functional division. In actual implementation, there may be other division methods.
[0103] In the case of dividing each functional module into corresponding functional modules, Figure 9 FIG. 1 is a schematic diagram showing a possible structure of the network device 900 involved in the above embodiment. Figure 9 As shown, the network device 900 includes:
[0104] An acquisition module 901 is configured to acquire forwarding mode information, where the forwarding mode information indicates a mode in which a network device processes forwarded data, and the forwarding mode indicated by the forwarding mode information includes a flexible forwarding mode;
[0105] A determination module 902 is configured to determine a forwarding mode according to the forwarding mode information;
[0106] The receiving module 903 is configured to receive at least one first forwarded data through at least one first interface board, and receive at least one second forwarded data through at least one second interface board;
[0107] In a possible implementation, the forwarding mode is a fault forwarding mode, and the receiving module 903 is specifically configured to receive at least one first forwarding data through at least one first interface board and receive at least one second forwarding data through at least one second interface board;
[0108] In a possible implementation, the forwarding mode information is a standard forwarding mode, and the receiving module 903 is specifically configured to receive at least one first forwarding data through at least one first interface board and receive at least one second forwarding data through at least one second interface board;
[0109] A first transmission module 904 is configured to transmit at least one first forwarding data to at least one first forwarding chip and at least one second forwarding data to at least one second forwarding chip in a flexible forwarding mode;
[0110] In a possible implementation, the forwarding mode is a fault forwarding mode, and the first transmission module 904 is specifically configured to transmit at least one first forwarding data and at least one second forwarding data to at least one first forwarding chip;
[0111] In a possible implementation, the forwarding mode information is a standard forwarding mode, and the first transmission module 904 is specifically configured to transmit at least one first forwarding data and at least one second forwarding data to at least one first forwarding chip;
[0112] The second transmission module 905 is used to transmit at least one first forwarding data to at least one first interface board and at least one second interface board through at least one first forwarding chip in a flexible forwarding mode, and to transmit at least one second forwarding data to at least one first interface board and at least one second interface board through at least one second forwarding chip.
[0113] In one possible implementation, the forwarding mode is a fault forwarding mode, and the second transmission module 905 is specifically used to transmit at least one first forwarding data and at least one second forwarding data to at least one first interface board and at least one second interface board through at least one first forwarding chip.
[0114] In one possible implementation, the forwarding mode information is a standard forwarding mode, and the second transmission module 905 is specifically configured to transmit at least one first forwarding data and at least one second forwarding data to at least one first interface board and at least one second interface board through at least one first forwarding chip.
[0115] The various modules of the above-mentioned network device can also be used to perform other actions in the above-mentioned method embodiment. All relevant contents of each step involved in the above-mentioned method embodiment can be referred to the functional description of the corresponding functional module and will not be repeated here.
[0116] The embodiment of the present application provides a network forwarding device 1000. In the embodiment of the present application, the network forwarding device 1000 can be divided into functional modules according to the above method example. For example, each functional module can be divided according to each function, or two or more functions can be integrated into one processing module. The above-mentioned integrated module can be implemented in the form of hardware or in the form of a software functional module. It should be noted that the division of modules in the embodiment of the present invention is schematic and is only a logical functional division. In actual implementation, there may be other division methods.
[0117] In the case of dividing each functional module into corresponding functional modules, Figure 10 FIG. 1 is a schematic diagram showing a possible structure of the network forwarding device 1000 involved in the above embodiment. Figure 10 As shown, the network forwarding device 1000 includes:
[0118] An acquisition module 1001 is configured to acquire forwarding mode information, where the forwarding mode information indicates a mode in which the first network forwarding device processes forwarded data, and the forwarding mode indicated by the forwarding mode information includes a flexible forwarding mode;
[0119] Determining module 1002, configured to determine a forwarding mode according to the forwarding mode information;
[0120] The receiving module 1003 is configured to receive at least one first forwarding data through at least one first interface board;
[0121] In a possible implementation, when the forwarding mode information is a fault forwarding mode and at least one second forwarding chip fails, the receiving module 1003 is further configured to receive at least one first forwarding data through at least one first interface board.
[0122] In one possible implementation, the forwarding mode information is a standard forwarding mode, and the standard forwarding mode indicates that the first forwarding chip processes the forwarding data, and the second forwarding chip serves as a backup. The receiving module 1003 is also used to receive at least one first forwarding data through at least one first interface board; and receive at least one second forwarding data through the first forwarding chip.
[0123] A first transmission module 1004 is configured to transmit at least one first forwarding data to at least one first forwarding chip in a flexible forwarding mode;
[0124] In a possible implementation, when the forwarding mode information is a fault forwarding mode and at least one second forwarding chip fails,
[0125] The first transmission module 1004 is specifically configured to transmit at least one first forwarding data to at least one first forwarding chip.
[0126] In one possible implementation, the forwarding mode information is a standard forwarding mode, and the standard forwarding mode indicates that the first forwarding chip processes the forwarding data, and the second forwarding chip serves as a backup. The first transmission module 1004 is specifically used to transmit at least one first forwarding data and at least one second forwarding data to at least one first interface board and at least one second interface board through at least one first forwarding chip.
[0127] The second transmission module 1005 is used to transmit at least one first forwarding data to at least one first interface board and at least one second interface board through at least one first forwarding chip in a flexible forwarding mode, where the second interface board is an interface board of a second forwarding device, and the network device includes a first forwarding device and a second forwarding device.
[0128] In a possible implementation, when the forwarding mode information is a fault forwarding mode and at least one second forwarding chip fails, the second transmission module 1005 is specifically configured to transmit at least one first forwarding data and at least one second forwarding data to the at least one first forwarding chip.
[0129] In one possible implementation, the forwarding mode information is a standard forwarding mode, and the standard forwarding mode indicates that the first forwarding chip processes the forwarding data, and the second forwarding chip serves as a backup. The second transmission module 1005 is specifically used to: transmit at least one first forwarding data and at least one second forwarding data to at least one first interface board and at least one second interface board through at least one first forwarding chip.
[0130] Each module of the above-mentioned network forwarding device can also be used to perform other actions in the above-mentioned method embodiment. All relevant contents of each step involved in the above-mentioned method embodiment can be referred to the functional description of the corresponding functional module and will not be repeated here.
[0131] Figure 11 1 is a schematic diagram of a network device structure provided in an embodiment of the present application. The network device 1100 may include one or more central processing units (CPU) 1101 and a memory 1105. The memory 1105 stores one or more application programs or data.
[0132] Memory 1105 may be volatile or persistent storage. The program stored in memory 1105 may include one or more modules, each of which may include a series of instruction operations on the network device. Furthermore, central processing unit 1101 may be configured to communicate with memory 1105 and execute the series of instruction operations in memory 1105 on network device 1100.
[0133] Among them, the central processing unit 1101 is used to execute the computer program in the memory 1105, so that the network device 1100 is used to execute: obtaining forwarding mode information, the forwarding mode information indicates the mode in which the network device processes forwarding data, and the forwarding mode indicated by the forwarding mode information includes a flexible forwarding mode; determining the forwarding mode according to the forwarding mode information; receiving at least one first forwarding data through at least one first interface board, and receiving at least one second forwarding data through at least one second interface board; in the flexible forwarding mode, transmitting at least one first forwarding data to at least one first forwarding chip, and transmitting at least one second forwarding data to at least one second forwarding chip; in the flexible forwarding mode, transmitting at least one first forwarding data to at least one first interface board and at least one second interface board through at least one first forwarding chip, and transmitting at least one second forwarding data to at least one first interface board and at least one second interface board through at least one second forwarding chip.
[0134] The network device 1100 may also include one or more power supplies 1102, one or more wired or wireless network interfaces 1103, one or more input and output interfaces 1104, and / or one or more operating systems, such as Windows Server™, Mac OS X™, Unix™, Linux™, FreeBSD™, etc.
[0135] The network device 1100 can execute the operations executed by the network devices in the aforementioned embodiments, and the details will not be repeated here.
[0136] Figure 12 1 is a schematic diagram of the structure of a network forwarding device provided in an embodiment of the present application. The network forwarding device 1200 may include one or more central processing units (CPU) 1201 and a memory 1205. The memory 1205 stores one or more applications or data.
[0137] Memory 1205 can be volatile or persistent storage. The program stored in memory 1205 can include one or more modules, each of which can include a series of instruction operations on the network forwarding device. Furthermore, the central processing unit 1201 can be configured to communicate with memory 1205 and execute the series of instruction operations in memory 1205 on the network forwarding device 1200.
[0138] Among them, the central processing unit 1201 is used to execute the computer program in the memory 1205, so that the network forwarding device 1200 is used to execute: obtaining forwarding mode information, the forwarding mode information indicates the mode of the first network forwarding device processing forwarding data, and the forwarding mode indicated by the forwarding mode information includes a flexible forwarding mode; determining the forwarding mode according to the forwarding mode information; receiving at least one first forwarding data through at least one first interface board; in the flexible forwarding mode, transmitting at least one first forwarding data to at least one first forwarding chip; in the flexible forwarding mode, transmitting at least one first forwarding data to at least one first interface board and at least one second interface board through at least one first forwarding chip, the second interface board is the interface board of the second forwarding device, and the network device includes a first forwarding device and a second forwarding device.
[0139] The network forwarding device 1200 may also include one or more power supplies 1202, one or more wired or wireless network interfaces 1203, one or more input and output interfaces 1204, and / or one or more operating systems, such as Windows Server™, Mac OS X™, Unix™, Linux™, FreeBSD™, etc.
[0140] The network forwarding device 1200 can execute the operations executed by the network forwarding device in the aforementioned embodiment, and the details will not be repeated here.
[0141] The embodiment of the present application also provides a computer program product containing instructions. The computer program product can be a software or program product containing instructions that can be run on a network device or stored in any available medium. When the computer program product is run on the plug-in result multiplexing device, the network device executes the aforementioned Figure 4 The data forwarding method implemented in the illustrated embodiment.
[0142] The embodiment of the present application also provides a computer program product containing instructions. The computer program product can be a software or program product containing instructions that can be run on a network forwarding device or stored in any available medium. When the computer program product is run on the plug-in result multiplexing device, the network forwarding device executes the aforementioned Figure 4 The data forwarding method implemented in the illustrated embodiment.
[0143] The embodiment of the present application also provides a computer program product including instructions. The computer program product may be a software or program product including instructions that can be run on a third device or stored in any available medium. When the computer program product is run on the plug-in result reuse device, the third device executes the aforementioned Figure 4 The data forwarding method implemented in the illustrated embodiment.
[0144] The embodiment of the present application also provides a computer-readable storage medium. The computer-readable storage medium can be any available medium that can be stored by the cache server or a data storage device such as a data center containing one or more available media. The available medium can be a magnetic medium (for example, a floppy disk, a hard disk, a tape), an optical medium (for example, a DVD), or a semiconductor medium (for example, a solid-state hard disk). The computer-readable storage medium includes instructions that instruct the network device to execute the aforementioned Figure 4 The data forwarding method implemented in the illustrated embodiment.
[0145] The embodiment of the present application also provides a computer-readable storage medium. The computer-readable storage medium can be any available medium that can be stored by the cache server or a data storage device such as a data center containing one or more available media. The available medium can be a magnetic medium (for example, a floppy disk, a hard disk, a tape), an optical medium (for example, a DVD), or a semiconductor medium (for example, a solid-state hard disk). The computer-readable storage medium includes instructions that instruct the network forwarding device to execute the aforementioned Figure 4 The data forwarding method implemented in the illustrated embodiment.
[0146] The embodiment of the present application also provides a computer-readable storage medium. The computer-readable storage medium can be any available medium that can be stored by the cache server or a data storage device such as a data center containing one or more available media. The available medium can be a magnetic medium (for example, a floppy disk, a hard disk, a tape), an optical medium (for example, a DVD), or a semiconductor medium (for example, a solid-state hard disk). The computer-readable storage medium includes instructions that instruct the third device to execute the aforementioned Figure 4 The data forwarding method implemented in the illustrated embodiment.
[0147] In the above embodiments, it can be implemented in whole or in part by software, hardware, firmware or any combination thereof. When implemented using a software program, it can be implemented in whole or in part in the form of a computer program product. The computer program product includes one or more computer instructions. When the computer program instructions are loaded and executed on a computer, all or part of the processes (or functions) of the embodiments of the present application are implemented. The computer can be a general-purpose computer, a special-purpose computer, a computer network, or other programmable devices. The computer instructions can be stored in a computer-readable storage medium or transmitted from one computer-readable storage medium to another computer-readable storage medium. For example, the computer instructions can be transmitted from a website, computer, server or data center to another website, computer, server or data center by wired (e.g., coaxial cable, optical fiber, digital subscriber line (DSL)) or wireless (e.g., infrared, wireless, microwave, etc.) means. The computer-readable storage medium can be any available medium that a computer can access or a data storage device such as a server or data center that contains one or more media that can be integrated. Available media may be magnetic media (eg, floppy disk, hard disk, tape), optical media (eg, DVD), or semiconductor media (eg, solid state disk (SSD)), etc. In the embodiment of the present application, the computer may include the aforementioned device.
[0148] Although the present application is described herein in conjunction with various embodiments, in the process of implementing the claimed application, those skilled in the art may understand and implement other variations of the disclosed embodiments by reviewing the drawings, the disclosure, and the appended claims. In the claims, the word "comprising" does not exclude other components or steps, and "a" or "an" does not exclude multiple situations. A single processor or other unit may implement several functions listed in the claims. Certain measures are recorded in different dependent claims, but this does not mean that these measures cannot be combined to produce good results.
Claims
1. A data forwarding method, characterized in that: Applied to a network device, the network device includes a first network forwarding device and a second network forwarding device, the first network forwarding device includes at least one first forwarding chip and at least one first interface board, the second network forwarding device includes at least one second forwarding chip and at least one second interface board, the method includes: Acquire forwarding mode information, where the forwarding mode information indicates a mode in which the network device processes forwarded data, and the forwarding mode indicated by the forwarding mode information includes a flexible forwarding mode; determining a forwarding mode according to the forwarding mode information; receiving at least one first forwarding data through the at least one first interface board, and receiving at least one second forwarding data through the at least one second interface board; In the flexible forwarding mode, the at least one first forwarding data is transmitted to the at least one first forwarding chip, and the at least one second forwarding data is transmitted to the at least one second forwarding chip; In the flexible forwarding mode, the at least one first forwarding data is transmitted to the at least one first interface board and the at least one second interface board through the at least one first forwarding chip, and the at least one second forwarding data is transmitted to the at least one first interface board and the at least one second interface board through the at least one second forwarding chip.
2. The method according to claim 1, characterized in that When the forwarding mode information is a fault forwarding mode and the at least one second forwarding chip is faulty, the method further includes: receiving at least one first forwarding data through the at least one first interface board, and receiving at least one second forwarding data through the at least one second interface board; transmitting the at least one first forwarding data and the at least one second forwarding data to the at least one first forwarding chip; The at least one first forwarding data and the at least one second forwarding data are transmitted to the at least one first interface board and the at least one second interface board through the at least one first forwarding chip.
3. The method according to claim 1, characterized in that The forwarding mode information is a standard forwarding mode, and the standard forwarding mode instructs the first forwarding chip to process forwarded data and the second forwarding chip to serve as a backup. The method further includes: receiving at least one first forwarding data through the at least one first interface board, and receiving at least one second forwarding data through the at least one second interface board; transmitting the at least one first forwarding data and the at least one second forwarding data to the at least one first forwarding chip; The at least one first forwarding data and the at least one second forwarding data are transmitted to the at least one first interface board and the at least one second interface board through the at least one first forwarding chip.
4. The method according to any one of claims 1 to 3, characterized in that The first network forwarding device includes a first processor, the second network forwarding device includes a second processor, and acquiring the forwarding mode information includes: acquiring, by a first processor of the first network forwarding device, first forwarding mode information indicating a mode in which the first network forwarding device processes forwarded data; Second forwarding mode information is acquired through a second processor of the second network forwarding device, where the second forwarding mode information indicates a mode in which the second network forwarding device processes forwarded data.
5. A data forwarding method, characterized in that: Applied to a first network forwarding device, the first network forwarding device including at least one first forwarding chip and at least one first interface board, the method includes: Acquire forwarding mode information, where the forwarding mode information indicates a mode in which the first network forwarding device processes forwarded data, and the forwarding mode indicated by the forwarding mode information includes a flexible forwarding mode; determining a forwarding mode according to the forwarding mode information; receiving at least one first forwarding data through the at least one first interface board; In the flexible forwarding mode, transmitting the at least one first forwarding data to the at least one first forwarding chip; In the flexible forwarding mode, the at least one first forwarding data is transmitted to the at least one first interface board and the at least one second interface board through the at least one first forwarding chip, the second interface board is the interface board of the second forwarding device, and the network equipment includes the first forwarding device and the second forwarding device.
6. The method according to claim 5, characterized in that When the forwarding mode information is a fault forwarding mode and the at least one second forwarding chip fails, the above method also includes: receiving at least one first forwarding data through the at least one first interface board; receiving the at least one second forwarding data through the first forwarding chip; transmitting the at least one first forwarding data to the at least one first forwarding chip; transmitting the at least one first forwarding data and the at least one second forwarding data to the at least one first interface board and the at least one second interface board through the at least one first forwarding chip.
7. The method according to claim 5, characterized in that The forwarding mode information is a standard forwarding mode, and the standard forwarding mode instructs the first forwarding chip to process forwarded data and the second forwarding chip to serve as a backup. The method further includes: receiving at least one first forwarding data through the at least one first interface board; receiving at least one second forwarding data through the first forwarding chip; transmitting the at least one first forwarding data and the at least one second forwarding data to the at least one first forwarding chip; In the standard forwarding mode, the at least one first forwarding data and the at least one second forwarding data are transmitted to the at least one first interface board and the at least one second interface board through the at least one first forwarding chip.
8. The method according to any one of claims 5 to 7, characterized in that: The first network forwarding device includes a first processor, and the acquiring of the forwarding mode information includes: First forwarding mode information is acquired through a first processor of the first network forwarding device, where the first forwarding mode information indicates a mode in which the first network forwarding device processes forwarded data.
9. A network device, characterized in that: The network device includes a first network forwarding device and a second network forwarding device, the first network forwarding device includes a first processor, at least one first forwarding chip and at least one first interface board, and the second network forwarding device includes a second processor, at least one second forwarding chip and at least one second interface board, wherein: The first processor and the second processor are configured to obtain forwarding mode information, where the forwarding mode information indicates a mode in which the network device processes forwarded data, and the forwarding mode indicated by the forwarding mode information includes a flexible forwarding mode; The first processor and the second processor are further configured to determine a forwarding mode according to the forwarding mode information; The at least one first interface board is configured to receive at least one first forwarding data and transmit the data to the at least one first forwarding chip in a flexible forwarding mode; The at least one second interface board is configured to receive at least one second forwarding data and transmit the data to the at least one second forwarding chip in a flexible forwarding mode; The at least one first forwarding chip is configured to transmit the at least one first forwarding data to the at least one first interface board and the at least one second interface board in a flexible forwarding mode, The at least one second forwarding chip is configured to transmit the at least one second forwarding data to the at least one first interface board and the at least one second interface board in a flexible forwarding mode.
10. The network device according to claim 9, characterized in that The forwarding mode information is a fault forwarding mode, and when the at least one second forwarding chip fails, The at least one first interface board is configured to receive at least one first forwarding data and transmit the data to the at least one first forwarding chip; The at least one second interface board is configured to receive at least one second forwarding data and transmit the data to the at least one first forwarding chip; The at least one first forwarding chip is configured to transmit the at least one first forwarding data and the at least one second forwarding data to the at least one first interface board and the at least one second interface board.
11. The network device according to claim 9, wherein: The forwarding mode information further includes a standard forwarding mode, and the standard forwarding mode indicates that the first forwarding chip processes the forwarded data and the second forwarding chip serves as a backup. The method further includes: The at least one first interface board is configured to receive at least one first forwarding data and transmit the data to the at least one first forwarding chip; The at least one second interface board is configured to receive at least one second forwarding data and transmit the data to the at least one first forwarding chip; The at least one first forwarding chip is configured to transmit the at least one first forwarding data and the at least one second forwarding data to the at least one first interface board and the at least one second interface board.
12. A network device, characterized in that: The network equipment includes: an acquisition module, configured to acquire forwarding mode information, wherein the forwarding mode information indicates a mode in which the network device processes forwarded data, and the forwarding mode indicated by the forwarding mode information includes a flexible forwarding mode; a determination module, configured to determine a forwarding mode according to the forwarding mode information; a receiving module, configured to receive at least one first forwarding data through the at least one first interface board, and receive at least one second forwarding data through the at least one second interface board; a first transmission module, configured to transmit the at least one first forwarding data to the at least one first forwarding chip, and transmit the at least one second forwarding data to the at least one second forwarding chip in a flexible forwarding mode; The second transmission module is used to transmit the at least one first forwarding data to the at least one first interface board and the at least one second interface board through the at least one first forwarding chip in a flexible forwarding mode, and to transmit the at least one second forwarding data to the at least one first interface board and the at least one second interface board through the at least one second forwarding chip.
13. The network device according to claim 12, wherein: The forwarding mode information is a fault forwarding mode, and when the at least one second forwarding chip fails, The receiving module is specifically configured to receive at least one first forwarding data through the at least one first interface board, and receive at least one second forwarding data through the at least one second interface board; The first transmission module is specifically configured to transmit the at least one first forwarding data and the at least one second forwarding data to the at least one first forwarding chip; The second transmission module is specifically configured to transmit the at least one first forwarding data and the at least one second forwarding data to the at least one first interface board and the at least one second interface board through the at least one first forwarding chip.
14. The network device according to claim 12, wherein: The forwarding mode information is a standard forwarding mode, and the standard forwarding mode instructs the first forwarding chip to process forwarded data and the second forwarding chip to serve as a backup. The method further includes: The receiving module is specifically configured to receive at least one first forwarding data through the at least one first interface board, and receive at least one second forwarding data through the at least one second interface board; The first transmission module is specifically configured to transmit the at least one first forwarding data and the at least one second forwarding data to the at least one first forwarding chip; The second transmission module is specifically configured to transmit the at least one first forwarding data and the at least one second forwarding data to the at least one first interface board and the at least one second interface board through the at least one first forwarding chip.
15. A network device, characterized in that: The network device includes a processor and a memory; the processor is coupled to the memory; the memory is used to store computer instructions, and the computer instructions are loaded and executed by the processor to enable the network device to implement the method according to any one of claims 1 to 4.
16. A network forwarding device, characterized in that: The network forwarding device includes a processor and a memory; the processor is coupled to the memory; the memory is used to store computer instructions, and the computer instructions are loaded and executed by the processor to enable the network forwarding device to implement the method according to any one of claims 5-8.
17. A computer-readable storage medium, characterized in that The computer-readable storage medium stores at least one computer program instruction, and the computer program instruction is loaded and executed by a processor to implement the method according to any one of claims 1 to 4.
18. A computer-readable storage medium, characterized in that The computer-readable storage medium stores at least one computer program instruction, and the computer program instruction is loaded and executed by a processor to implement the method according to any one of claims 5 to 8.
19. A computer program product, characterized in that The computer program product comprises computer-executable instructions. When the computer-executable instructions are executed on a computer, the computer is configured to implement the method according to any one of claims 1 to 4.
20. A computer program product, characterized in that The computer program product comprises computer-executable instructions. When the computer-executable instructions are executed on a computer, the computer is configured to implement the method according to any one of claims 5 to 8.