Traffic forwarding method and device and related equipment
By determining the target path and target outgoing interface in the Spine-Leaf network and setting the target source port value, the problems of load imbalance and network congestion in the intelligent computing data center are solved, and more balanced traffic forwarding and effective utilization of resources are achieved.
Patent Information
- Application Number
- CN202411888265.X
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-19
- Publication Date
- 2025-04-15
- Estimated Expiration
- 2044-12-19
AI Technical Summary
In the Spine-Leaf network of smart computing data center, the switches perform hash routing forwarding based on factors such as five-tuple traffic, resulting in load imbalance and network congestion.
The controller determines the target path and target outbound interface of the task to be trained in the Spine-Leaf network, and sends information requesting the target source port value to the target Leaf. The target Leaf calculates and feedbacks the target source port value. The source server sets the message source port as the target source port value, and the target Leaf hash forwarding based on this.
It realizes more balanced traffic forwarding in the Spine-Leaf network, reduces the ACL resource usage on Leaf switches and reduces the risk of network congestion.
Smart Images

Figure CN119835219A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the technical field of intelligent computing centers, and in particular to a traffic forwarding method, device and related equipment. Background Art
[0002] In the intelligent computing data center network, the upstream and downstream bandwidth is 1:1, and there will be many equal-cost routing (ECMP, Equal-Cost Multi-Path routing) links in the network. In the case of flow-by-flow forwarding, the switch will perform hash routing forwarding based on the five-tuple of the traffic and other calculation factors to achieve load balancing in the network. The traffic from multiple entrances is hashed ECMP to the same exit. There is no traffic on other exits, resulting in unbalanced load sharing and network congestion. In other words, in the intelligent computing data center network, the switch equipment hashes or loads unevenly, resulting in network traffic congestion that cannot be solved. Summary of the invention
[0003] The present application provides a traffic forwarding method, device and related equipment.
[0004] In a first aspect, the present application provides a traffic forwarding method, which is applied to a controller in a Spine-Leaf network, and the method includes:
[0005] Based on the source destination address of the task to be trained, determine the target path for transmitting the traffic of the task to be trained, and based on the target path, determine the target outbound interface for forwarding the traffic of the task to be trained on the target Leaf accessed by the source server;
[0006] Sending information requesting a target source port value to the target Leaf, wherein after receiving the information, the target Leaf calculates a corresponding target source port value based on the source destination address of the task to be trained and the target outbound interface, and feeds the target source port value back to the controller;
[0007] Receive the target source port value fed back by the target Leaf, and instruct the source server to set the message source port of the traffic of the task to be trained to the target source port value when executing the task to be trained, wherein the target Leaf hashes the traffic of the task to be trained to the target outbound interface for forwarding based on the source destination address of the traffic of the task to be trained and the target source port value.
[0008] Optionally, based on the source destination address of the task to be trained, the step of determining a target path for transmitting the traffic of the task to be trained includes:
[0009] Obtain the network topology information of the entire network, the host ARP information, and the mapping relationship between each ingress port included in each port group constructed on the Spine device and each equal-cost route included in each equal-cost route group, wherein the network topology information of the entire network includes each link relationship and the ingress and egress interface information included in each link;
[0010] Defining an initial cost value of each link included in the network topology information of the entire network, wherein the size of the initial cost value of a link is inversely proportional to the maximum bandwidth value of the link;
[0011] According to the source and destination information of the task to be trained, the host ARP information, the mapping relationship between each input port included in each port group constructed on each Spine device and each equivalent-cost route included in each equivalent-cost route group, and the cost value of each link included in the network topology information of the entire network, determine the target path for transmitting the traffic of the task to be trained, wherein the sum of the cost values of each target link included in the target path is less than or equal to a preset value.
[0012] In a second aspect, the present application provides a traffic forwarding method, which is applied to a source server, and the method includes:
[0013] Receive an instruction sent by a controller to set the message source port of the task to be trained to a target source port value, wherein the controller determines a target path for transmitting the traffic of the task to be trained based on the source destination address of the task to be trained, and determines a target outbound interface for forwarding the traffic of the task to be trained on the target Leaf to which the source server is connected based on the target path, and then sends information requesting the target source port value to the target Leaf. After receiving the information, the target Leaf calculates the corresponding target source port value based on the source destination address of the task to be trained and the target outbound interface, and feeds the target source port value back to the controller;
[0014] The task traffic to be trained whose message source port is the target source port value is sent to the target Leaf, so that the target Leaf hashes the task traffic to be trained to the target outbound interface for forwarding based on the source destination address of the task traffic to be trained and the target source port value.
[0015] Optionally, an agent program is installed on the source server, and the agent program receives an instruction sent by the controller to set the message source port of the task to be trained to the target source port value, and when determining to start the task to be trained, sets the message source port of the task to be trained traffic to the target source port value, and sends the task to be trained traffic with the message source port as the target source port value to the target Leaf.
[0016] In a third aspect, the present application provides a traffic forwarding device, which is applied to a controller in a Spine-Leaf network, and the device includes:
[0017] A determination unit, configured to determine a target path for transmitting the traffic of the task to be trained based on the source destination address of the task to be trained, and determine a target outbound interface for forwarding the traffic of the task to be trained on a target Leaf accessed by the source server based on the target path;
[0018] A sending unit, configured to send information requesting a target source port value to the target Leaf, wherein after receiving the information, the target Leaf calculates a corresponding target source port value based on the source destination address of the task to be trained and the target outbound interface, and feeds the target source port value back to the controller;
[0019] A receiving unit is used to receive the target source port value fed back by the target Leaf, and instruct the source server to set the message source port of the traffic of the task to be trained to the target source port value when executing the task to be trained, wherein the target Leaf hashes the traffic of the task to be trained to the target outbound interface for forwarding based on the source destination address of the traffic of the task to be trained and the target source port value.
[0020] Optionally, when determining a target path for transmitting traffic of the task to be trained based on the source destination address of the task to be trained, the determining unit is specifically configured to:
[0021] Obtain the network topology information of the entire network, the host ARP information, and the mapping relationship between each ingress port included in each port group constructed on the Spine device and each equal-cost route included in each equal-cost route group, wherein the network topology information of the entire network includes each link relationship and the ingress and egress interface information included in each link;
[0022] Defining an initial cost value of each link included in the network topology information of the entire network, wherein the size of the initial cost value of a link is inversely proportional to the maximum bandwidth value of the link;
[0023] According to the source and destination information of the task to be trained, the host ARP information, the mapping relationship between each input port included in each port group constructed on each Spine device and each equivalent-cost route included in each equivalent-cost route group, and the cost value of each link included in the network topology information of the entire network, determine the target path for transmitting the traffic of the task to be trained, wherein the sum of the cost values of each target link included in the target path is less than or equal to a preset value.
[0024] In a fourth aspect, the present application provides a traffic forwarding device, which is applied to a source server, and the device includes:
[0025] A receiving unit, configured to receive an instruction sent by a controller to set a message source port of a task to be trained to a target source port value, wherein the controller determines a target path for transmitting the traffic of the task to be trained based on the source destination address of the task to be trained, and determines a target outbound interface for forwarding the traffic of the task to be trained on a target Leaf to which the source server is connected based on the target path, and then sends information requesting a target source port value to the target Leaf. After receiving the information, the target Leaf calculates a corresponding target source port value based on the source destination address of the task to be trained and the target outbound interface, and feeds the target source port value back to the controller;
[0026] A sending unit is used to send the task traffic to be trained whose source port is the target source port value to the target Leaf, so that the target Leaf hashes the task traffic to be trained to the target outbound interface for forwarding based on the source destination address of the task traffic to be trained and the target source port value.
[0027] Optionally, an agent program is installed on the source server, and the agent program receives an instruction sent by the controller to set the message source port of the task to be trained to the target source port value, and when determining to start the task to be trained, sets the message source port of the task to be trained traffic to the target source port value, and sends the task to be trained traffic with the message source port as the target source port value to the target Leaf.
[0028] In a fifth aspect, an embodiment of the present application provides a traffic forwarding device, the traffic forwarding device comprising:
[0029] A memory for storing program instructions;
[0030] The processor is used to call the program instructions stored in the memory, and execute the steps of the method as described in any one of the first aspects above according to the obtained program instructions.
[0031] In a sixth aspect, an embodiment of the present application further provides a computer-readable storage medium, wherein the computer-readable storage medium stores computer-executable instructions, and the computer-executable instructions are used to enable the computer to execute the steps of the method described in any one of the above-mentioned first aspects.
[0032] In a seventh aspect, an embodiment of the present application provides a traffic forwarding device, the traffic forwarding device comprising:
[0033] A memory for storing program instructions;
[0034] The processor is used to call the program instructions stored in the memory and execute the steps of the method as described in any one of the second aspects according to the obtained program instructions.
[0035] In an eighth aspect, an embodiment of the present application further provides a computer-readable storage medium, wherein the computer-readable storage medium stores computer-executable instructions, and the computer-executable instructions are used to enable the computer to execute the steps of the method described in any one of the second aspects above.
[0036] In summary, the traffic forwarding method provided in the embodiment of the present application is applied to the controller in the Spine-Leaf network, and the method includes: based on the source and destination addresses of the task to be trained, determining the target path for transmitting the traffic of the task to be trained, and based on the target path, determining the target output interface for forwarding the traffic of the task to be trained on the target Leaf to which the source server is connected; sending information requesting the target source port value to the target Leaf, wherein after receiving the information, the target Leaf calculates the corresponding target source port value based on the source and destination addresses of the task to be trained and the target output interface, and feeds back the target source port value to the controller; receiving the target source port value fed back by the target Leaf, and instructing the source server to set the message source port of the traffic of the task to be trained to the target source port value when executing the task to be trained, wherein the target Leaf hashes the traffic of the task to be trained to the target output interface for forwarding based on the source and destination addresses of the traffic of the task to be trained and the target source port value.
[0037] By adopting the traffic forwarding method provided in the embodiment of the present application, the controller calculates the source destination service and the egress port information, requests the source port that meets the forwarding requirements from the Leaf switch, and completes the adjustment of the end-side service source port through the source server to complete the end-side tuning, thereby reducing the existing solution for network device tuning. The need to send traffic matrix to the Leaf switch occupies a large amount of ACL resources, resulting in a large consumption of Leaf switch resources. BRIEF DESCRIPTION OF THE DRAWINGS
[0038] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments of the present application or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only some embodiments recorded in this application. For ordinary technicians in this field, other drawings can also be obtained based on these drawings of the embodiments of the present application.
[0039] Figure 1 A schematic diagram of a traffic forwarding process provided for related technologies;
[0040] Figure 2 A detailed flow chart of a traffic forwarding method provided in an embodiment of the present application;
[0041] Figure 3 A detailed flow chart of another traffic forwarding method provided in an embodiment of the present application;
[0042] Figure 4 A schematic diagram of the structure of a traffic forwarding device provided in an embodiment of the present application;
[0043] Figure 5 A schematic diagram of the structure of another traffic forwarding device provided in an embodiment of the present application;
[0044] Figure 6 A schematic diagram of the hardware architecture of a traffic forwarding device provided in an embodiment of the present application;
[0045] Figure 7 A schematic diagram of the hardware architecture of another traffic forwarding device provided in an embodiment of the present application. DETAILED DESCRIPTION
[0046] The terms used in the embodiments of the present application are only for the purpose of describing specific embodiments, rather than limiting the present application. The singular forms of "a", "said" and "the" used in the present application and claims are also intended to include plural forms, unless the context clearly indicates other meanings. It should also be understood that the term "and / or" used herein refers to any or all possible combinations of one or more associated listed items.
[0047] It should be understood that, although the terms first, second, third, etc. may be used to describe various information in the embodiments of the present application, these information should not be limited to these terms. These terms are only used to distinguish the same type of information from each other. For example, without departing from the scope of the present application, the first information may also be referred to as the second information, and similarly, the second information may also be referred to as the first information. Depending on the context, in addition, the word "if" used may be interpreted as "at..." or "when..." or "in response to determination".
[0048] In the related solution, the mapping relationship between the inbound port and the outbound port of the equal-cost routing group is completed by sending the inbound port LBN rail group configuration up and down on the spine device. The controller can clearly know the mapping relationship between each inbound port and outbound port through the implementation principle of LBN, and then the controller selects the shortest path based on this mapping relationship and cost value, and sends the traffic matrix configuration down to the leaf side.
[0049] For example, see Figure 1As shown in the figure, it is a schematic diagram of a traffic forwarding process provided by the related technology. When the controller selects a route, it will select the forwarding path with the smallest total cost value in combination with the cost value selection rule, store it in the controller memory, and modify the link cost value information at the same time to trigger the distribution of leaf device configuration. For example, Figure 1 The green or blue path in the traffic matrix is sent to the leaf device for traffic diversion, and the spine device performs natural forwarding according to the LBN mapping relationship. In this way, the controller can complete path navigation and routing according to the service source and destination. The spine device does not need to send traffic matrix to the spine device, saving the ACL resources of the spine device. And reduce the configuration interaction between the controller and the spine device during the routing process. However, a large amount of traffic matrix configuration still needs to be sent to the leaf device. The related solution requires a large amount of ACL resources to send traffic matrix on the leaf device, and the switch resource consumption is large.
[0050] For example, see Figure 2 , which is a detailed flow chart of a traffic forwarding method provided in an embodiment of the present application, the method is applied to a controller, and the method includes the following steps:
[0051] Step 200: Based on the source destination address of the task to be trained, determine the target path for transmitting the traffic of the task to be trained, and based on the target path, determine the target outbound interface on the target Leaf accessed by the source server for forwarding the traffic of the task to be trained.
[0052] When determining a target path for transmitting the traffic of the task to be trained based on the source and destination addresses of the task to be trained, a preferred implementation method is:
[0053] Obtain the network topology information of the entire network, the host ARP information, and the mapping relationship between each ingress port included in each port group constructed on the Spine device and each equal-cost route included in each equal-cost route group, wherein the network topology information of the entire network includes each link relationship and the ingress and egress interface information included in each link;
[0054] Defining an initial cost value of each link included in the network topology information of the entire network, wherein the size of the initial cost value of a link is inversely proportional to the maximum bandwidth value of the link;
[0055] According to the source and destination information of the task to be trained, the host ARP information, the mapping relationship between each input port included in each port group constructed on each Spine device and each equivalent-cost route included in each equivalent-cost route group, and the cost value of each link included in the network topology information of the entire network, determine the target path for transmitting the traffic of the task to be trained, wherein the sum of the cost values of each target link included in the target path is less than or equal to a preset value.
[0056] That is, determine the best path for forwarding the task to be trained, the target path with the smallest cost value, and further, determine the target outbound interface on the Leaf connected to the source server for forwarding the traffic of the task to be trained based on the determined target path. The target outbound interface is the outbound interface connected to the Spine device. In actual applications, when forwarding each flow, the Leaf device performs hash processing based on the source and destination address information of the flow and the source port information of the message, and hashes it to a certain outbound interface for forwarding. The hash result is associated with the value of the source port of the message.
[0057] Step 210: Send information requesting a target source port value to the target Leaf.
[0058] After receiving the information, the target Leaf calculates the corresponding target source port value based on the source destination address of the task to be trained and the target outbound interface, and feeds the target source port value back to the controller.
[0059] In an embodiment of the present application, after determining the target outbound interface for forwarding the traffic of the task to be trained on the target Leaf to which the source server is connected, the controller requests one or more source port values from the target Leaf, that is, sends an indication carrying the target outbound interface information to the target Leaf, instructing the target Leaf to calculate the corresponding source port value (target source port value) based on the source destination address and the target outbound interface of the task to be trained, and feeds back the target source port value to the controller.
[0060] Step 220: Receive the target source port value fed back by the target Leaf, and instruct the source server to set the message source port of the traffic of the task to be trained to the target source port value when executing the task to be trained.
[0061] Among them, the target Leaf hashes the task traffic to be trained to the target outbound interface for forwarding based on the source destination address of the task traffic to be trained and the target source port value.
[0062] In an embodiment of the present application, the target source port value is associated with a hash rule, and the target source port value corresponds to the target output interface. That is, when the target Leaf performs hash forwarding on traffic whose source destination address is the source destination address of the task to be trained, if the source port value of the traffic message is the target source port value, the stray message is hashed to the target output interface for forwarding.
[0063] That is, there is no need to send the forwarding flow table to the Leaf device. The training task traffic can be forwarded directly based on the original forwarding mechanism of the Leaf device. The source port value of the training task traffic is solidified at the source server so that when the Leaf device forwards the training task traffic, it determines a fixed outbound interface based on the training task traffic. The source port value of the training task traffic is calculated based on the determined Leaf forwarding outbound interface. In this way, each training task traffic can be specified to be forwarded through a fixed outbound interface.
[0064] For example, see Figure 3 , which is a detailed flow chart of a traffic forwarding method provided in an embodiment of the present application, the method is applied to a source server, and the method includes the following steps:
[0065] Step 300: Receive an instruction from a controller to set the message source port of the task to be trained to the target source port value.
[0066] Among them, the controller determines the target path for transmitting the traffic of the task to be trained based on the source and destination addresses of the task to be trained, and determines the target outbound interface for forwarding the traffic of the task to be trained on the target Leaf to which the source server is connected based on the target path, and then sends information requesting the target source port value to the target Leaf. After receiving the information, the target Leaf calculates the corresponding target source port value based on the source and destination addresses of the task to be trained and the target outbound interface, and feeds the target source port value back to the controller.
[0067] In an embodiment of the present application, a preferred implementation method is that an agent program is installed on the source server, and the agent program receives an instruction sent by the controller to set the message source port of the task to be trained to the target source port value.
[0068] Step 310: Send the task traffic to be trained whose message source port is the target source port value to the target Leaf, so that the target Leaf hashes the task traffic to be trained to the target outbound interface for forwarding based on the source destination address of the task traffic to be trained and the target source port value.
[0069] Specifically, before the task to be trained begins, based on the source and destination information of the task to be trained, the best path (i.e., the target path) in the network for transmitting the task to be trained is determined. Then, the controller determines the target outbound interface on the Leaf device connected to the source end on the target path for forwarding the traffic of the task to be trained, and instructs the Leaf device to generate the corresponding target source port information based on the target outbound interface. The controller synchronizes the target source port information to the source end. When executing the task to be trained, the source end sets the message source port information of the traffic of the task to be trained to the target source port and sends it to the Leaf device. The Leaf device performs hash forwarding based on the target source port value, and finally hashes to the target outbound interface of the Leaf device for forwarding.
[0070] The traffic forwarding process provided in the embodiment of the present application is described in detail below in conjunction with specific application scenarios.
[0071] 1) The controller calculates the shortest path cost value based on the source IP and destination IP of the task to be trained reported by the source server (e.g., the agent installed on the source node) and writes it into the memory.
[0072] 2) The controller determines the source IP, destination IP, and the source Leaf outbound interface of the calculated shortest path, and requests a source port (value) from the source Leaf switch (to which the source Leaf switch server is connected).
[0073] 3) The source Leaf switch calculates the corresponding source port (UDP source port value) based on the source IP, destination IP, and outbound interface information, and returns the result (source port value) to the controller.
[0074] 4) The controller instructs the source server to modify the message source port value of the task traffic to be trained based on the received information (source port value);
[0075] 4) After the communication library is initialized, the training task starts. The training task traffic message carries the source port information of the execution to ensure that the forwarding path of the source Leaf switch meets expectations (forwarding from the source Leaf outbound interface).
[0076] 5) After the task training is completed, the source server notifies the controller to delete the routing information and wait for the next task to start. The above process is repeated to complete the dynamic scheduling of each job task.
[0077] For example, see Figure 4 FIG. 1 is a schematic diagram of a structure of a traffic forwarding device provided in an embodiment of the present application, wherein the device is applied to a controller in a Spine-Leaf network, and the device includes:
[0078] The determination unit 40 is used to determine a target path for transmitting the traffic of the task to be trained based on the source destination address of the task to be trained, and determine a target outbound interface for forwarding the traffic of the task to be trained on the target Leaf accessed by the source server based on the target path;
[0079] A sending unit 41 is used to send information requesting a target source port value to the target Leaf, wherein after receiving the information, the target Leaf calculates a corresponding target source port value based on the source destination address of the task to be trained and the target outbound interface, and feeds the target source port value back to the controller;
[0080] The receiving unit 41 is used to receive the target source port value fed back by the target Leaf, and instruct the source server to set the message source port of the traffic of the task to be trained to the target source port value when executing the task to be trained, wherein the target Leaf hashes the traffic of the task to be trained to the target output interface for forwarding based on the source destination address of the traffic of the task to be trained and the target source port value.
[0081] Optionally, when determining a target path for transmitting traffic of the task to be trained based on the source destination address of the task to be trained, the determining unit 40 is specifically configured to:
[0082] Obtain the network topology information of the entire network, the host ARP information, and the mapping relationship between each ingress port included in each port group constructed on the Spine device and each equal-cost route included in each equal-cost route group, wherein the network topology information of the entire network includes each link relationship and the ingress and egress interface information included in each link;
[0083] Defining an initial cost value of each link included in the network topology information of the entire network, wherein the size of the initial cost value of a link is inversely proportional to the maximum bandwidth value of the link;
[0084] According to the source and destination information of the task to be trained, the host ARP information, the mapping relationship between each input port included in each port group constructed on each Spine device and each equivalent-cost route included in each equivalent-cost route group, and the cost value of each link included in the network topology information of the entire network, determine the target path for transmitting the traffic of the task to be trained, wherein the sum of the cost values of each target link included in the target path is less than or equal to a preset value.
[0085] For example, see Figure 5 FIG. 1 is a schematic diagram of a structure of a traffic forwarding device provided in an embodiment of the present application. The device is applied to a source server, and the device includes:
[0086] A receiving unit 50 is used to receive an instruction sent by the controller to set the message source port of the task to be trained to the target source port value, wherein the controller determines the target path for transmitting the traffic of the task to be trained based on the source destination address of the task to be trained, and determines the target outbound interface for forwarding the traffic of the task to be trained on the target Leaf accessed by the source server based on the target path, and then sends information requesting the target source port value to the target Leaf. After receiving the information, the target Leaf calculates the corresponding target source port value based on the source destination address of the task to be trained and the target outbound interface, and feeds the target source port value back to the controller;
[0087] The sending unit 51 is used to send the task traffic to be trained whose source port is the target source port value to the target Leaf, so that the target Leaf hashes the task traffic to be trained to the target outbound interface for forwarding based on the source destination address of the task traffic to be trained and the target source port value.
[0088] Optionally, an agent program is installed on the source server, and the agent program receives an instruction sent by the controller to set the message source port of the task to be trained to the target source port value, and when determining to start the task to be trained, sets the message source port of the task to be trained traffic to the target source port value, and sends the task to be trained traffic with the message source port as the target source port value to the target Leaf.
[0089] The above units may be one or more integrated circuits configured to implement the above methods, such as one or more application specific integrated circuits (ASIC), or one or more digital signal processors (DSP), or one or more field programmable gate arrays (FPGA). For another example, when a certain unit is implemented in the form of a processing element scheduling program code, the processing element may be a general-purpose processor, such as a central processing unit (CPU) or other processor that can call program code. For another example, these units may be integrated together and implemented in the form of a system-on-a-chip (SOC).
[0090] Furthermore, the traffic forwarding device provided in the embodiment of the present application, from the hardware level, the hardware architecture diagram of the traffic forwarding device can be seen in Figure 6As shown, the traffic forwarding device may include: a memory 60 and a processor 61,
[0091] The memory 60 is used to store program instructions; the processor 61 calls the program instructions stored in the memory 60 and executes the above method embodiment applied to the controller according to the obtained program instructions. The specific implementation method and technical effect are similar and will not be repeated here.
[0092] Optionally, the present application also provides a controller, comprising at least one processing element (or chip) for executing the above method embodiment applied to the controller.
[0093] Optionally, the present application also provides a program product, such as a computer-readable storage medium, which stores computer-executable instructions, and the computer-executable instructions are used to enable the computer to execute the above-mentioned method embodiment applied to the controller.
[0094] Furthermore, the traffic forwarding device provided in the embodiment of the present application, from the hardware level, the hardware architecture diagram of the traffic forwarding device can be seen in Figure 7 As shown, the traffic forwarding device may include: a memory 70 and a processor 71,
[0095] The memory 70 is used to store program instructions; the processor 71 calls the program instructions stored in the memory 70 and executes the above method embodiment applied to the controller according to the obtained program instructions. The specific implementation method and technical effect are similar and will not be repeated here.
[0096] Optionally, the present application also provides a server, comprising at least one processing element (or chip) for executing the above method embodiment applied to the server.
[0097] Optionally, the present application also provides a program product, such as a computer-readable storage medium, which stores computer-executable instructions, and the computer-executable instructions are used to enable the computer to execute the above-mentioned method embodiment applied to the server.
[0098] Here, the machine-readable storage medium may be any electronic, magnetic, optical or other physical storage device that may contain or store information, such as executable instructions, data, etc. For example, the machine-readable storage medium may be: RAM (RadomAccess Memory), volatile memory, non-volatile memory, flash memory, storage drive (such as hard disk drive), solid state drive, any type of storage disk (such as CD, DVD, etc.), or similar storage medium, or a combination thereof.
[0099] The systems, devices, modules or units described in the above embodiments may be implemented by computer chips or entities, or by products with certain functions. A typical implementation device is a computer, which may be in the form of a personal computer, a laptop computer, a cellular phone, a camera phone, a smart phone, a personal digital assistant, a media player, a navigation device, an email transceiver, a game console, a tablet computer, a wearable device or a combination of any of these devices.
[0100] For the convenience of description, the above device is described in various units according to their functions. Of course, when implementing the present application, the functions of each unit can be implemented in the same or multiple software and / or hardware.
[0101] Those skilled in the art will appreciate that the embodiments of the present application may be provided as methods, systems, or computer program products. Therefore, the present application may adopt the form of a complete hardware embodiment, a complete software embodiment, or an embodiment in combination with software and hardware. Moreover, the embodiments of the present application may adopt the form of a computer program product implemented in one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) that contain computer-usable program code.
[0102] The present application is described with reference to the flowcharts and / or block diagrams of the methods, devices (systems), and computer program products according to the embodiments of the present application. It should be understood that each process and / or box in the flowchart and / or block diagram, as well as the combination of the processes and / or boxes in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to generate a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.
[0103] Moreover, these computer program instructions can also be stored in a computer-readable memory that can guide a computer or other programmable data processing device to work in a specific manner, so that the instructions stored in the computer-readable memory produce a product including an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 The function specified in one or more boxes.
[0104] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for executing on the computer or other programmable device to implement the process. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.
[0105] The above description is only a preferred embodiment of the present application and is not intended to limit the present application. Any modifications, equivalent substitutions, improvements, etc. made within the spirit and principles of the present application shall be included in the scope of protection of the present application.
Claims
1. A traffic forwarding method, characterized in that: A controller applied to a Spine-Leaf network, the method comprising: Based on the source destination address of the task to be trained, determine the target path for transmitting the traffic of the task to be trained, and based on the target path, determine the target outbound interface for forwarding the traffic of the task to be trained on the target Leaf accessed by the source server; Sending information requesting a target source port value to the target Leaf, wherein after receiving the information, the target Leaf calculates a corresponding target source port value based on the source destination address of the task to be trained and the target outbound interface, and feeds the target source port value back to the controller; Receive the target source port value fed back by the target Leaf, and instruct the source server to set the message source port of the traffic of the task to be trained to the target source port value when executing the task to be trained, wherein the target Leaf hashes the traffic of the task to be trained to the target outbound interface for forwarding based on the source destination address of the traffic of the task to be trained and the target source port value.
2. The method according to claim 1, characterized in that The step of determining a target path for transmitting traffic of the task to be trained based on the source and destination addresses of the task to be trained comprises: Obtain the network topology information of the entire network, the host ARP information, and the mapping relationship between each ingress port included in each port group constructed on the Spine device and each equal-cost route included in each equal-cost route group, wherein the network topology information of the entire network includes each link relationship and the ingress and egress interface information included in each link; Defining an initial cost value of each link included in the network topology information of the entire network, wherein the size of the initial cost value of a link is inversely proportional to the maximum bandwidth value of the link; According to the source and destination information of the task to be trained, the host ARP information, the mapping relationship between each input port included in each port group constructed on each Spine device and each equivalent-cost route included in each equivalent-cost route group, and the cost value of each link included in the network topology information of the entire network, determine the target path for transmitting the traffic of the task to be trained, wherein the sum of the cost values of each target link included in the target path is less than or equal to a preset value.
3. A traffic forwarding method, characterized in that: Applied to the source server, the method includes: Receive an instruction sent by a controller to set the message source port of the task to be trained to a target source port value, wherein the controller determines a target path for transmitting the traffic of the task to be trained based on the source destination address of the task to be trained, and determines a target outbound interface for forwarding the traffic of the task to be trained on the target Leaf to which the source server is connected based on the target path, and then sends information requesting the target source port value to the target Leaf. After receiving the information, the target Leaf calculates the corresponding target source port value based on the source destination address of the task to be trained and the target outbound interface, and feeds the target source port value back to the controller; The task traffic to be trained whose message source port is the target source port value is sent to the target Leaf, so that the target Leaf hashes the task traffic to be trained to the target outbound interface for forwarding based on the source destination address of the task traffic to be trained and the target source port value.
4. The method according to claim 3, characterized in that An agent program is installed on the source server, and the agent program receives an instruction sent by the controller to set the message source port of the task to be trained to the target source port value, and when determining to start the task to be trained, sets the message source port of the task to be trained traffic to the target source port value, and sends the task to be trained traffic with the message source port as the target source port value to the target Leaf.
5. A traffic forwarding device, characterized in that: A controller used in a Spine-Leaf network, the device comprising: A determination unit, configured to determine a target path for transmitting the traffic of the task to be trained based on the source destination address of the task to be trained, and determine a target outbound interface for forwarding the traffic of the task to be trained on a target Leaf accessed by the source server based on the target path; A sending unit, configured to send information requesting a target source port value to the target Leaf, wherein after receiving the information, the target Leaf calculates a corresponding target source port value based on the source destination address of the task to be trained and the target outbound interface, and feeds the target source port value back to the controller; A receiving unit is used to receive the target source port value fed back by the target Leaf, and instruct the source server to set the message source port of the traffic of the task to be trained to the target source port value when executing the task to be trained, wherein the target Leaf hashes the traffic of the task to be trained to the target outbound interface for forwarding based on the source destination address of the traffic of the task to be trained and the target source port value.
6. The device according to claim 5, characterized in that When determining a target path for transmitting traffic of the task to be trained based on the source and destination addresses of the task to be trained, the determining unit is specifically configured to: Obtain the network topology information of the entire network, the host ARP information, and the mapping relationship between each ingress port included in each port group constructed on the Spine device and each equal-cost route included in each equal-cost route group, wherein the network topology information of the entire network includes each link relationship and the ingress and egress interface information included in each link; Defining an initial cost value of each link included in the network topology information of the entire network, wherein the size of the initial cost value of a link is inversely proportional to the maximum bandwidth value of the link; According to the source and destination information of the task to be trained, the host ARP information, the mapping relationship between each input port included in each port group constructed on each Spine device and each equivalent-cost route included in each equivalent-cost route group, and the cost value of each link included in the network topology information of the entire network, determine the target path for transmitting the traffic of the task to be trained, wherein the sum of the cost values of each target link included in the target path is less than or equal to a preset value.
7. A traffic forwarding device, characterized in that: Applied to a source server, the device comprises: A receiving unit, configured to receive an instruction sent by a controller to set a message source port of a task to be trained to a target source port value, wherein the controller determines a target path for transmitting the traffic of the task to be trained based on the source destination address of the task to be trained, and determines a target outbound interface for forwarding the traffic of the task to be trained on a target Leaf to which the source server is connected based on the target path, and then sends information requesting a target source port value to the target Leaf. After receiving the information, the target Leaf calculates a corresponding target source port value based on the source destination address of the task to be trained and the target outbound interface, and feeds the target source port value back to the controller; A sending unit is used to send the task traffic to be trained whose source port is the target source port value to the target Leaf, so that the target Leaf hashes the task traffic to be trained to the target outbound interface for forwarding based on the source destination address of the task traffic to be trained and the target source port value.
8. The device according to claim 7, characterized in that An agent program is installed on the source server, and the agent program receives an instruction sent by the controller to set the message source port of the task to be trained to the target source port value, and when determining to start the task to be trained, sets the message source port of the task to be trained traffic to the target source port value, and sends the task to be trained traffic with the message source port as the target source port value to the target Leaf.
9. A traffic forwarding device, characterized in that: The traffic forwarding device comprises: A memory for storing program instructions; A processor is used to call the program instructions stored in the memory, and execute the steps of the method according to any one of claims 1-2 or any one of claims 3-4 according to the obtained program instructions.
10. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer-executable instructions, and the computer-executable instructions are used to enable the computer to execute the steps of the method according to any one of claims 1 to 2, or any one of claims 3 to 4.
Citation Information
Patent Citations
Load balancing method and device and equipment
CN107634912A
Method for forwarding message in data center network and related device
CN112152924A
Flow transmission method, device and controller
CN115412499A
Forwarding path planning method for large-scale data network center
CN115462049A
Message processing method and device, equipment and storage medium
CN115865850A