Data transmission method, device, electronic device, storage medium and program product

By obtaining the routing path corresponding to the network card of the computing device in a multi-layer network architecture, the problem of low data transmission efficiency between computing devices is solved, the switch load balancing is realized, and the data transmission rate and the efficiency of training artificial intelligence models are improved.

CN118764448BActive Publication Date: 2024-12-31TENCENT TECHNOLOGY (SHENZHEN) CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411201394.7
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-08-29
Publication Date
2024-12-31
Estimated Expiration
2044-08-29

AI Technical Summary

Technical Problem

In the prior art, data transmission efficiency between computing devices is low, resulting in unbalanced switch load, especially when training artificial intelligence models, data transmission efficiency is reduced.

Method used

Using a multi-layer network architecture, data transmission is realized by obtaining the routing path corresponding to the network card in the computing device, ensuring that there is a one-to-one correspondence between the routing path and the network card, avoiding random determination of the routing path, and improving switch load balancing.

Benefits of technology

The data transmission rate and efficiency between computing devices are improved, especially when training artificial intelligence models, and the efficiency of data transmission is improved.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118764448B_ABST
    Figure CN118764448B_ABST
Patent Text Reader

Abstract

The present application provides a data transmission method, device, electronic device, storage medium and program product; the method is applied to a multi-layer network architecture, the convergence layer includes at least one convergence sublayer, the access layer includes multiple access switches, each access switch is connected to at least one first computing device, each first computing device is provided with at least one network card, the convergence sublayer includes multiple convergence switches, the method includes: for any network card in the first computing device, obtain a routing path for transmitting data to the network card, send the routing path to a second access switch in the access layer, the second access switch is connected to at least one second computing device, and the second access switch and the first access switch belong to different blocks; the second access switch is used to forward the data corresponding to the network card of the destination address sent by the second computing device to the network card based on the routing path. Through the present application, the efficiency of data transmission can be improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of data processing technology, and in particular to a data transmission method, device, electronic device, storage medium and program product. Background Art

[0002] With the development of science and technology, users have higher and higher demands for the use of computing devices. In related technologies, when a first computing device and a second computing device need to perform data transmission, the first computing device can randomly send a data transmission request to a switch, and then the switch can send the data transmission request to the second computing device, that is, the routing path is composed of a path between the first computing device and a randomly determined switch, and a path between the randomly determined switch and the second computing device, which is equivalent to a randomly determined routing path. The randomly determined routing path will cause an unbalanced load on the switch, thereby resulting in a low rate of data transmission between computing devices, that is, low efficiency of data transmission between computing devices. Summary of the invention

[0003] The embodiments of the present application provide a data transmission method, device, electronic device, storage medium and program product, which can improve the efficiency of data transmission.

[0004] The technical solution provided in the embodiment of the present application is implemented as follows:

[0005] The embodiment of the present application provides a data transmission method, which is applied to a multi-layer network architecture, wherein the multi-layer network architecture includes an access layer and a convergence layer, wherein the convergence layer includes at least one convergence sublayer, and the access layer includes a plurality of access switches, each of the access switches is connected to at least one first computing device, each of the first computing devices is provided with at least one network card, and the convergence sublayer includes a plurality of convergence switches, wherein the method includes:

[0006] For any network card in the first computing device, obtaining a routing path for transmitting data to the network card, wherein there is a one-to-one correspondence between the routing path and the network card;

[0007] Sending the routing path to a second access switch in the access layer, where the second access switch is connected to at least one second computing device, and the second access switch and the first access switch belong to different blocks;

[0008] The second access switch is used to forward the data sent by the second computing device and having a destination address corresponding to the network card to the network card based on the routing path.

[0009] The embodiment of the present application further provides a data transmission method, which is applied to a multi-layer network architecture, wherein the multi-layer network architecture includes an access layer and a convergence layer, wherein the convergence layer includes at least one convergence sublayer, and the access layer includes a plurality of access switches, each of the access switches is connected to at least one first computing device, each of the first computing devices is provided with at least one network card, and the convergence sublayer includes a plurality of convergence switches, wherein the method includes:

[0010] The second access switch in the access layer receives a routing path for transmitting data to a network card in the first computing device, wherein the routing path has a one-to-one correspondence with the network card;

[0011] The second access switch is connected to at least one second computing device, and the second access switch and the first access switch belong to different blocks;

[0012] After receiving the data sent by the second computing device and having a destination address corresponding to the network card, the data is sent to the network card based on the routing path.

[0013] The embodiment of the present application further provides a data transmission device, which is applied to a multi-layer network architecture, wherein the multi-layer network architecture includes an access layer and a convergence layer, wherein the convergence layer includes at least one convergence sublayer, wherein the access layer includes a plurality of access switches, each of the access switches is connected to at least one first computing device, each of the first computing devices is provided with at least one network card, the convergence sublayer includes a plurality of convergence switches, and the device includes:

[0014] An acquisition module, configured to acquire, for any network card in the first computing device, a routing path for transmitting data to the network card, wherein there is a one-to-one correspondence between the routing path and the network card;

[0015] A first sending module is configured to send the routing path to a second access switch in the access layer, where the second access switch is connected to at least one second computing device, and the second access switch and the first access switch belong to different blocks;

[0016] The second access switch is used to forward the data sent by the second computing device and having a destination address corresponding to the network card to the network card based on the routing path.

[0017] In the above scheme, in some embodiments, the first access switch has at least one first port, and there is a second port corresponding to the first port one by one; the acquisition module is also used to determine the first port corresponding to the network card from the pre-set correspondence between the candidate network card and the candidate first port, and use the path between the network card and the first port corresponding to the network card as the first path; determine the aggregation switch corresponding to the second port from the pre-set correspondence between the candidate second port and the candidate aggregation switch, and determine the second path based on the second port and the aggregation switch corresponding to the second port; determine the routing path based on the first path and the second path.

[0018] In the above scheme, the number of the convergence sublayers is multiple; the convergence switches corresponding to the second port include a first convergence switch and a second convergence switch, the first convergence switch and the second convergence switch belong to different convergence sublayers, and the first access switch is connected to the second convergence switch;

[0019] The acquisition module is further configured to use the routing path between the second port and the second aggregation switch as the first sub-path; use the routing path between the second aggregation switch and the first aggregation switch as the second sub-path; and determine the second path based on the first sub-path and the second sub-path.

[0020] In the above scheme, the multi-layer network architecture also includes a core layer, and the core layer includes multiple core switches. The acquisition module is also used to obtain a first path between the network card and the first access switch in the access layer, and obtain a second path between the first access switch and the aggregation switch in the at least one aggregation sublayer; determine the target core switch corresponding to the aggregation switch in the second path from the pre-set correspondence between the candidate aggregation switches and the candidate core switches; use the path between the aggregation switch in the second path and the target core switch as the third path; and determine a routing path based on the first path, the second path and the third path.

[0021] In the above scheme, the first access switch belongs to the first block, and the first sending module is further used to search for a second identifier matching the first identifier from identifiers of access switches belonging to the second block according to the first identifier of the first access switch, wherein the first block is different from the second block; and use the access switch indicated by the second identifier as the second access switch, and send the routing path to the second access switch.

[0022] In the above scheme, the first identifier is a first number, the number of access switches belonging to the second block is multiple, and the identifier of the access switch belonging to the second block is a second number. The first sending module is further used to determine the difference between the first number and the second number for each second number; if the quotient of the difference and a preset third number is a target value, the second number is used as a second identifier matching the first identifier.

[0023] In the above scheme, the first sending module is also used to determine the target identifier corresponding to the first identifier from the correspondence between the pre-set candidate first identifiers and the candidate target identifiers according to the first identifier of the first access switch; and to search for an identifier consistent with the target identifier from the identifiers of the access switches belonging to the second block as the second identifier matching the first identifier.

[0024] In the above scheme, the acquisition module is further used to obtain the first operation information of the first access switch and the second operation information of the aggregation switch after sending the routing path to the second access switch in the access layer; if at least one of the first operation information and the second operation information indicates that there is an abnormality in the routing path, a new routing path for transmitting data to the network card is obtained, and the new routing path is sent to the second access switch in the access layer; wherein the second access switch is further used to replace the routing path with the new routing path, and based on the new routing path, forward the data sent by the second computing device and corresponding to the network card to the network card.

[0025] In the above scheme, the acquisition module is also used to send the new routing path carrying the routing priority to the second access switch in the access layer; wherein the routing priority of the new routing path is higher than the routing priority of the routing path; the second access switch is also used to replace the routing path with the new routing path based on the routing priority of the new routing path.

[0026] In the above scheme, the acquisition module is further used to determine a third access switch from the access switches included in the block to which the first access switch belongs; determine a target network card corresponding to the third access switch from the preset correspondence between candidate network cards and candidate access switches; use the path between the target network card and the third access switch as a new first path; use the path between the third access switch and the aggregation switch as a new second path; determine a new routing path based on the new first path and the new second path; the target network card is used to forward the data of the network card to the network card after receiving the data of the network card sent by the second access switch based on the new routing path.

[0027] In the above scheme, the acquisition module is further used to, when the abnormality of the routing path is caused by the failure of the aggregation switch or by the failure of the line between the first access switch and the aggregation switch, determine a third aggregation switch from the aggregation switches included in the aggregation sublayer to which the aggregation switch belongs; determine a fourth path based on the first access switch and the third aggregation switch; and replace the second path in the routing path with the fourth path to obtain a new routing path.

[0028] In the above scheme, there are multiple convergence sublayers; the acquisition module is further used to take the path between the first access switch and the third convergence switch as the third sub-path; based on the preset correspondence between the candidate third convergence switch and the candidate fourth convergence switch, determine the fourth convergence switch corresponding to the third convergence switch, and the third convergence switch and the fourth convergence switch belong to different convergence sublayers; take the path between the third convergence switch and the fourth convergence switch as the fourth sub-path; and determine the fourth path based on the third sub-path and the fourth sub-path.

[0029] In the above scheme, the first sending module is also used to send a new routing path deletion instruction to the second access switch in the access layer after sending the new routing path to the second access switch in the access layer, if the operation information changes from indicating that the routing path is operating abnormally to operating normally, so that the second access switch deletes the new routing path.

[0030] The embodiment of the present application further provides a data transmission device, which is applied to a multi-layer network architecture, wherein the multi-layer network architecture includes an access layer and a convergence layer, wherein the convergence layer includes at least one convergence sublayer, wherein the access layer includes a plurality of access switches, each of the access switches is connected to at least one first computing device, each of the first computing devices is provided with at least one network card, the convergence sublayer includes a plurality of convergence switches, and the device includes:

[0031] A receiving module, used for a second access switch in the access layer, to receive a routing path for transmitting data to a network card in the first computing device, wherein the routing path and the network card have a one-to-one correspondence;

[0032] The second access switch is connected to at least one second computing device, and the second access switch and the first access switch belong to different blocks;

[0033] A second sending module is configured to send the data to the network card based on the routing path after receiving the data sent by the second computing device and whose destination address corresponds to the network card.

[0034] An embodiment of the present application provides an electronic device, the electronic device comprising:

[0035] A memory for storing computer executable instructions or computer programs;

[0036] The processor is used to implement the data transmission method provided in the embodiment of the present application when executing the computer executable instructions or computer programs stored in the memory.

[0037] An embodiment of the present application provides a computer-readable storage medium storing a computer program or a computer-executable instruction or a computer program for implementing the data transmission method provided in the embodiment of the present application when executed by a processor.

[0038] An embodiment of the present application provides a computer program product, including a computer program or computer executable instructions. When the computer program or computer executable instructions are executed by a processor, the data transmission method provided in the embodiment of the present application is implemented.

[0039] The embodiments of the present application have the following beneficial effects:

[0040] In the data transmission method provided in the embodiment of the present application, for any network card in the first computing device, a routing path for transmitting data to the network card can be obtained, and there is a one-to-one correspondence between the routing path and the network card. The routing path is sent to the second access switch in the access layer, and the second access switch is connected to at least one second computing device, and the second access switch and the first access switch belong to different blocks. The second access switch is used to forward the data of the network card corresponding to the destination address sent by the second computing device to the network card based on the routing path.

[0041] That is to say, in the data transmission method provided in the embodiment of the present application, there is a one-to-one corresponding routing path for any network card of the first computing device, and the second computing device can send data to any network card of the first computing device based on the routing path. Compared with the method of randomly determining the routing path for data transmission, the present application uses the routing path corresponding to the network card for data transmission, which can achieve switch load balancing for data transmission between the first computing device and the second computing device, thereby increasing the rate of data transmission, that is, the data transmission method provided in the embodiment of the present application can improve the efficiency of data transmission. BRIEF DESCRIPTION OF THE DRAWINGS

[0042] Figure 1A is a schematic diagram of the structure of a data transmission system provided in an embodiment of the present application;

[0043] Figure 1B This is a structural diagram 1 of a multi-layer network architecture provided by an embodiment of the present application;

[0044] Figure 2Ais a schematic structural diagram of a first electronic device provided in an embodiment of the present application;

[0045] Figure 2B is a schematic diagram of the structure of a second electronic device provided in an embodiment of the present application;

[0046] Figure 3A This is a second structural diagram of a multi-layer network architecture provided in an embodiment of the present application;

[0047] Figure 3B This is a structural diagram 3 of the multi-layer network architecture provided by the embodiment of the present application;

[0048] Figure 4 is a schematic diagram of a data transmission method provided in an embodiment of the present application;

[0049] Figure 5 1 is a flowchart of a data transmission method provided in an embodiment of the present application;

[0050] Figure 6 Schematic diagram 2 of the data transmission method provided in the embodiment of the present application;

[0051] Figure 7 Schematic diagram 1 of a routing path provided in an embodiment of the present application;

[0052] Figure 8 Schematic diagram 2 of the routing path provided in the embodiment of the present application;

[0053] Fig. 9 Schematic diagram 3 of the data transmission method provided in the embodiment of the present application;

[0054] Fig.10 This is a schematic diagram of the data transmission method provided in the embodiment of the present application. Figure 4 ;

[0055] Fig.11 This is a schematic diagram of the data transmission method provided in the embodiment of the present application. Figure 5 ;

[0056] Fig.12 Schematic diagram 3 of the routing path provided in the embodiment of the present application;

[0057] Fig.13 This is a schematic diagram of the data transmission method provided in the embodiment of the present application. Figure 6 ;

[0058] Fig.14 This is a schematic diagram of the routing path provided in the embodiment of the present application. Figure 4 ;

[0059] Fig.15 is a schematic diagram of the connection relationship between the computing device and the access switch provided in an embodiment of the present application;

[0060] Fig.16 This is a schematic diagram of the data transmission method provided in the embodiment of the present application. Figure 7 ;

[0061] Fig.17 This is a schematic diagram of the routing path provided in the embodiment of the present application. Figure 5 ;

[0062] Fig.18 This is a schematic diagram of the data transmission method provided in the embodiment of the present application. Figure 8 ;

[0063] Fig.19 This is a schematic diagram of the data transmission method provided in the embodiment of the present application. Figure 9 ;

[0064] Fig. 20 This is a schematic diagram of the data transmission method provided in the embodiment of the present application. Figure 10 ;

[0065] Fig.21 It is a schematic diagram of the transmission rate test results provided in the embodiment of the present application. DETAILED DESCRIPTION

[0066] In order to make the purpose, technical solutions and advantages of the present application clearer, the present application will be further described in detail below in conjunction with the accompanying drawings. The described embodiments should not be regarded as limiting the present application. All other embodiments obtained by ordinary technicians in the field without making creative work are within the scope of protection of this application.

[0067] In the following description, reference is made to “some embodiments”, which describe a subset of all possible embodiments, but it will be understood that “some embodiments” may be the same subset or different subsets of all possible embodiments and may be combined with each other without conflict.

[0068] In the following description, the terms "first\second\third" involved are merely used to distinguish similar objects and do not represent a specific ordering of the objects. It can be understood that "first\second\third" can be interchanged with a specific order or sequence where permitted, so that the embodiments of the present application described herein can be implemented in an order other than that illustrated or described herein.

[0069] In the embodiments of the present application, the term "module" or "unit" refers to a computer program or a part of a computer program that has a predetermined function and works together with other related parts to achieve a predetermined goal, and can be implemented in whole or in part by using software, hardware (such as processing circuits or memories), or a combination thereof. Similarly, a processor (or multiple processors or memories) can be used to implement one or more modules or units. In addition, each module or unit can be part of an overall module or unit that includes the function of the module or unit.

[0070] Unless otherwise defined, all technical and scientific terms used in the embodiments of the present application have the same meanings as those commonly understood by those skilled in the art. The terms used in the embodiments of the present application are only for the purpose of describing the embodiments of the present application and are not intended to limit the present application.

[0071] The relevant data collection and processing in the embodiments of this application should be strictly in accordance with the requirements of relevant laws and regulations when applied in examples, obtain the informed consent or separate consent of the personal information subject, and carry out subsequent data use and processing within the scope of authorization of laws and regulations and the personal information subject.

[0072] Before further describing the embodiments of the present application in detail, the nouns and terms involved in the embodiments of the present application are explained. The nouns and terms involved in the embodiments of the present application are subject to the following interpretations.

[0073] 1) Access Layer: In the present application, the access layer includes multiple access switches and multiple first computing devices. Each access switch is connected to at least one first computing device, that is, one access switch can be connected to one or more first computing devices.

[0074] 2) Aggregation Layer: In the present application, the aggregation layer includes one or more aggregation sublayers, each of which may include multiple aggregation switches, that is, one aggregation sublayer includes one or more aggregation switches.

[0075] 3) Core Layer: In the present application, the core layer may include one or more core sublayers, and each core sublayer may include one or more core switches.

[0076] 4) Switch: In this application, a switch is a computer network device that is used to connect computing devices to achieve communication between computing devices. For example, a first access switch, a second access switch, and an aggregation switch can be used to connect a first computing device and a second computing device to achieve communication between the first computing device and the second computing device.

[0077] 5) Network Interface Card: A network card is a computer hardware device used to connect a computing device to a network so that the computing device can send and receive data via wired or wireless means.

[0078] 6) Computing device: In this application, the computing device may be a device including a graphics processor, which is a microprocessor that performs image and graphics related operations in the computing device. Depending on actual usage requirements, the computing device may also include other processors.

[0079] 7) High Performance Compute (HPC): In this application, high performance computing refers to using the computing power of a computing cluster to solve problems in different fields. The computing cluster includes a first computing device and a second computing device. For example, the computing power of the computing cluster can be used to solve problems in scientific research, weather forecasting, artificial intelligence, image processing and other fields.

[0080] 8) Block: In this application, a block is a computing unit composed of multiple computing devices (such as GPU servers, access switches) in a high-performance computing scenario. The computing devices in this unit can be connected through a high-speed network and can work together to process computing tasks.

[0081] 9) Cloud technology: Cloud technology refers to a hosting technology that unifies hardware, software, network and other resources within a wide area network or local area network to achieve data computing, storage, processing and sharing.

[0082] The related technology has the following problems:

[0083] Technical Problem 1. In the related technology, when the first computing device and the second computing device need to transmit data, the first computing device can randomly send a data transmission request to the switch, and then the switch can send the data transmission request to the second computing device, that is, the routing path is composed of the path between the first computing device and the randomly determined switch, and the path between the randomly determined switch and the second computing device, which is equivalent to the routing path being randomly determined, and the randomly determined routing path will cause an unbalanced load on the switch, thereby resulting in a low rate of data transmission between the computing devices, that is, the efficiency of data transmission between the computing devices is low.

[0084] Technical Issue 2: In related technologies, for the scenario of training artificial intelligence models, a large amount of data needs to be transmitted between computing devices. Following Technical Issue 1, the efficiency of training artificial intelligence models is reduced due to the low efficiency of data transmission between computing devices.

[0085] Technical Problem 3: In the related art, a hash function can be used to determine the routing path for data transmission between computing devices. Specifically, the information of the computing device can be hashed by the hash function to obtain a hash value, and the routing path can be determined based on the hash value. The method of using a hash function to determine the routing path for data transmission between computing devices will lead to the problem of local hot spots, that is, it will cause an unbalanced load on the switch, resulting in a low rate of data transmission between computing devices, that is, the efficiency of data transmission between computing devices is low.

[0086] Technical Problem 4: In related technologies, when there is congestion on the routing path, the efficiency of data transmission between computing devices will be low and the communication bandwidth will be reduced.

[0087] The embodiments of the present application provide a data transmission method, device, electronic device, computer-readable storage medium, and computer program product, which can improve the efficiency of data transmission.

[0088] See also Figure 1A , Figure 1A 1 is a schematic diagram of the structure of the data transmission system provided in the embodiment of the present application. The data transmission system 100 can realize supporting a data transmission application. In some embodiments, the data transmission system 100 includes a terminal 400, a server 200-1, a server 200-2, a server 200-3 and a switch. Figure 1A Only the first access switch 500 - 1 , the second access switch 500 - 2 and the aggregation switch 600 are illustrated.

[0089] Server 200-1 is a first computing device, which includes a graphics processor and is provided with at least one network card. Server 200-2 is a second computing device, which includes a graphics processor and is provided with at least one network card.

[0090] A Software Defined Network (SDN) controller is installed in the server 200 - 3 . The terminal 400 , the server 200 - 1 , the server 200 - 2 and the server 200 - 3 are all connected via a network 300 , which may be a wide area network or a local area network, or a combination of the two.

[0091] The server 200-1 is connected to the first access switch 500-1 via a network cable, the first access switch 500-1 is connected to the aggregation switch 600 via a network cable, the aggregation switch 600 is connected to the second access switch 500-2 via a network cable, and the second access switch 500-2 is connected to the server 200-2 via a network cable.

[0092] The data transmission system 100 is applied to a multi-layer network architecture, see Figure 1B , Figure 1B 1 is a schematic diagram of a multi-layer network architecture provided in an embodiment of the present application. The multi-layer network architecture includes an access layer 700-1 and a convergence layer. The access layer 700-1 includes multiple access switches. Figure 1B Only the first access switch 500-1 and the second access switch 500-2 are shown. The first access switch 500-1 and the second access switch 500-2 belong to different blocks, that is, the first access switch 500-1 belongs to the first block 201, and the second access switch 500-2 belongs to the second block 202. The convergence layer includes a convergence sublayer 700-2, and the convergence sublayer 700-2 includes multiple convergence switches. Figure 1B Only the aggregation switch 600 is shown.

[0093] Continue to see Figure 1A In some embodiments, when a user requires data transmission between server 200-1 and server 200-2, in response to a data transmission instruction triggered by a graphical interface 410-1 based on terminal 400, terminal 400 may send a data transmission request generated based on the data transmission instruction to server 200-3.

[0094] In some embodiments, for different scenarios, the terminal 400 can send different requests to the server 200-3, and the server 200-3 can determine whether data transmission is required based on the received request. For example, for an image processing scenario, in response to an image processing instruction triggered by a graphical interface 410-1 based on the terminal 400, the terminal 400 can send an image processing request generated based on the image processing instruction to the server 200-3, and the server 200-3 can then determine whether data transmission is required.

[0095] When server 200-3 determines that data transmission is required, or server 200-3 responds to a data transmission request, server 200-3 can obtain a routing path for transmitting data to a network card for any network card in server 200-1. There is a one-to-one correspondence between the routing path and the network card. The routing path includes: a first path between the network card and the first access switch 500-1, and a second path between the first access switch 500-1 and the aggregation switch 600.

[0096] The server 200 - 3 may send the routing path to the second access switch 500 - 2 , and the second access switch 500 - 2 is used to forward the data of the network card corresponding to the destination address sent by the server 200 - 2 to the network card based on the routing path.

[0097] The electronic device provided in the embodiment of the present application is described below. The electronic device includes a first electronic device and a second electronic device, wherein the first electronic device includes a software-defined grid controller. The first electronic device that implements the data transmission method provided in the embodiment of the present application may be a terminal, a server, or a combination of the two. The second electronic device of the data transmission method provided in the embodiment of the present application may also be a switch, specifically an access switch.

[0098] Among them, the terminal can be various types of terminals such as laptops, tablet computers, desktop computers, set-top boxes, smart phones, smart speakers, smart watches, smart TVs, and car terminals. The server can be an independent physical server, or a server cluster or distributed system composed of multiple physical servers. It can also be a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, middleware services, domain name services, security services, content delivery networks (Content Delivery Network, CDN), and big data and artificial intelligence platforms. The terminal and the server can be directly or indirectly connected via wired or wireless communication, which is not limited in the embodiments of the present application.

[0099] See also Figure 2A-2B , Figure 2A is a schematic diagram of the structure of a first electronic device provided in an embodiment of the present application, Figure 2B is a schematic diagram of the structure of a second electronic device provided in an embodiment of the present application, Figure 2A-2B The electronic devices (first electronic device and second electronic device) shown include: at least one processor 410, a memory 450, at least one network interface 420 and a user interface 430. The various components in the electronic devices (first electronic device and second electronic device) are coupled together via a bus system 440. It is understood that the bus system 440 is used to achieve connection and communication between these components. In addition to the data bus, the bus system 440 also includes a power bus, a control bus and a status signal bus. However, for the sake of clarity, the bus system 440 is not described in detail. Figure 2A-2B Various buses are labeled as bus system 440 .

[0100] The processor 410 may be an integrated circuit chip having signal processing capabilities, such as a general-purpose processor, a digital signal processor (DSP), or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc., wherein the general-purpose processor may be a microprocessor or any conventional processor, etc.

[0101] The user interface 430 includes one or more output devices 431 that enable presentation of media content, including one or more speakers and / or one or more visual display screens. The user interface 430 also includes one or more input devices 432, including user interface components that facilitate user input, such as a keyboard, mouse, microphone, touch screen display, camera, other input buttons and controls.

[0102] The memory 450 may be removable, non-removable, or a combination thereof. Exemplary hardware devices include solid-state memory, hard disk drives, optical disk drives, etc. The memory 450 may optionally include one or more storage devices that are physically remote from the processor 410.

[0103] The memory 450 includes a volatile memory or a non-volatile memory, and may also include both volatile and non-volatile memories. The non-volatile memory may be a read-only memory (ROM), and the volatile memory may be a random access memory (RAM). The memory 450 described in the embodiments of the present application is intended to include any suitable type of memory.

[0104] In some embodiments, memory 450 can store data to support various operations, examples of which include programs, modules, and data structures, or a subset or superset thereof, as exemplarily described below.

[0105] Operating system 451, including system programs for processing various basic system services and performing hardware-related tasks, such as a framework layer, a core library layer, a driver layer, etc., for implementing various basic services and processing hardware-based tasks;

[0106] A network communication module 452, used to reach other electronic devices via one or more (wired or wireless) network interfaces 420, exemplary network interfaces 420 include: Bluetooth, Wireless LAN (WiFi), and Universal Serial Bus (USB), etc.;

[0107] a presentation module 453 for enabling presentation of information via one or more output devices 431 (e.g., display screen, speaker, etc.) associated with the user interface 430 (e.g., a user interface for operating peripherals and displaying content and information);

[0108] The input processing module 454 is used to detect one or more user inputs or interactions from one of the one or more input devices 432 and translate the detected inputs or interactions.

[0109] In some embodiments, the data transmission device provided in the embodiments of the present application can be implemented in software. Figure 2A The data transmission device 455 stored in the memory 450 is shown, which can be software in the form of a program and a plug-in, etc., including the following software modules: an acquisition module 4551 and a first sending module 4552. These modules are logical, so they can be arbitrarily combined or further split according to the functions implemented. The functions of each module will be described below.

[0110] Figure 2B The data transmission device 456 stored in the memory 450 is shown, which can be software in the form of a program and a plug-in, etc., including the following software modules: a receiving module 4561 and a second sending module 4562. These modules are logical, so they can be arbitrarily combined or further split according to the functions implemented. The functions of each module will be explained below.

[0111] In other embodiments, the data transmission device provided in the embodiments of the present application can be implemented in hardware. As an example, the data transmission device provided in the embodiments of the present application can be a processor in the form of a hardware decoding processor, which is programmed to execute the data transmission method provided in the embodiments of the present application. For example, the processor in the form of a hardware decoding processor can adopt one or more application specific integrated circuits (Application Specific Integrated Circuit, ASIC), digital signal processors (Digital Signal Processor, DSP), programmable logic devices (Programmable Logic Device, PLD), complex programmable logic devices (Complex Programmable Logic Device, CPLD), field programmable gate arrays (Field-Programmable Gate Array, FPGA) or other electronic components.

[0112] The first data transmission method provided in the embodiment of the present application is described below. As mentioned above, the first electronic device that implements the data transmission method provided in the embodiment of the present application may be a terminal, a server, or a combination of the two.

[0113] The data transmission method provided in the embodiment of the present application is applied to a multi-layer network architecture. In order to facilitate understanding of the data transmission method provided in the embodiment of the present application, the multi-layer network architecture is described below. In the multi-layer network architecture provided in the embodiment of the present application, the network topology connection relationship between each switch is a fat tree topology.

[0114] In some embodiments, the multi-layer network architecture includes an access layer and a convergence layer, the convergence layer includes at least one (one or more) convergence sublayers, the access layer includes multiple access switches, and the convergence sublayer includes multiple convergence switches. For the case where the convergence layer includes one convergence sublayer, please refer to Figure 1B .

[0115] In some embodiments, the access layer includes a first access switch and a second access switch, wherein the first access switch is connected to at least one (one or more) first computing devices, the second access switch is connected to at least one (one or more) second computing devices, and the first access switch and the second switch belong to different blocks. For each block, the number of computing devices in the block can be one or more, which can be set according to actual usage requirements.

[0116] Each computing device is provided with at least one network card, that is, the first computing device is provided with one or more network cards, and the second computing device is provided with one or more network cards. The number of the first computing device and the number of the second computing device can be the same or different. The number of network cards provided on the first computing device can be the same as the number of network cards provided on the second computing device, or different, and can be specifically set according to actual usage requirements.

[0117] For example, the number of first computing devices may be 2, the number of second computing devices may be 1, the number of network cards set on any one of the first computing devices may be 8, and the number of network cards set on the second computing device may be 16, that is, the number of first computing devices is different from the number of second computing devices, and the number of network cards set on the first computing device is different from the number of network cards set on the second computing device.

[0118] For a multi-layer network architecture, there are multiple blocks. For each block, the number of access switches in the block is determined according to the number of ports of the access switch and the number of network cards, and the number of aggregation switches is determined according to the number of aggregation sublayers, the number of access switches in the access layer, and the number of ports of each access switch. When the number of aggregation sublayers is 1, the number of aggregation switches is equal to the number of ports of the access switch in the access layer.

[0119] In some embodiments, the blocks can be divided according to the number of network cards. For example, the computing devices corresponding to every 16 network cards that can be connected to the switch can be regarded as a block. In some embodiments, the blocks can also be divided according to the tasks performed, according to the regions, or according to the types of graphics processors. The specific settings can be made according to actual usage requirements.

[0120] The number of access switches in the access layer may be the same as or different from the number of aggregation switches in an aggregation sublayer, and may be set according to actual usage requirements.

[0121] Combine the following Figure 3A The multi-layer network architecture provided in the embodiment of the present application is illustrated by example. Figure 3A , Figure 3A This is the second structural diagram of the multi-layer network architecture provided in an embodiment of the present application. The multi-layer network architecture includes an access layer 310 and a convergence layer 320, wherein the convergence layer 320 includes two convergence sublayers, specifically a first convergence sublayer 301 and a second convergence sublayer 302.

[0122] The number of switches (access switches) in the access layer 310, the number of switches (aggregation switches) in the first convergence sublayer 301, and the number of switches (aggregation switches) in the second convergence sublayer 302 may be the same or different, and may be specifically set according to actual usage requirements.

[0123] exist Figure 3A In the example, the first convergence sublayer 301 may include 64 convergence switches. Figure 3A The aggregation switch 3011 is shown in FIG. 1 . The second aggregation sublayer 302 may include 64 aggregation switches. Figure 3A An aggregation switch 3012 is shown in FIG.

[0124] The access layer 310 may include access switches located in different blocks. The number of blocks may be 16. Figure 3A Only the first block 3101 and the second block 3116 are shown, each block includes 4 access switches. Figure 3A In the example, the first block 3101 includes four access switches, including the first access switch 304. The second block 3116 includes four access switches, including the second access switch 305.

[0125] Each access switch is connected to one or more first computing devices. Figure 3A In the example, the first access switch 304 is connected to the first computing device 306 , and the second access switch 305 is connected to the second computing device 303 .

[0126] The first computing device 306 is provided with 16 network cards. Figure 3A The network card 3061 is shown in FIG. 1 . The second computing device 303 is provided with 16 network cards. Figure 3A30 shows a network card 3031, that is, the number of the first computing devices is the same as the number of the second computing devices, and the number of network cards arranged on the first computing device is the same as the number of network cards arranged on the second computing device.

[0127] In some embodiments, the multi-layer network architecture includes an access layer, an aggregation layer, and a core layer. The access layer and the aggregation layer can correspond to the above description of the access layer and the aggregation layer, and will not be repeated here. The core layer may include at least one (one or more) core sublayers, and the core sublayer includes multiple core switches.

[0128] The number of core sublayers can be set according to actual usage requirements. For each core sublayer, the number of core switches in the core sublayer is determined according to the number of aggregation switches in the aggregation sublayer and the number of ports of each aggregation switch. The number of aggregation switches in an aggregation sublayer can be the same as or different from the number of core switches in a core sublayer, and can be set according to actual usage requirements.

[0129] See also Figure 3B , Figure 3B 3 is a schematic diagram of the structure of the multi-layer network architecture provided in the embodiment of the present application. The multi-layer network architecture includes an access layer 310, a convergence layer 320 and a core layer. For the description of the access layer 310 and the convergence layer 320, please refer to Figure 3A , I will not go into details here.

[0130] The convergence layer 320 includes two convergence sublayers, specifically the first convergence sublayer 301 and the second convergence sublayer 302, and the core layer includes one core sublayer 401. The number of switches (core switches) in the core sublayer 401 can be the same as or different from the number of switches (access switches) in the access layer 310, the number of switches (aggregation switches) in the first convergence sublayer 301, and the number of switches (aggregation switches) in the second convergence sublayer 302. Figure 3B In the embodiment, the core sublayer 401 may include 64 core switches. Figure 3B Only the core switch 4011 is shown.

[0131] In some embodiments, when the number of computing devices is greater than a preset number threshold, due to the increased demand for communication bandwidth, a core layer can be set to meet the data transmission between computing devices with a number greater than the preset number threshold. In addition, the core layer can also improve the redundancy of the multi-layer network architecture. Even if there is an abnormality in the routing path, data transmission can still be performed, thereby improving the stability of data transmission.

[0132] In some embodiments, one or more access switches may be included for the same block, and an access switch may have multiple uplink ports (i.e., second ports). An aggregation sublayer may include multiple aggregation switches. For each access switch, different uplink ports are connected to a different aggregation sublayer corresponding to the aggregation switch, wherein the uplink port of the access switch is connected to the downlink port of the aggregation switch.

[0133] In some embodiments, a convergence sublayer includes multiple convergence switches, and a convergence switch includes multiple upstream convergence ports. The number of convergence sublayers includes multiple, and for one convergence switch, different upstream convergence ports are connected to different convergence switches in another convergence sublayer, that is, another convergence sublayer includes multiple convergence switches, wherein the upstream interface of the convergence switch in one convergence sublayer is connected to the downstream port of the convergence switch in another convergence sublayer.

[0134] In order to facilitate understanding of the data transmission method provided in the embodiment of the present application, see Figure 4 , Figure 4 This is a schematic diagram of a data transmission method provided in an embodiment of the present application. Figure 4 The data transmission method provided in the embodiment of the present application is described.

[0135] Figure 4 The connection relationship between the computing device, the access switch and the aggregation switch is shown. The block may include 16. Figure 4 The first block 411 and the second block 412 are shown in FIG. Each block may include 1 computing device and 4 access switches. Figure 4 In the example, the first block 411 includes a first computing device 402, access switch 1, access switch 2, access switch 3, and access switch 4. The first computing device 402 is connected to access switch 1, access switch 2, access switch 3, and access switch 4.

[0136] The second block 412 includes a second computing device 403, access switch 5, access switch 6, access switch 7, and access switch 8. The second computing device 403 is connected to access switch 5, access switch 6, access switch 7, and access switch 8.

[0137] For an access switch, different ports in the access switch are connected to different aggregation switches. Figure 4 In the example, access switch 1 includes 4 ports. Specifically, access switch 1 can be connected to aggregation switch 1, access switch 1 can be connected to aggregation switch 2, access switch 1 is connected to aggregation switch 3, and access switch 1 is connected to aggregation switch 4.

[0138] Access switch 2 includes 4 ports. Specifically, access switch 2 can be connected to aggregation switch 1, access switch 2 can be connected to aggregation switch 2, access switch 2 is connected to aggregation switch 3, and access switch 2 is connected to aggregation switch 4.

[0139] Access switch three includes 4 ports. Specifically, access switch three can be connected to aggregation switch one, access switch three can be connected to aggregation switch two, access switch three is connected to aggregation switch three, and access switch three is connected to aggregation switch four.

[0140] Access switch four includes 4 ports. Specifically, access switch four can be connected to aggregation switch one, access switch four can be connected to aggregation switch two, access switch four is connected to aggregation switch three, and access switch four is connected to aggregation switch four.

[0141] Access switch five includes 4 ports. Specifically, access switch five can be connected to aggregation switch one, access switch five can be connected to aggregation switch two, access switch five is connected to aggregation switch three, and access switch five is connected to aggregation switch four.

[0142] Access switch six includes 4 ports. Specifically, access switch six can be connected to aggregation switch one, access switch six can be connected to aggregation switch two, access switch six is ​​connected to aggregation switch three, and access switch six is ​​connected to aggregation switch four.

[0143] Access switch seven includes 4 ports. Specifically, access switch seven can be connected to aggregation switch one, access switch seven can be connected to aggregation switch two, access switch seven is connected to aggregation switch three, and access switch seven is connected to aggregation switch four.

[0144] Access switch eight includes four ports. Specifically, access switch eight can be connected to aggregation switch one, access switch eight can be connected to aggregation switch two, access switch eight is connected to aggregation switch three, and access switch eight is connected to aggregation switch four.

[0145] The path between the computing device and the access switch is the first path, and the connection relationship between the access switch and the aggregation switch is the second path. Figure 4 16 routing paths are shown. When data transmission is required, Figure 4 The data can be transmitted using any routing path shown.

[0146] Combine the following Figure 5 The data transmission method provided in the embodiment of the present application is described in detail. Figure 5 , Figure 5 This is a flow chart of the data transmission method provided in the embodiment of the present application. Figure 5 The steps shown, and taking the execution subject as a server as an example, illustrate the data transmission method provided in the embodiment of the present application.

[0147] In step 101, for any network card in a first computing device, a routing path for transmitting data to the network card is obtained.

[0148] When the user needs to perform data transmission, in some embodiments, in response to a data transmission instruction triggered for the terminal, the terminal may send a data transmission request to the server, and then the server may execute the above step 101.

[0149] In some embodiments, for scenarios requiring high-performance computing, in response to a target instruction triggered by the terminal, the terminal may send a target request to the server, so that the server may execute step 101 above, wherein the target instruction and the target request may be requests for high-performance computing scenarios, for example, for scenarios such as model training, weather forecasting, and big data processing, accordingly, the target request may be a model training request, a weather forecasting request, a data processing request, etc.

[0150] Among them, model training, weather forecasting, big data processing, etc. can be achieved through cloud computing, which distributes computing tasks across a large number of computing devices, so that computing resources can be obtained as needed. Among them, model training can be an artificial intelligence cloud service.

[0151] In some embodiments, step 101 may be implemented in the following manner: for any network card in the first computing device that needs to perform data transmission with the second computing device, a routing path for transmitting data to the network card may be obtained.

[0152] The routing path may be a Border Gateway Protocol (BGP) path. BGP is a protocol used to exchange routing information between different autonomous systems (AS). It is mainly used to transmit routing and reachability information between networks on the Internet, and is a key technology for interconnecting different network areas. Of course, it can also be a path corresponding to other protocols. For example, the routing path can also be a Policy-Based Routing path. It can be set according to actual usage requirements.

[0153] There is a one-to-one correspondence between routing paths and network cards, that is, each network card has a corresponding routing path. For example, the first computing device includes network card 1 and network card 2. Network card 1 corresponds to routing path 1, and network card 2 corresponds to routing path 2.

[0154] The routing path includes: a first path between the network card and a first access switch in the access layer, and a second path between the first access switch and a convergence switch in at least one convergence sublayer. Figure 4 The path between the network card of the first computing device 402 and the access switch 1 (ie, the first access switch) is the first path 4021, and the path between the access switch 1 and the aggregation switch 1 is the second path 4022. That is, the routing path includes the first path 4021 and the second path 4022.

[0155] See also Figure 6 , Figure 6 This is a flow chart of the data transmission method provided in the embodiment of the present application. Figure 6 The steps shown are Figure 5 The step "obtaining a routing path for transmitting data to a network card" is illustrated. The first access switch has at least one first port (uplink port) and a second port (downlink port) corresponding to the first port.

[0156] In step 1011, the first port corresponding to the network card is determined from the preset correspondence relationship between the candidate network cards and the candidate first ports, and the path between the network card and the first port corresponding to the network card is used as the first path.

[0157] In some embodiments, step 1011 can be implemented in the following manner: the preset correspondence between the candidate network card and the candidate first port is confirmed by the topological connection relationship between the first computing device and the first access switch, wherein the topological connection relationship between the first computing device and the first access switch can refer to Figure 4 Description.

[0158] For any network card in the first computing device, the first port corresponding to the network card can be determined from the pre-set correspondence between the candidate network cards and the candidate first ports, so that the path between the network card and the first port corresponding to the network card can be used as the first path, that is, the first path is the path between the network card and the first port corresponding to the network card, and the first port corresponding to the network card is the first port of the first access switch. In other words, the first path is the path between the network card and the first access switch.

[0159] See also Figure 7 , Figure 7 Schematic diagram 1 of a routing path provided in an embodiment of the present application, Figure 7 FIG. 7 shows a block 701, which includes a first computing device 702 and a first access switch 706. The first computing device 702 is provided with multiple network cards. Figure 7The network card 703 is shown in FIG. The first access switch 706 includes multiple ports, including a first port 704 .

[0160] From the preset correspondence between the candidate network cards and the candidate first ports, the first port 704 corresponding to the network card 703 is determined. After the first port 704 corresponding to the network card 703 is determined, the path between the network card 703 and the first port 704 can be used as the first path.

[0161] That is, the first path is a path between the network card 703 of the first computing device 702 and the first port 704 of the first access switch 706 . In other words, the first path is a path between the first computing device 702 and the first access switch 706 .

[0162] In step 1012, the aggregation switch corresponding to the second port is determined from the preset correspondence relationship between the candidate second ports and the candidate aggregation switches, and the second path is determined based on the second port and the aggregation switch corresponding to the second port.

[0163] In some embodiments, step 1012 may be implemented in the following manner: since there is a second port corresponding one-to-one to the first port, after determining the first port corresponding to the network card, the second port corresponding to the network card may be determined.

[0164] For example, in Figure 7 In the example, the first access switch 706 further includes a second port 705, wherein the first port 704 corresponds to the second port 705 one-to-one. Therefore, after determining the first port 704 corresponding to the network card 703, the second port 705 corresponding to the network card 703 can be determined.

[0165] After determining the second port corresponding to the network card, the aggregation switch corresponding to the second port can be determined from the preset correspondence between the candidate second ports and the candidate aggregation switches, wherein the preset correspondence between the candidate second ports and the candidate aggregation switches is confirmed by the topological connection relationship between the first access switch and the aggregation switch, wherein the topological connection relationship between the first access switch and the aggregation switch can refer to Figure 4 Description.

[0166] After determining the aggregation switch corresponding to the second port, the second path can be determined based on the second port and the aggregation switch corresponding to the second port. In some embodiments, when the number of aggregation sublayers is 1, the path between the second port and the aggregation switch corresponding to the second port can be used as the second path. In other words, the second path is the path between the second port and the aggregation switch corresponding to the second port. In other words, the second path is the path between the first access switch and the aggregation switch in one aggregation sublayer.

[0167] In some embodiments, the aggregation switch corresponding to the second port includes multiple first aggregation ports (i.e., downstream aggregation ports), and the first aggregation port corresponding to the second port can be determined from the pre-set correspondence between the candidate second ports and the candidate first aggregation ports, so that the path between the second port and the first aggregation port is used as the second path.

[0168] For example, in Figure 7 In the example, the aggregation switch 708 includes a first aggregation port 707. From the correspondence between the pre-set candidate second ports and the candidate first aggregation ports, the first aggregation port 707 corresponding to the second port 705 is determined, and the path between the second port 705 and the first aggregation port 707 can be used as the second path. In other words, the path between the first access switch 706 and the aggregation switch 708 can be used as the second path.

[0169] For the case where the number of convergence sublayers is an integer greater than 1, that is, when the number of convergence sublayers is multiple, the second ports correspond to multiple convergence switches, and any two convergence switches corresponding to the second ports belong to different convergence sublayers, and there is a pre-set topological connection relationship between the convergence switches corresponding to the multiple second ports.

[0170] In some embodiments, a sub-path can be determined based on the first access switch and aggregation switches belonging to different aggregation sublayers, and then the second path can be determined based on the sub-path. The number of sub-paths is consistent with the number of aggregation switches corresponding to the second ports. The aggregation switches corresponding to different second ports belong to different aggregation sublayers. It can be seen that the number of sub-paths is consistent with the number of aggregation sublayers.

[0171] The aggregation switches corresponding to the second port include a first aggregation switch and a second aggregation switch, the first aggregation switch and the second aggregation switch belong to different aggregation sublayers, the first access switch is connected to the second aggregation switch, and the second aggregation switch is connected to the first aggregation switch.

[0172] Of course, a third aggregation switch can be set according to actual use requirements, and the third aggregation switch and the first aggregation switch, and the third aggregation switch and the first aggregation switch belong to different aggregation sublayers. In this way, the second path is determined. In other words, the number of aggregation switches belonging to different aggregation sublayers can be set according to actual use requirements.

[0173] The following describes the method of "determining the second path based on the second port and the aggregation switch corresponding to the second port", and the path between the second port and the second aggregation switch can be used as the first sub-path.

[0174] In some embodiments, the second aggregation switch includes multiple first aggregation ports (i.e., downstream ports of the aggregation switch), and the first aggregation port corresponding to the second port can be determined from the pre-set correspondence between the candidate second ports and the candidate first aggregation ports, so that the path between the second port and the first aggregation port is used as the first sub-path. The first sub-path is the second path when the number of aggregation sub-layers is 1. For details, please refer to the description of determining the second path when the number of aggregation sub-layers is 1, which will not be repeated here.

[0175] The routing path between the second aggregation switch and the first aggregation switch is used as the second sub-path. In some embodiments, the second aggregation switch includes multiple first aggregation ports (i.e., downlink ports of the aggregation switch) and multiple second aggregation ports (i.e., uplink ports of the aggregation switch), wherein the first aggregation ports correspond one-to-one to the second aggregation ports, and the second aggregation port corresponding to the first aggregation port can be determined first.

[0176] The first aggregation switch includes multiple first aggregation ports. The first aggregation port corresponding to the second aggregation port can be determined from the pre-set correspondence between the candidate first aggregation ports and the candidate second aggregation ports, so that the path between the first aggregation port and the second aggregation port is used as the second sub-path, that is, the path between the first aggregation port of the first aggregation switch and the second aggregation port of the second aggregation switch is used as the second sub-path.

[0177] After obtaining the first subpath and the second subpath, the second path can be determined based on the first subpath and the second subpath. In some embodiments, there are corresponding ports between the first subpath and the second subpath, wherein the corresponding ports belong to the same switch, and the first subpath and the second subpath can be spliced ​​by the corresponding ports between the first subpath and the second subpath, so as to determine the second path.

[0178] See also Figure 8 , Figure 8 This is a schematic diagram of the routing path provided in the embodiment of the present application. Figure 8 An example is given to illustrate the method of determining the first path and the second path. Figure 8 FIG. 8 shows a block 801, which includes a first computing device 802 and a first access switch 806. The first computing device 802 is provided with multiple network cards. Figure 8 The network card 803 is shown in FIG. The first access switch 806 includes multiple ports, including a first port 804 .

[0179] From the preset correspondence between the candidate network cards and the candidate first ports, determine the first port 804 corresponding to the network card 803. After determining the first port 804 corresponding to the network card 803, the path between the network card 803 and the first port 804 can be used as the first path. In other words, the path between the network card 803 of the first computing device 802 and the first port 804 of the first access switch 806 is the first path.

[0180] The first access switch 806 also includes a second port 805 , wherein the first port 804 corresponds to the second port 805 one-to-one. After the first port 804 corresponding to the network card 803 is determined, the second port 805 corresponding to the network card 803 can be determined.

[0181] The second aggregation switch 808 includes a first aggregation port 807. The first aggregation port 807 corresponding to the second port 805 is determined from the pre-set correspondence between the candidate second ports and the candidate first aggregation ports. The path between the second port 805 and the first aggregation port 807 can be used as the first sub-path, that is, the path between the second port 805 of the first access switch 806 and the first aggregation port 807 of the second aggregation switch 808 can be used as the first sub-path.

[0182] The second aggregation switch 808 also includes a second aggregation port 809. The first aggregation port 807 corresponds to the second aggregation port 809 one by one, and the second aggregation port 809 corresponding to the first aggregation port 807 can be determined. The first aggregation switch 810 includes a first aggregation port 811. From the correspondence relationship between the pre-set candidate first aggregation ports and the candidate second aggregation ports, the first aggregation port 811 corresponding to the second aggregation port 809 is determined, so that the path between the second aggregation port 809 and the first aggregation port 811 is used as the second sub-path. In other words, the path between the second aggregation port 809 of the second aggregation switch 808 and the first aggregation port 811 of the first aggregation switch 810 can be used as the second sub-path.

[0183] The corresponding ports between the first sub-path and the second sub-path are spliced ​​to the first sub-path and the second sub-path. Figure 8 In the example, the first sub-path is a path between the second port 805 and the first aggregation port 807 , and the second sub-path is a path between the second aggregation port 809 and the first aggregation port 811 .

[0184] The first aggregation port 807 corresponds to the second aggregation port 809, and both the first aggregation port 807 and the second aggregation port 809 belong to the second aggregation switch 808. The first sub-path between the second port 805 and the first aggregation port 807 and the second sub-path between the second aggregation port 809 and the first aggregation port 811 can be spliced ​​to determine the second path. In the above manner, the accurate first path and the second path can be obtained.

[0185] In step 1013, a routing path is determined based on the first path and the second path.

[0186] In some embodiments, step 1013 can be implemented in the following manner: there are corresponding ports between the first path and the second path, and the corresponding ports belong to the same switch. The first path and the second path can be spliced ​​based on the corresponding ports between the first path and the second path, so that the routing path can be determined.

[0187] For example, in Figure 8 In the example, the second port 805 corresponds to the first port 804, and both the second port 805 and the first port 804 belong to the first access switch 806, so the first path and the second path can be spliced ​​to determine a routing path.

[0188] Through steps 1011 to 1013, the number of convergence sublayers in the convergence layer can be combined to adopt different methods to accurately determine the routing path, which is used for the second computing device to transmit data to the first computing device, thereby improving the accuracy of the transmitted data.

[0189] In some embodiments, the multi-layer network architecture further includes a core layer, the core layer includes one or more core sublayers, the core sublayer includes multiple core switches, that is, the core layer includes multiple core switches.

[0190] When the number of core layers is 1, a first path between the network card and the first access switch in the access layer can be obtained, and a second path between the first access switch and a convergence switch in at least one convergence sublayer can be obtained. The method for obtaining the first path and the second path can refer to the method for obtaining the first path and the second path. Figure 6 The description of step 1011 and step 1012 is not repeated here.

[0191] If the number of convergence sublayers is 1, the convergence switch in the second path is the convergence switch corresponding to the second port. If the number of convergence sublayers is multiple, the convergence switch in the second path is the first convergence switch, that is, the convergence sublayer to which the convergence switch in the second path belongs is adjacent to the core layer.

[0192] In some embodiments, the target core switch corresponding to the aggregation switch in the second path can be determined from the pre-set correspondence between the candidate aggregation switches and the candidate core switches, and then the path between the aggregation switch in the second path and the target core switch can be used as the third path; based on the first path, the second path and the third path, the routing path is determined.

[0193] In some embodiments, there are corresponding ports between the first path and the second path, and the corresponding ports belong to the same switch. The first path and the second path can be spliced ​​based on the corresponding ports between the first path and the second path. Correspondingly, there are corresponding ports between the second path and the third path, and the corresponding ports belong to the same aggregation switch. The second path and the third path can be spliced ​​based on the corresponding ports between the second path and the third path, so that the routing path can be determined.

[0194] In the case where there are multiple core layers, the first path and the second path can be obtained. The method of obtaining the first path and the second path can refer to the method for obtaining the first path and the second path. Figure 6 The description of step 1011 and step 1012 is not repeated here.

[0195] The core switch may include a first core switch and a second core switch, wherein the first core switch and the second core switch belong to different core sublayers, the first core switch and the second core switch are connected, and the second core switch is connected to the aggregation switch in the second path.

[0196] Of course, a third core switch can be set according to actual usage requirements, and the third core switch and the first core switch, and the third core switch and the second core switch belong to different convergence sublayers to determine the second path. In other words, the number of core switches belonging to different core sublayers can be set according to actual usage requirements.

[0197] In some embodiments, the target core switch corresponding to the aggregation switch in the second path can be determined from the pre-set correspondence between the candidate aggregation switches and the candidate core switches, and the target core switch is the second core switch.

[0198] The path between the aggregation switch and the second core switch in the second path can be used as the fifth sub-path, and the path between the second core switch and the first core switch can be used as the sixth sub-path. Then, the third path can be determined based on the fifth sub-path and the sixth sub-path. The method for determining the third path can be equivalent to the method for determining the second path, which will not be described in detail here. Then, the routing path can be determined based on the first path, the second path, and the third path.

[0199] The present application can combine the number of convergence sublayers in the convergence layer and the number of core sublayers in the core layer, and adopt different methods to accurately determine the routing path, which is used for the second computing device to transmit data to the first computing device, thereby improving the accuracy of the transmitted data.

[0200] In step 102, the routing path is sent to a second access switch in the access layer.

[0201] In some embodiments, step 102 can be implemented in the following manner: the first access switch belongs to the first block, see Fig. 9 , Fig. 9 This is a flow chart of the data transmission method provided in the embodiment of the present application. Fig. 9 The steps shown are Figure 5 Step 102 is shown for explanation.

[0202] In step 1021, according to the first identifier of the first access switch, a second identifier matching the first identifier is searched from identifiers of access switches belonging to the second block.

[0203] In some embodiments, the first identifier is a first number, the number of access switches belonging to the second block is multiple, and the identifier of the access switch belonging to the second block is a second number. Fig.10 , Fig.10 This is a schematic diagram of the data transmission method provided in the embodiment of the present application. Figure 4 , the following combination Fig.10 The steps shown are Fig. 9 Step 1021 is shown for explanation.

[0204] In step 10211A, for each second number, the difference between the first number and the second number is determined.

[0205] In order to enable network cards with the same addresses corresponding to computing devices belonging to different blocks to transmit data through the same switch, thereby improving the efficiency of data transmission, the number of network cards included in each block is consistent, and for each block, an order can be set for the network cards. According to the order of the network cards, an order can be set for the access switches in the block, and the first number and the second number can be set according to the corresponding order of the access switches.

[0206] The first number is used to identify the first access switch in the first block, and the first number is used to uniquely identify the first access switch. For example, the first block includes the first access switch and the access switch 1, and the first number of the first access switch is 1. Each access switch in the second block has a second number, and the second number corresponds to the access switch in the second block one by one. In order to determine the second number, the difference between the first number and each second number can be determined first.

[0207] In step 10212A, if the quotient of the difference and the preset third number is the target value, the second number is used as the second identifier that matches the first identifier.

[0208] In some embodiments, the third number is the number of access switches in the block (i.e., the first block) to which the first access switch corresponding to the access layer belongs. The number of access switches in the first block can be determined based on the number of ports of the access switch and the number of network cards in the first block.

[0209] The following first describes a method for setting the target value. The target value in the embodiment of the present application is pre-set, wherein the target value is related to a method for setting the first number and the second number. For access switches at the same address in a block, if the first number corresponding to the first access switch is consistent with the second number of the access switch at the corresponding address in the second block, the target value is 0.

[0210] If the first number corresponding to the first access switch is inconsistent with the second number of the access switch of the corresponding address in the second block, and the target difference between the first number and the second number corresponding to the address is consistent with the target difference between the number and the second number corresponding to other addresses, then the target value includes the absolute value and remainder of the integer corresponding to the quotient of the target difference and the third number.

[0211] If the quotient is not the target value, it means that the second number cannot be used as the second identifier that matches the first identifier. If the quotient is the target value, it means that the second number can be used as the second identifier that matches the first identifier.

[0212] For the case where the target value is 0, if the quotient is not the target value, it means that the remainder of the first number divided by the third number is different from the remainder of the second number divided by the third number, which means that the second number cannot be used as a second identifier that matches the first identifier.

[0213] If the quotient is the target value, it means that the remainder of the first number divided by the third number is the same as the remainder of the second number divided by the third number, that is, the first number and the second number are congruent modulo N, where N is the quotient of the difference and the third number, which further means that the second number can be used as a second identifier that matches the first identifier.

[0214] For example, the number of access switches in the first block is 2, the first block includes the first access switch, the second block includes access switch 2 and access switch 3, the first digit of the first access switch is 3, the second digit of access switch 2 is 3, and the second digit of access switch 3 is 4.

[0215] The difference between the first digit and the second digit of access switch 2 is calculated. The difference is 0, the number of access switches is 2, and the quotient of the difference and the third digit (the number of access switches) is 0. Then the second digit (3) can be used as the second identifier that matches the first identifier.

[0216] The difference between the first digit and the second digit of access switch 3 is calculated. The difference is -1. The number of access switches is 2. The quotient of the difference and the third digit (the number of access switches) is not 0. This indicates that the second digit (4) cannot be used as the second identifier that matches the first identifier.

[0217] For another example, the target value includes an integer absolute value of 2 and a remainder of 2, the number of access switches in the first block is 2, the first block includes a first access switch, and the second block includes access switch 4 and access switch 5.

[0218] The first digit of the first access switch is 3, the second digit of access switch 4 is 13, and the second digit of access switch 5 is 14. The difference between the first digit and the second digit of access switch 4 is calculated, and the difference is -10. The number of access switches is 2. The quotient of the difference and the third digit (the number of access switches) is 2 more than 2, which is the target value. The second digit (13) can be used as the second identifier that matches the first identifier.

[0219] The difference between the first digit and the second digit of access switch 8 is calculated. The difference is -11. The number of access switches is 2. The quotient of the difference and the third digit (the number of access switches) is 2 more than 3. The quotient is not the target value, indicating that the second digit (14) cannot be used as the second identifier that matches the first identifier.

[0220] Through steps 10211A-10212A, the second identifier matching the first identifier can be accurately found, and the second identifier is used to determine the second access switch, which is equivalent to accurately determining the second access switch.

[0221] In some embodiments, see Fig.11 , Fig.11 This is a schematic diagram of the data transmission method provided in the embodiment of the present application. Figure 5 , the following combination Fig.11 The steps shown are Fig. 9 Step 1021 is shown for explanation.

[0222] In step 10211B, according to the first identifier of the first access switch, a target identifier corresponding to the first identifier is determined from a preset correspondence relationship between candidate first identifiers and candidate target identifiers.

[0223] In some embodiments, in order to enable network cards with the same address corresponding to computing devices belonging to different blocks to transmit data through the same switch, thereby improving the efficiency of data transmission, the number of network cards included in each block is consistent. For two different blocks, the network cards with the same address can be marked, and then a corresponding relationship is set between the marks of the switches connected to the network cards with the same address.

[0224] Step 10211B may be implemented in the following manner: according to the first identifier of the first access switch, a target identifier corresponding to the first identifier is determined from a preset correspondence relationship between candidate first identifiers and candidate target identifiers.

[0225] The first identifier may be an identifier set by a user according to actual usage requirements. In some embodiments, the first identifier may be the name of the first access switch. Accordingly, the correspondence between the pre-set candidate first identifier and the candidate target identifier is the correspondence between the name of the pre-set candidate access switch in the first block and the target name of the candidate access switch, that is, the target identifier is the target name.

[0226] In some embodiments, the first identifier may be a string of the first access switch. Accordingly, the correspondence between the pre-set candidate first identifier and the candidate target identifier is the correspondence between the string of the candidate access switch in the pre-set first block and the target string of the candidate access switch, that is, the target identifier is the target string.

[0227] In step 10212B, an identifier consistent with the target identifier is searched from the identifiers of the access switches belonging to the second block as a second identifier matching the first identifier.

[0228] In some embodiments, in step 10212B, after determining the target identifier corresponding to the first identifier, an identifier consistent with the target identifier can be searched from the identifiers of the access switches belonging to the second block as a second identifier that matches the first identifier. Through steps 10211B-10212B, the target identifier that matches the first identifier can be accurately found, and the target identifier is used to determine the second access switch, which is equivalent to accurately determining the second access switch.

[0229] In step 1022, the access switch indicated by the second identifier is used as the second access switch, and the routing path is sent to the second access switch.

[0230] In some embodiments, the second access switch can forward data sent by the second computing device and whose destination address corresponds to the network card to the network card based on the routing path, wherein the destination address is the address of the network card in the first computing device. The second computing device is provided with multiple network cards. Specifically, the second access switch can forward data sent by the network card of the second computing device and whose destination address corresponds to the network card to the network card based on the routing path.

[0231] In some embodiments, the second access switch can receive data of a network card corresponding to a destination address sent by a second computing device. The destination address may include an identifier of the network card. The identifier of the network card may be the name of the network card, a string that uniquely identifies the network card, etc. The identifier of the network card may also be composed of the name of the network card and the identifier of the computing device where the network card is located.

[0232] The second access switch can select a routing path corresponding to the identifier of the network card from the pre-received routing paths according to the identifier of the network card, and the routing path includes a path between the aggregation switch and the first access switch. In order to forward the data of the network card through the routing path, the data of the network card corresponding to the destination address sent by the second computing device can be sent to the aggregation switch according to the connection relationship between the second access switch and the aggregation switch in the routing path.

[0233] Furthermore, the aggregation switch can send the data of the network card corresponding to the destination address sent by the second computing device to the first access switch according to the second path, and the first access switch can send the data of the network card corresponding to the destination address sent by the second computing device to the network card of the first computing device according to the first path.

[0234] In order to facilitate understanding of the data transmission method provided in the embodiment of the present application, see Fig.12 , Fig.12 Schematic diagram 3 of the routing path provided in the embodiment of the present application. Fig.12 The first block 1210 and the second block 1220 are shown in FIG. The first block 1210 includes a first computing device 1201 and a first access switch 1204. The first computing device 1201 is provided with multiple network cards. Fig.12 The first network card 1202 is shown in FIG. The first access switch 1204 includes a plurality of ports, specifically including a first port 1203 and a second port 1205, wherein the first port 1203 and the second port 1205 correspond to each other one by one.

[0235] The first network card 1202 is connected to the first port 1203, and the first port 1203 corresponding to the first network card 1202 is determined from the preset correspondence between the candidate network cards and the candidate first ports. After the first port 1203 corresponding to the first network card 1202 is determined, the path between the first network card 1202 and the first port 1203 can be used as the first path.

[0236] That is, the path between the first network card 1202 of the first computing device 1201 and the first port 1203 of the first access switch 1204 can be used as the first path. After determining the first port 1203 corresponding to the first network card 1202, the second port 1205 corresponding to the first network card 1202 can be determined.

[0237] The aggregation switch 1 includes a first aggregation port 1206. From the pre-set correspondence between the candidate second ports and the candidate first aggregation ports, the first aggregation port 1206 corresponding to the second port 1205 is determined, and the path between the second port 1205 and the first aggregation port 1206 can be used as the second path. In other words, the path between the second port 1205 of the first access switch 1204 and the first aggregation port 1206 of the aggregation switch 1 can be used as the second path.

[0238] After obtaining the first path and the second path, Fig.12 In the example, the second port 1205 corresponds to the first port 1203, and both the second port 1205 and the first port 1203 belong to the first access switch 1204, so the first path and the second path can be spliced ​​to determine the second path. In the above manner, the first path and the second path can be accurately determined, and then the routing path can be accurately determined.

[0239] In some embodiments, the first identifier of the first access switch 1204 is 1204, and a correspondence between 1204 and 1212 (target identifier) ​​is pre-set, so the target identifier (1212) corresponding to 1204 can be determined, and then the access switch corresponding to 1212 in the second block 1220 can be used as the second access switch 1212.

[0240] The second access switch 1212 and the second computing device 1207 both belong to the second block 1220. The second computing device 1207 is provided with multiple network cards. Fig.12 The second network card 1213 is shown in the figure. The second access switch 1212 includes multiple ports, specifically including a first port 1211 and a second port 1209, wherein the first port 1211 and the second port 1209 correspond to each other.

[0241] The first port 1211 corresponding to the second network card 1213 is determined from the pre-set correspondence between the candidate network cards and the candidate first ports. The address of the first network card 1202 in the first computing device 1201 is the destination address. The second computing device 1207 can send data corresponding to the first network card 1202 at the destination address to the second access switch 1212.

[0242] That is, the second network card 1213 can send the data of the first network card 1202 to the second access switch 1212 through the connection relationship between the second network card 1213 and the first port 1211 , and the first port 1211 corresponds to the second port 1209 .

[0243] The second access switch 1212 can send the data of the first network card 1202 to the aggregation switch 1 through the connection relationship between the second port 1209 and the first aggregation port 1206 , and further, the data of the first network card 1202 can be sent to the first access switch 1204 through the second path.

[0244] The first access switch 1204 can send the data of the first network card 1202 to the first network card 1202 through the first path. In this way, the data with the destination address corresponding to the first network card 1202 sent by the second computing device 1207 can be forwarded to the first network card 1202 based on the routing path.

[0245] In the data transmission method provided in the embodiment of the present application, there is a one-to-one corresponding routing path for any network card of the first computing device, and the second computing device can send data to any network card of the first computing device based on the routing path. Compared with the method of randomly determining the routing path for data transmission, the present application uses the routing path corresponding to the network card for data transmission, realizes load balancing of the switch for data transmission between the first computing device and the second computing device, and increases the data transmission rate. That is, the data transmission method provided in the embodiment of the present application can improve the efficiency of data transmission and can solve the above-mentioned technical problems 1 and 3.

[0246] In some embodiments, for the scenario of training artificial intelligence models, it is necessary to transmit a large amount of data between computing devices. Since the data transmission method provided in the embodiment of the present application adopts the routing path corresponding to the network card for data transmission, the load balancing of the switch for data transmission between the first computing device and the second computing device is achieved, and the data transmission rate is increased, that is, the data transmission method provided in the embodiment of the present application can improve the efficiency of data transmission, and thus can improve the efficiency of training artificial intelligence models. It can solve the above-mentioned technical problem 2.

[0247] In the data transmission method provided in the embodiment of the present application, a routing path can be sent to an access switch through a server installed with an SDN controller, which is equivalent to pre-planning a routing path for data transmission for a switch that needs to perform data transmission, thereby reducing routing path conflicts during data transmission and improving data transmission efficiency.

[0248] In some embodiments, Figure 5 After step 102, the first operation information of the first access switch may be obtained, and the second operation information of the aggregation switch may be obtained. In some embodiments, the operation information of each access switch in the access layer may be obtained.

[0249] Among them, the operation information of each access switch in the access layer can be obtained, and the operation information includes the first operation information. The operation information of each aggregation switch in the aggregation layer can also be obtained, wherein the operation information of each aggregation switch in the aggregation layer includes the operation information of the aggregation switches in each aggregation sublayer, and the operation information of each aggregation switch in the aggregation layer includes the second operation information of the aggregation switch.

[0250] The first operation information is explained below. The first operation information includes first port information of the first access switch. The number of first port information may include one or more. The first port information is the first link information between the ports connected to the port. Specifically, the first link information may be link information between the first port and the network card and link information between the second port and the first aggregation port. The first link information may include link status information, link bandwidth information, link delay information, etc.

[0251] The link status information may be the working status of the link formed by the multiple ports, and the working status may be active, inactive, congested, etc. The link status information may also be information indicating whether the multiple ports are connected.

[0252] The bandwidth information of the link may be the data transmission rate of the link. The delay information of the link may be the time required for transmission from one port to another port in the link, wherein the state information of the link may be determined based on the bandwidth information of the link and the delay information of the link.

[0253] The first operation information may further include first system information of the first access switch. The first system information may include the temperature of the first access switch, the operation time of the first access switch, the packet loss rate of the first access switch, etc., which may be specifically set according to actual usage requirements.

[0254] The operation information of the access switch in the access layer is equivalent to the first operation information. The second operation information may include the second port information of the aggregation switch and the second system information of the aggregation switch. The second port information may include the second link information between the ports connected to the ports. The second link information may include the status information of the link, the bandwidth information of the link, the delay information of the link, etc.

[0255] The second system information includes the temperature of the aggregation switch, the running time of the aggregation switch, the number of ports of the aggregation switch, etc., and can be equivalently replaced with the description of the first port information, which will not be repeated here.

[0256] After the first operation information and the second operation information are acquired, it can be determined whether the first operation information indicates that an abnormality exists in the routing path, and it can be determined whether the second operation information indicates that an abnormality exists in the routing path.

[0257] Among them, when the first operation information and / or the second operation information represent that there is an abnormality in the routing path, it means that the operation information represents that the routing path is operating abnormally, wherein the operation information includes the first operation information and / or the second operation information, and when the first operation information and / or the second operation information represent that there is no abnormality in the routing path, it means that the operation information represents that the routing path is operating normally, which is explained below with reference to specific examples.

[0258] In some embodiments, for the first operation information and the second operation information, when the link status information indicates that the working state of the link is congested, it means that there is an abnormality in the routing path, that is, the routing path is operating abnormally. When the link status information indicates that the working state of the link is active, it means that there is no abnormality in the routing path, that is, the routing path is operating normally.

[0259] When the link status information indicates that multiple ports are not connected, it means that the network line is damaged, that is, the line is faulty, which in turn indicates that there is an abnormality in the routing path, that is, the routing path is operating abnormally. When the link status information indicates that multiple ports are connected and the working state is not congested, it means that the network line is not damaged, that is, there is no fault in the line, which in turn indicates that there is no abnormality in the routing path, that is, the routing path is operating normally.

[0260] In the case where the bandwidth information of the link indicates that the data transmission rate is less than the preset first transmission rate threshold, it means that there is an abnormality in the routing path, that is, the routing path is operating abnormally. In the case where the bandwidth information of the link indicates that the data transmission rate is greater than or equal to the preset first transmission rate threshold, it means that there is no abnormality in the routing path, that is, the routing path is operating normally.

[0261] If the delay information of the link indicates that the time required for transmission from one port to another port in the link is greater than a preset first time threshold, it indicates that there is an abnormality in the routing path, that is, the routing path is operating abnormally. If the delay information of the link indicates that the time required for transmission from one port to another port in the link is less than or equal to the preset first time threshold, it indicates that there is no abnormality in the routing path, that is, the routing path is operating normally.

[0262] For the first system information, when the temperature of the first access switch is greater than a preset temperature threshold, it indicates that there is an abnormality in the first access switch, that is, there is an abnormality in the routing path, that is, the routing path is operating abnormally. When the temperature of the first access switch is less than or equal to the preset temperature threshold, it indicates that there is no abnormality in the first access switch, that is, there is no abnormality in the routing path, that is, the routing path is operating normally.

[0263] When the operation time of the first access switch is greater than the preset operation time threshold, it indicates that there is an abnormality in the routing path, that is, the routing path is operating abnormally. When the operation time of the first access switch is less than or equal to the preset operation time threshold, it indicates that there is no abnormality in the routing path, that is, the routing path is operating normally.

[0264] When the packet loss rate of the first access switch is greater than the preset packet loss rate threshold, it indicates that there is an abnormality in the routing path, that is, the routing path is operating abnormally. When the packet loss rate of the first access switch is less than or equal to the preset packet loss rate threshold, it indicates that there is no abnormality in the routing path, that is, the routing path is operating normally.

[0265] If the first operation information indicates that there is no abnormality in the routing path, and the second operation information indicates that there is no abnormality in the routing path, that is, if the first operation information indicates that the routing path is running normally, and the second operation information indicates that the routing path is running normally, then the routing path may not be changed, that is, the second access switch still forwards the data of the network card corresponding to the destination address sent by the second computing device to the network card based on the routing path.

[0266] If at least one of the first operation information and the second operation information represents an abnormality in the routing path, that is, if the first operation information represents an abnormality in the routing path, and / or the second operation information represents an abnormality in the routing path (that is, the operation information represents abnormal operation of the routing path), then a new routing path for transmitting data to the network card is obtained, and the new routing path is sent to the second access switch in the access layer.

[0267] The second access switch is further used to replace the routing path with a new routing path, and forward the data of the network card corresponding to the destination address sent by the second computing device to the network card based on the new routing path. It should be noted that the "new routing path" in the embodiment of the present application is only used to distinguish from the "routing path", and does not mean to re-establish the routing path.

[0268] In some embodiments, a new routing path carrying a routing priority may be sent to a second access switch in the access layer, wherein the routing priority of the new routing path is higher than the routing priority of the routing path. The second access switch may receive the new routing path having a higher routing priority than the routing priority of the routing path.

[0269] That is, the second access switch may receive two different routing paths of routing priorities, specifically the new routing path and the routing path. In some embodiments, the second access switch is further configured to replace the routing path with the new routing path based on the routing priority of the new routing path.

[0270] For example, the routing priority of routing path 3 can be identified by 400, and a new routing path (routing path 4) with an identifier of 500 can be sent to the second access switch. The access switch can compare the routing priorities of routing path 3 and routing path 4. Since 500 is greater than 400, routing path 3 can be replaced with the new routing path (routing path 4).

[0271] In some embodiments, a new routing path carrying a preset replacement identifier can be sent to a second access switch in the access layer, where the replacement identifier can be set according to the actual usage requirements of the user. For example, the replacement identifier can include the name of the routing path, the name of the switch in the routing path, the name of the network card in the routing path, etc., which are all reasonable.

[0272] That is, the second access switch may receive the routing path and the new routing path carrying the replacement identifier. In some embodiments, the second access switch is further configured to replace the routing path with the new routing path based on the replacement identifier.

[0273] In some embodiments, see Fig.13 , Fig.13 This is a schematic diagram of the data transmission method provided in the embodiment of the present application. Figure 6 , the following combination Fig.13 The steps shown illustrate a method for obtaining a new routing path for transmitting data to the network card.

[0274] In step 1301, a third access switch is determined from access switches included in the block to which the first access switch belongs.

[0275] In some embodiments, the first operation information indicates that there is an abnormality in the routing path, which may specifically include one or more of the following: the first abnormality: there is an abnormality in the first access switch. The second abnormality: there is an abnormality in the connection between the first access switch and the network card. The third abnormality: there is an abnormality in the connection between the first access switch and the aggregation switch.

[0276] In the case where the first operation information indicates that there is an abnormality in the routing path, that is, in the case where the routing path operates abnormally, a third access switch can be determined from the access switches included in the block to which the first access switch belongs. In some embodiments, in the second and third cases above, the third access switch can be the first access switch.

[0277] For example, see Fig.14 , Fig.14 This is a schematic diagram of the routing path provided in the embodiment of the present application. Figure 4 . Fig.14 Undertake Fig.12 When the first operation information of the first access switch 1204 indicates that there is an abnormality in the routing path, specifically, when the second situation and / or the third situation mentioned above exists, the first access switch 1204 can be used as the third access switch.

[0278] In some embodiments, for the first case above, the third access switch is not the first access switch. For example, the block to which the first access switch belongs includes access switch a, access switch b, and access switch c, wherein access switch a is the first access switch. For the first case above, the third access switch may be access switch b or access switch c.

[0279] In some embodiments, the third access switch may be determined based on the operation information of the access switch. In some embodiments, the access switch having the largest data transmission rate represented by the bandwidth information of the link in the operation information may be selected as the third access switch.

[0280] In some embodiments, any access switch whose data transmission rate represented by the bandwidth information of the link in the operation information is less than a second transmission rate threshold can be used as the third access switch, where the second transmission rate threshold is greater than the first transmission rate threshold.

[0281] In some embodiments, the access switch whose link delay information in the operation information indicates that the time required for transmission from one port in the link to another port is the shortest can be used as the third access switch. In some embodiments, the access switch whose link delay information in the operation information indicates that the time required for transmission from one port in the link to another port is less than a preset second time threshold can be used as the third access switch. The second time threshold is less than the first time threshold. Of course, the third access switch can also be determined based on other operation information, which is not specifically limited here.

[0282] In step 1302, a target network card corresponding to the third access switch is determined from a preset correspondence relationship between candidate network cards and candidate access switches.

[0283] After the third access switch is determined, the target network card corresponding to the third access switch can be determined from the preset correspondence between the candidate network cards and the candidate access switches. The preset correspondence between the candidate network cards and the candidate access switches is described below.

[0284] For a computing device and an access switch in any block, the network card of the computing device can be connected to a port of the access switch via a network cable, wherein there is a one-to-one correspondence between the network card and the interface.

[0285] For example, see Fig.15 , Fig.15 1 is a schematic diagram of the connection relationship between the computing device and the access switch provided in the embodiment of the present application. Block 1501 includes a first computing device 1502 and four access switches. Fig.15 1, 2, 3 and 4 are shown in FIG. 1 . The first computing device 1502 is provided with 16 network cards. Fig.15 The first network card 1503 and the second network card 1506 are shown in FIG.

[0286] Each of the four access switches includes four first ports, which may also be referred to as downlink ports. Fig.15 Only the first port 1504 of the access switch 1 and the first port 1507 of the access switch 4 are shown. Accordingly, each of the four access switches includes four second ports, which may also be referred to as uplink ports.

[0287] For each network card, the network card can be connected to the 16 first ports corresponding to the four access switches, and the network card and the first port correspond one to one. Fig.15Only the first network card 1503 is shown to be connected to the first port 1504 of the access switch 1, and the second network card 1506 is shown to be connected to the first port 1507 of the access switch 4. The other network cards are equivalent to the first network card 1503 and are not described in detail here.

[0288] That is, the corresponding relationship between the candidate network card and the candidate first port can be determined through the connection relationship between the network card and the first port, which is equivalent to obtaining the corresponding relationship between the candidate network card and the candidate access switch. Then, the target network card corresponding to the third access switch can be determined from the corresponding relationship between the candidate network card and the candidate access switch.

[0289] For example, in Fig.15 In the example, the third access switch may be access switch 4. According to the corresponding relationship between the second network card 1506 and the access switch 4, the target network card may be determined to be the second network card 1506. In this way, the target network card may be accurately determined.

[0290] In step 1303, the path between the target network card and the third access switch is used as a new first path.

[0291] In some embodiments, after the target network card and the third access switch are determined, the path between the target network card and the third access switch can be used as a new first path. The "new first path" in the embodiments of the present application is only used to distinguish from the "first path" and does not mean to re-establish the first path.

[0292] The target network card is connected to the new first port in the third access switch, so the path between the target network card and the new first port can be used as the new first path. In this way, the accurate new first path can be determined. The "new first port" in the embodiment of the present application is only used to distinguish it from the "first port", and does not mean to recreate the first port.

[0293] In step 1304, the path between the third access switch and the aggregation switch is used as a new second path.

[0294] In some embodiments, the path between the second port of the third access switch and the aggregation interface of the aggregation switch can be used as a new second path, wherein the "new second path" in the embodiments of the present application is only used to distinguish from the "second path" and does not mean to re-establish the second path.

[0295] If there are multiple aggregation sublayers, the path between the second port of the third access switch and the aggregation interface of the aggregation switch can be used as a new first subpath, and the path between the aggregation interface of the aggregation switch and the aggregation interface of the aggregation switch in another aggregation sublayer can be used as a new second subpath.

[0296] Then, based on the new first subpath and the new second subpath, a new second path is determined. The "new first subpath" in the embodiment of the present application is only used to distinguish it from the "first subpath", and does not mean to re-establish the first subpath. Accordingly, the "new second subpath" is only used to distinguish it from the "second subpath", and does not mean to re-establish the second subpath. Specifically, the method of determining the routing path can be equivalently replaced, which will not be described in detail here. In this way, an accurate new second path can be determined.

[0297] In step 1305, a new routing path is determined based on the new first path and the new second path. Step 1305 is equivalent to step 1013, and the details can be referred to the description of step 1013, and the description of step 1013 is equivalently replaced, and will not be repeated here.

[0298] In some embodiments, the target network card is used to forward the network card data to the network card after receiving the network card data sent by the second access switch based on the new routing path, and the network card data corresponds to the destination address sent by the second computing device.

[0299] In some embodiments, any method in the prior art that can realize data transmission between multiple network cards of the same computing device can be used to realize that the target network card forwards the network card data to the network card. For example, the Remote Direct Memory Access (RDMA) method can be used to realize that the target network card forwards the network card data to the network card. The remote direct memory access method can improve the throughput of the computing device and reduce the network communication delay of the computing device. For another example, Peripheral Component Interconnect Express (PCle) can also be used to achieve it.

[0300] In some embodiments, Fig.13 In the manner of obtaining a new routing path for transmitting data to a network card, in some embodiments, the second access switch can receive data of the network card corresponding to the destination address sent by the second computing device, and then can send the data of the network card corresponding to the destination address sent by the second computing device to the aggregation switch according to the connection relationship between the second access switch and the aggregation switch. The aggregation switch is the aggregation switch corresponding to the new second path.

[0301] The aggregation switch can send the data of the network card to the third access switch based on the new second path, and the third access switch can send the data of the network card to the network card. In this way, the data of the network card corresponding to the destination address sent by the second computing device can be forwarded to the network card based on the new routing path.

[0302] For example, see Fig.14 The second network card 1213 of the second computing device 1207 can send the data of the first network card 1202 corresponding to the destination address to the third network card 1405 first, and then the third network card 1405 sends the data of the first network card 1202 to the second access switch 1212 based on the connection relationship with the first port 1406 in the second access switch 1212.

[0303] The second access switch 1212 can send the data of the first network card 1202 to the aggregation switch 2 through the connection relationship between the second port 1407 and the first aggregation port 1404 in the aggregation switch 2. Fig.14 In the figure, the new first path is the path between the fourth network card 1401 of the first computing device 1201 and the first port 1402 of the first access switch 1204, and the new second path is the path between the second port 1403 of the first access switch 1204 and the first aggregation port 1404 in the aggregation switch 2.

[0304] The second aggregation switch can send the data of the first network card 1202 to the first access switch 1204 according to the new second path, the first access switch 1204 can send the data of the first network card 1202 to the fourth network card 1401 according to the new first path, and the fourth network card 1401 can send the data of the first network card 1202 to the first network card 1202. In this way, it is possible to forward the data corresponding to the network card of the destination address sent by the second computing device to the network card based on the new routing path.

[0305] It can be seen that in the data transmission method provided in the embodiment of the present application, when there is an abnormality in the routing path, the routing path can be replaced with a new routing path, thereby ensuring the stability of data transmission, and avoiding the problems of low efficiency of data transmission between computing devices and reduced communication bandwidth due to congestion in the routing path. Therefore, while ensuring the stability of data transmission, the efficiency of data transmission can be improved, and the communication bandwidth can be increased, which can solve the above-mentioned technical problem 4.

[0306] In some embodiments, see Fig.16 , Fig.16 This is a schematic diagram of the data transmission method provided in the embodiment of the present application. Figure 7 , the following combination Fig.16 The steps shown illustrate a method for obtaining a new routing path for transmitting data to the network card.

[0307] In step 1601, when the abnormality of the routing path is caused by a failure of the aggregation switch or a failure of the line between the first access switch and the aggregation switch, a third aggregation switch is determined from the aggregation switches included in the aggregation sublayer to which the aggregation switch belongs.

[0308] For a situation where the second operation information represents that there is an abnormality in the routing path, that is, for at least one of a situation where the abnormality in the routing path is caused by a failure of an aggregation switch, a situation where the abnormality in the routing path is caused by a line failure between the first access switch and the aggregation switch (the first aggregation switch), and a situation where the abnormality in the routing path is caused by a line failure between the first aggregation switch and the second aggregation switch, a third aggregation switch can be determined from the aggregation switches included in the aggregation sublayer to which the aggregation switch belongs.

[0309] For example, see Fig.17 , Fig.17 This is a schematic diagram of the routing path provided in the embodiment of the present application. Figure 5 , Fig.17 Undertake Fig.12 The aggregation sublayer also includes an aggregation switch 3 located in the same aggregation sublayer as the aggregation switch 1. In the case where the abnormality of the routing path is caused by a failure of the aggregation switch 1, and / or the abnormality of the routing path is caused by a line failure between the first access switch 1204 and the aggregation switch, a third aggregation switch can be determined from the aggregation switches included in the aggregation sublayer to which the aggregation switch 1 belongs, wherein the third aggregation switch is the aggregation switch 3.

[0310] In step 1602, a fourth path is determined based on the first access switch and the third aggregation switch.

[0311] In some embodiments, the number of convergence sublayers is 1, and the path between the second port of the first access switch and the convergence port of the third convergence switch can be determined as the fourth path. Fig.17 , the path between the second port 1703 of the first access switch 1204 and the first aggregation port 1702 of the aggregation switch three (the third aggregation switch) can be used as the fourth path.

[0312] In some embodiments, there are multiple convergence sublayers, and the path between the first access switch and the third convergence switch can be used as the third subpath. For details, please refer to the description of determining the fourth path when the number of convergence sublayers is 1, which will not be repeated here.

[0313] Based on the preset correspondence between the candidate third aggregation switch and the candidate fourth aggregation switch, a fourth aggregation switch corresponding to the third aggregation switch is determined, and the third aggregation switch and the fourth aggregation switch belong to different aggregation sublayers.

[0314] The path between the third aggregation switch and the fourth aggregation switch is taken as the fourth sub-path. Specifically, the path between the aggregation port of the third aggregation switch and the aggregation port of the fourth aggregation switch can be taken as the fourth sub-path. Based on the third sub-path and the fourth sub-path, the fourth path is determined. The method for determining the fourth path can refer to the description of determining the second path, which will not be repeated here.

[0315] In step 1603, the second path in the routing path is replaced with the fourth path to obtain a new routing path. In other words, the new routing path can be determined by the first path and the fourth path, and in this way, an accurate new routing path can be obtained.

[0316] In some embodiments, Fig.16 In the manner of obtaining a new routing path for transmitting data to a network card, in some embodiments, the second access switch can receive data of the network card corresponding to the destination address sent by the second computing device, and then can send the data of the network card corresponding to the destination address sent by the second computing device to the aggregation switch according to the connection relationship between the second access switch and the aggregation switch. The aggregation switch is the aggregation switch corresponding to the new second path.

[0317] The aggregation switch can send the data of the network card to the first access switch based on the new second path, and the first access switch can send the data of the network card to the network card. In this way, the data of the network card corresponding to the destination address sent by the second computing device can be forwarded to the network card based on the new routing path.

[0318] For example, see Fig.17 , the second computing device 1207 can send the data of the first network card 1202 corresponding to the destination address to the second access switch 1212. The second access switch 1212 can send the data of the first network card 1202 to the aggregation switch three through the connection relationship between the second port 1704 and the first aggregation port 1702 in the aggregation switch three.

[0319] exist Fig.17 In the example, the fourth path is a path between the first aggregation port 1702 of the aggregation switch 3 and the first port 1703 of the first access switch 1204. The aggregation switch 3 can send the data of the first network card 1202 to the first access switch 1204 according to the fourth path, and the first access switch 1204 can send the data of the first network card 1202 to the first network card 1202 according to the first path. In this way, it is possible to forward the data corresponding to the network card of the destination address sent by the second computing device to the network card based on the new routing path.

[0320] It can be seen that in the data transmission method provided in the embodiment of the present application, when there is an abnormality in the routing path, the routing path can be replaced with a new routing path, thereby ensuring the stability of data transmission, and avoiding the problems of low efficiency of data transmission between computing devices and reduced communication bandwidth due to congestion in the routing path. Therefore, while ensuring the stability of data transmission, the efficiency of data transmission can be improved, and the communication bandwidth can be increased, which can solve the above-mentioned technical problem 4.

[0321] In some embodiments, the present application can periodically execute the step of "obtaining first operating information of the first access switch and obtaining second operating information of the aggregation switch", that is, the first operating information and the second operating information can be periodically obtained, so as to determine whether the operating information has changed from characterizing the existence of an abnormality in the routing path to characterizing the absence of an abnormality in the routing path, that is, to determine whether the operating information has changed from characterizing the abnormal operation of the routing path to the normal operation of the routing path, wherein the operating information corresponds to the first operating information and / or the second operating information.

[0322] If the operation information does not change from characterizing abnormal operation of the routing path to normal operation of the routing path, that is, the operation information still characterizes abnormal operation of the routing path, the second access switch can forward the data of the network card corresponding to the destination address sent by the second computing device to the network card based on the new routing path.

[0323] If the operation information changes from indicating abnormal operation of the routing path to normal operation of the routing path, a new routing path deletion instruction is sent to the second access switch in the access layer, so that the second access switch deletes the new routing path. In this way, the new routing path can be deleted after the routing path is normal, ensuring load balancing of the switch for data transmission between the first computing device and the second computing device, and increasing the rate of data transmission, that is, the data transmission method provided in the embodiment of the present application can improve the efficiency of data transmission.

[0324] The second data transmission method provided in the embodiment of the present application is described below. As mentioned above, the second electronic device that implements the data transmission method provided in the embodiment of the present application can be a switch, specifically, an access switch of the access layer.

[0325] See also Fig.18 , Fig.18 This is a schematic diagram of the data transmission method provided in the embodiment of the present application. Figure 8 , the following combination Fig.18 The steps shown illustrate the data transmission method provided in the embodiment of the present application, wherein the execution subject of the data transmission method is the second access switch.

[0326] The data transmission method provided in the embodiment of the present application is applied to a multi-layer network architecture. The multi-layer network architecture includes an access layer and a convergence layer. The convergence layer includes at least one convergence sublayer. The access layer includes multiple access switches. Each access switch is connected to at least one first computing device. Each first computing device is provided with at least one network card. The convergence sublayer includes multiple convergence switches. For details, please refer to the description of the first data transmission method, which will not be repeated here.

[0327] In step 1801, a second access switch in an access layer receives a routing path for transmitting data to a network card in a first computing device.

[0328] Among them, there is a one-to-one correspondence between the routing path and the network card, and the routing path includes: a first path between the network card and the first access switch in the access layer, and a second path between the first access switch and a convergence switch in at least one convergence sublayer; the second access switch is connected to at least one second computing device, and the second access switch and the first access switch belong to different blocks.

[0329] In step 1802, after receiving data sent by the second computing device with a destination address corresponding to the network card, the data is sent to the network card based on the routing path.

[0330] For step 1801 and step 1802, please refer to the description of the first data transmission method, which will not be repeated here. In some embodiments, the second access switch is also used to receive the new routing path, and after receiving the data of the destination address corresponding to the network card sent by the second computing device, send the data to the network card based on the new routing path.

[0331] In the data transmission method provided in the embodiment of the present application, there is a one-to-one corresponding routing path for any network card of the first computing device, and the second computing device can send data to any network card of the first computing device based on the routing path. Compared with the method of randomly determining the routing path for data transmission, the present application uses the routing path corresponding to the network card for data transmission, realizes the load balancing of the switch for data transmission between the first computing device and the second computing device, and increases the data transmission rate, that is, the data transmission method provided in the embodiment of the present application can improve the efficiency of data transmission.

[0332] In some embodiments, the following is combined Figure 19-20 The data transmission method provided in the embodiment of the present application is illustrated by way of example, wherein: Fig.19 This is a schematic diagram of the data transmission method provided in the embodiment of the present application. Figure 9 . Fig. 20 This is a schematic diagram of the data transmission method provided in the embodiment of the present application. Figure 10 .

[0333] exist Figure 19-20 In the example, the first electronic device that executes the data transmission method provided in the embodiment of the present application is a server, and the second electronic device that executes the data transmission method provided in the embodiment of the present application is a second access switch. The first electronic device includes an SDN controller, that is, Figure 19-20 The server shown may include an SDN controller.

[0334] See also Fig.19 In step 1901, for a network card in a first computing device, a routing path for transmitting data to the network card is obtained.

[0335] For step 1901, see Figure 5 The description of step 101 shown in FIG. 1 is omitted here. Step 1901 and Fig. 20 The method of performing routing path planning 2004 through the topological connection relationship 2001 is described below.

[0336] Through the topological connection relationship between the first computing device and the first access switch, the first port of the first access switch connected to any network card in the first computing device can be determined. For example, the first port of the first access switch (GPULA-001) is Eth200GE1, that is, the downlink port of the first access switch (GPULA-001) is Eth200GE1.

[0337] The first port of the first access switch has a corresponding second port, wherein the first port corresponds to the second port one-to-one. Therefore, after determining the first port connected to the network card, the second port corresponding to the first port connected to the network card can be determined, wherein the second port is the uplink interface.

[0338] For example, the downlink port of the first access switch (GPULA-001) is Eth200GE1, and the uplink port of the first access switch (GPULA-001) is Eth200GE17, that is, the second port of the first access switch (GPULA-001) is Eth200GE17.

[0339] Then, the aggregation switch connected to the first access switch can be determined through the topological connection relationship between the first access switch and the aggregation switch. That is, the aggregation switch connected to the uplink port of the first access switch can be determined, and then the routing path 2005 can be obtained, wherein the routing path 2005 includes the first path between the network card and the first access switch, and the second path between the first access switch and the aggregation switch.

[0340] In step 1902, the routing path is sent.

[0341] Step 1902 is to send the routing path to the second access switch. Fig. 20 In the example, after obtaining the routing path 2005, the routing path 2005 can be sent to the second access switch 2003. For step 1902, see Figure 5 The description of step 101 is not repeated here.

[0342] In step 1903, after receiving the data of the destination address corresponding to the network card sent by the second computing device, the data is sent based on the routing path. Step 1903 is to send the data to the network card of the first computing device based on the routing path after receiving the data of the destination address corresponding to the network card sent by the second computing device.

[0343] The following describes steps 1901 to 1903 with reference to a specific example, in which a routing path for transmitting data to the network card is obtained. The routing path includes a first path between the network card and the first access switch. A prefix 1.1.1.1 / 32 may be set for the first path, and 1.1.1.1 / 32 is used to indicate the first path between the network card and the first access switch.

[0344] The routing path also includes a second path between the first access switch and the aggregation switch. A prefix of 2.2.2.2 may be set for the second path, and 2.2.2.2 is used to indicate the second path between the first access switch and the aggregation switch. Paths with prefixes of 1.1.1.1 / 32 and 2.2.2.2 may be sent to the first access switch, and the routing priority of the routing path is identified by 400. After receiving the data of the network card corresponding to the destination address sent by the second computing device, the first access switch may send the data to the network card of the first computing device based on the routing path.

[0345] In step 1904, when there is an abnormality in the routing path, a new routing path is acquired.

[0346] For step 1904, see Fig.13 and Fig.16 The corresponding description is not repeated here. Fig. 20 In the example, it can be determined whether there is an abnormality in the routing path according to the operation information 2002. If the operation information 2002 indicates that there is an abnormality in the routing path, a fault response 2006 can be performed. The operation information 2002 includes one or more of the first operation information and the second operation information.

[0347] In step 1905, the new routing path is sent.

[0348] exist Fig. 20In the example, the fault response 2006 is to obtain a new routing path and send the new routing path to the second access switch 2003, wherein the routing path 2005 may be a new routing path. When the operation information changes from indicating that there is an abnormality in the routing path to indicating that there is no abnormality in the routing path, the fault response 2006 may send a new routing path deletion instruction to the second access switch 2003.

[0349] In step 1906, after receiving the data of the destination address corresponding to the network card sent by the second computing device, the data is sent based on the new routing path.

[0350] Step 1906 is to send the data to the network card of the first computing device based on the new routing path after receiving the data of the network card corresponding to the destination address sent by the second computing device.

[0351] In the data transmission method provided in the embodiment of the present application, there is a one-to-one corresponding routing path for any network card of the first computing device, and the second computing device can send data to any network card of the first computing device based on the routing path. Compared with the method of randomly determining the routing path for data transmission, the present application uses the routing path corresponding to the network card for data transmission, realizes the load balancing of the switch for data transmission between the first computing device and the second computing device, and improves the data transmission rate. That is, the data transmission method provided in the embodiment of the present application can improve the efficiency of data transmission.

[0352] See also Fig.21 , Fig.21 is a schematic diagram of the transmission rate test results provided by the embodiment of the present application. Fig.21 The unit of the vertical axis is GB / s. The column corresponding to number 1 is the rate 1 of data transmission in the related technology, and rate 1 is 10.49 GB / s. The column corresponding to number 2 is the rate 2 of data transmission in the present application, and rate 2 is 15.11 GB / s. It can be seen that the data transmission method provided in the embodiment of the present application has a data transmission rate.

[0353] The column corresponding to number 3 is the data transmission rate 3 when there is an abnormality in the routing path in the related technology, and the rate 3 is 6.06 GB / s. The column corresponding to number 4 is the data transmission rate 4 when there is an abnormality in the routing path of the present application, and the rate 4 is 14.95 GB / s. It can be seen that although the abnormality in the routing path will cause the data transmission rate to decrease, the data transmission rate of the data transmission method provided in the embodiment of the present application is still higher than the data transmission rate in the related technology.

[0354] The following continues to describe an exemplary structure of the data transmission device 455 provided in the embodiment of the present application implemented as a software module. The data transmission device 455 provided in the embodiment of the present application is applied to a multi-layer network architecture, wherein the multi-layer network architecture includes an access layer and a convergence layer, wherein the convergence layer includes at least one convergence sublayer, and the access layer includes multiple access switches, each of the access switches is connected to at least one first computing device, each of the first computing devices is provided with at least one network card, and the convergence sublayer includes multiple convergence switches.

[0355] In some embodiments, Figure 2A As shown, the software modules stored in the data transmission device 455 of the memory 450 may include:

[0356] An acquisition module 4551 is used to acquire, for any network card in the first computing device, a routing path for transmitting data to the network card, where there is a one-to-one correspondence between the routing path and the network card;

[0357] The first sending module 4552 is used to send the routing path to the second access switch in the access layer, the second access switch is connected to at least one second computing device, and the second access switch and the first access switch belong to different blocks; wherein the second access switch is used to forward the data whose destination address corresponds to the network card and is sent by the second computing device to the network card based on the routing path.

[0358] In some embodiments, the first access switch has at least one first port and a second port corresponding to the first port one-to-one; the acquisition module 4551 is further used to determine the first port corresponding to the network card from the pre-set correspondence between the candidate network cards and the candidate first ports, and use the path between the network card and the first port corresponding to the network card as the first path; determine the aggregation switch corresponding to the second port from the pre-set correspondence between the candidate second ports and the candidate aggregation switches, and determine the second path based on the second port and the aggregation switch corresponding to the second port; determine the routing path based on the first path and the second path.

[0359] In some embodiments, the number of the convergence sublayers is multiple; the convergence switches corresponding to the second port include a first convergence switch and a second convergence switch, the first convergence switch and the second convergence switch belong to different convergence sublayers, and the first access switch is connected to the second convergence switch;

[0360] The acquisition module 4551 is further configured to use the routing path between the second port and the second aggregation switch as the first sub-path; use the routing path between the second aggregation switch and the first aggregation switch as the second sub-path; and determine the second path based on the first sub-path and the second sub-path.

[0361] In some embodiments, the multi-layer network architecture also includes a core layer, and the core layer includes multiple core switches. The acquisition module 4551 is also used to obtain a first path between the network card and the first access switch in the access layer, and obtain a second path between the first access switch and the aggregation switch in the at least one aggregation sublayer; determine the target core switch corresponding to the aggregation switch in the second path from the pre-set correspondence between the candidate aggregation switches and the candidate core switches; use the path between the aggregation switch in the second path and the target core switch as the third path; and determine a routing path based on the first path, the second path, and the third path.

[0362] In some embodiments, the first access switch belongs to the first block, and the first sending module 4552 is further used to search for a second identifier that matches the first identifier from the identifiers of access switches belonging to the second block according to the first identifier of the first access switch, wherein the first block is different from the second block; and use the access switch indicated by the second identifier as the second access switch, and send the routing path to the second access switch.

[0363] In some embodiments, the first identifier is a first number, the number of access switches belonging to the second block is multiple, and the identifier of the access switch belonging to the second block is a second number. The first sending module 4552 is further used to determine the difference between the first number and the second number for each second number; if the quotient of the difference and a preset third number is a target value, the second number is used as a second identifier matching the first identifier.

[0364] In some embodiments, the first sending module 4552 is further used to determine, based on the first identifier of the first access switch, a target identifier corresponding to the first identifier from a correspondence between pre-set candidate first identifiers and candidate target identifiers; and to search for an identifier consistent with the target identifier from the identifiers of the access switches belonging to the second block as a second identifier that matches the first identifier.

[0365] In some embodiments, the acquisition module 4551 is further used to obtain first operating information of the first access switch and second operating information of the aggregation switch after sending the routing path to the second access switch in the access layer; if at least one of the first operating information and the second operating information indicates that there is an abnormality in the routing path, a new routing path for transmitting data to the network card is obtained, and the new routing path is sent to the second access switch in the access layer; wherein the second access switch is further used to replace the routing path with the new routing path, and based on the new routing path, forward the data sent by the second computing device whose destination address corresponds to the network card to the network card.

[0366] In some embodiments, the acquisition module 4551 is further used to send the new routing path carrying the routing priority to the second access switch in the access layer; wherein the routing priority of the new routing path is higher than the routing priority of the routing path; the second access switch is further used to replace the routing path with the new routing path based on the routing priority of the new routing path.

[0367] In some embodiments, the acquisition module 4551 is further used to determine a third access switch from the access switches included in the block to which the first access switch belongs; determine a target network card corresponding to the third access switch from a pre-set correspondence between candidate network cards and candidate access switches; use the path between the target network card and the third access switch as a new first path; use the path between the third access switch and the aggregation switch as a new second path; determine a new routing path based on the new first path and the new second path; the target network card is used to forward the data of the network card to the network card after receiving the data of the network card sent by the second access switch based on the new routing path.

[0368] In some embodiments, the acquisition module 4551 is further used to determine a third aggregation switch from the aggregation switches included in the aggregation sublayer to which the aggregation switch belongs when the abnormality of the routing path is caused by a failure of the aggregation switch or a failure of a line between the first access switch and the aggregation switch; determine a fourth path based on the first access switch and the third aggregation switch; and replace the second path in the routing path with the fourth path to obtain a new routing path.

[0369] In some embodiments, there are multiple convergence sublayers; the acquisition module 4551 is further used to take the path between the first access switch and the third convergence switch as the third sub-path; based on the pre-set correspondence between the candidate third convergence switch and the candidate fourth convergence switch, determine the fourth convergence switch corresponding to the third convergence switch, and the third convergence switch and the fourth convergence switch belong to different convergence sublayers; take the path between the third convergence switch and the fourth convergence switch as the fourth sub-path; determine the fourth path based on the third sub-path and the fourth sub-path.

[0370] In some embodiments, the first sending module 4552 is further used to send a new routing path deletion instruction to the second access switch in the access layer after sending the new routing path to the second access switch in the access layer, if the operation information changes from indicating that the routing path is operating abnormally to operating normally, so that the second access switch deletes the new routing path.

[0371] The following continues to describe an exemplary structure of the data transmission device 456 provided in an embodiment of the present application implemented as a software module. The data transmission device 456 provided in an embodiment of the present application is applied to a multi-layer network architecture, wherein the multi-layer network architecture includes an access layer and a convergence layer, wherein the convergence layer includes at least one convergence sublayer, and the access layer includes multiple access switches, each of the access switches is connected to at least one first computing device, each of the first computing devices is provided with at least one network card, and the convergence sublayer includes multiple convergence switches.

[0372] In some embodiments, Figure 2B As shown, the software modules stored in the data transmission device 455 of the memory 450 may include:

[0373] A receiving module 4561, used for a second access switch in the access layer, to receive a routing path for transmitting data to a network card in the first computing device, wherein the routing path and the network card have a one-to-one correspondence relationship;

[0374] The routing path includes: a first path between the network card and a first access switch in the access layer, and a second path between the first access switch and a convergence switch in the at least one convergence sublayer; the second access switch is connected to at least one second computing device, and the second access switch and the first access switch belong to different blocks;

[0375] The second sending module 4562 is used to send the data to the network card based on the routing path after receiving the data sent by the second computing device and the destination address corresponds to the network card.

[0376] The embodiment of the present application provides a computer program product, which includes a computer program or a computer executable instruction, and the computer program or the computer executable instruction is stored in a computer-readable storage medium. The processor of the electronic device (the first electronic device and the second electronic device) reads the computer executable instruction or the computer program from the computer-readable storage medium, and the processor executes the computer executable instruction or the computer program, so that the electronic device executes the data transmission method described in the embodiment of the present application.

[0377] The present application embodiment provides a computer-readable storage medium in which computer executable instructions or computer programs are stored. When the computer executable instructions or computer programs are executed by a processor, the processor will execute the data transmission method provided by the present application embodiment, for example, Figure 5 The data transmission method shown. For example, Fig.18 The data transmission method is shown.

[0378] In some embodiments, the computer-readable storage medium may be a memory such as RAM, ROM, flash memory, magnetic surface memory, optical disk, or CD-ROM; or may be various devices including one or any combination of the above memories.

[0379] In some embodiments, computer executable instructions may be in the form of a program, software, software module, script or code, written in any form of programming language (including compiled or interpreted languages, or declarative or procedural languages), and may be deployed in any form, including as a stand-alone program or as a module, component, subroutine or other unit suitable for use in a computing environment.

[0380] As an example, computer-executable instructions or computer programs may, but need not, correspond to a file in a file system, may be stored as part of a file that stores other programs or data, such as in one or more scripts in a HyperText Markup Language (HTML) document, in a single file dedicated to the program in question, or in multiple coordinated files (e.g., files storing one or more modules, subroutines, or code portions).

[0381] As an example, computer-executable instructions or computer programs may be deployed to be executed on one electronic device (a first electronic device or a second electronic device), or on multiple electronic devices located at one location, or on multiple electronic devices distributed at multiple locations and interconnected by a communication network.

[0382] To sum up, in the data transmission method provided in the embodiment of the present application, there is a one-to-one corresponding routing path for any network card of the first computing device, and the second computing device can send data to any network card of the first computing device based on the routing path. Compared with the method of randomly determining the routing path for data transmission, the present application adopts the routing path corresponding to the network card for data transmission, realizes the load balancing of the switch for data transmission between the first computing device and the second computing device, and increases the data transmission rate. That is, the data transmission method provided in the embodiment of the present application can improve the efficiency of data transmission and can solve the above-mentioned technical problems 1 and 3.

[0383] In some embodiments, for the scenario of training artificial intelligence models, it is necessary to transmit a large amount of data between computing devices. Since the data transmission method provided in the embodiment of the present application adopts the routing path corresponding to the network card for data transmission, the load balancing of the switch for data transmission between the first computing device and the second computing device is achieved, and the data transmission rate is increased, that is, the data transmission method provided in the embodiment of the present application can improve the efficiency of data transmission, and thus can improve the efficiency of training artificial intelligence models. It can solve the above-mentioned technical problem 2.

[0384] In the data transmission method provided in the embodiment of the present application, it is possible to replace the routing path with a new routing path when there is an abnormality in the routing path, thereby ensuring the stability of data transmission, and avoiding the problems of low efficiency of data transmission between computing devices and reduced communication bandwidth due to congestion in the routing path. Therefore, it is possible to improve the efficiency of data transmission and increase the communication bandwidth while ensuring the stability of data transmission, and can solve the above-mentioned technical problem 4.

[0385] The above is only an embodiment of the present application and is not intended to limit the protection scope of the present application. Any modifications, equivalent substitutions and improvements made within the spirit and scope of the present application are included in the protection scope of the present application.

Claims

1. A data transmission method, characterized in that: Applied to a multi-layer network architecture, the multi-layer network architecture includes an access layer and a convergence layer, the convergence layer includes at least one convergence sublayer, the access layer includes a plurality of access switches, each of the access switches is connected to at least one first computing device, each of the first computing devices is provided with at least one network card, the convergence sublayer includes a plurality of convergence switches, and the method includes: For any network card in the first computing device, obtain a routing path for transmitting data to the network card, wherein the routing path and the network card have a one-to-one correspondence; wherein the routing path includes: a first path between the network card and a first access switch in the access layer, and a second path between the first access switch and a convergence switch in the at least one convergence sublayer; Sending the routing path to a second access switch in the access layer, where the second access switch is connected to at least one second computing device, and the second access switch and the first access switch belong to different blocks; The second access switch is used to forward the data sent by the second computing device and having a destination address corresponding to the network card to the network card based on the routing path.

2. The method according to claim 1, characterized in that: The first access switch has at least one first port and a second port corresponding to the first port in a one-to-one manner; The obtaining of a routing path for transmitting data to the network card includes: Determine the first port corresponding to the network card from the preset correspondence relationship between the candidate network card and the candidate first port, and use the path between the network card and the first port corresponding to the network card as the first path; Determine the aggregation switch corresponding to the second port from the preset correspondence relationship between the candidate second ports and the candidate aggregation switches, and determine the second path based on the second port and the aggregation switch corresponding to the second port; Based on the first path and the second path, a routing path is determined.

3. The method according to claim 2, characterized in that The number of the convergence sublayers is multiple; the convergence switches corresponding to the second port include a first convergence switch and a second convergence switch, the first convergence switch and the second convergence switch belong to different convergence sublayers, and the first access switch is connected to the second convergence switch; The determining the second path based on the second port and the aggregation switch corresponding to the second port includes: Taking the routing path between the second port and the second aggregation switch as a first sub-path; Taking the routing path between the second aggregation switch and the first aggregation switch as a second sub-path; Based on the first sub-path and the second sub-path, the second path is determined.

4. The method according to claim 1, characterized in that The multi-layer network architecture further includes a core layer, and the core layer includes a plurality of core switches; The obtaining of a routing path for transmitting data to the network card includes: Acquire a first path between the network card and a first access switch in the access layer, and acquire a second path between the first access switch and a convergence switch in the at least one convergence sublayer; Determine the target core switch corresponding to the aggregation switch in the second path from the preset correspondence between the candidate aggregation switches and the candidate core switches; Using the path between the aggregation switch and the target core switch in the second path as the third path; Based on the first path, the second path, and the third path, a routing path is determined.

5. The method according to claim 1, characterized in that The first access switch belongs to the first block; The sending the routing path to the second access switch in the access layer includes: searching, according to the first identifier of the first access switch, for a second identifier matching the first identifier from identifiers of access switches belonging to a second block, wherein the first block is different from the second block; The access switch indicated by the second identifier is used as the second access switch, and the routing path is sent to the second access switch.

6. The method according to claim 5, characterized in that The first identifier is a first number, the number of access switches belonging to the second block is multiple, and the identifier of the access switch belonging to the second block is a second number; The searching, according to the first identifier of the first access switch, from identifiers of access switches belonging to the second block, for a second identifier matching the first identifier includes: for each of the second numbers, determining a difference between the first number and the second number; If the quotient of the difference and a preset third number is a target value, the second number is used as a second identifier that matches the first identifier.

7. The method according to claim 5, characterized in that The searching, according to the first identifier of the first access switch, from identifiers of access switches belonging to the second block, for a second identifier matching the first identifier includes: According to the first identifier of the first access switch, determine the target identifier corresponding to the first identifier from the preset correspondence relationship between candidate first identifiers and candidate target identifiers; From the identifiers of the access switches belonging to the second block, an identifier consistent with the target identifier is searched as a second identifier matching the first identifier.

8. The method according to claim 1, characterized in that After sending the routing path to the second access switch in the access layer, the method further includes: Acquire first operation information of the first access switch, and acquire second operation information of the aggregation switch; If at least one of the first operation information and the second operation information indicates that the routing path is abnormal, obtaining a new routing path for transmitting data to the network card, and sending the new routing path to the second access switch in the access layer; The second access switch is further configured to replace the routing path with the new routing path, and forward the data sent by the second computing device and having a destination address corresponding to the network card to the network card based on the new routing path.

9. The method according to claim 8, characterized in that The sending the new routing path to the second access switch in the access layer includes: Sending the new routing path carrying the routing priority to the second access switch in the access layer; Wherein, the routing priority of the new routing path is higher than the routing priority of the routing path; The second access switch is further configured to replace the routing path with the new routing path based on the routing priority of the new routing path.

10. The method according to claim 8, characterized in that The obtaining of a new routing path for transmitting data to the network card includes: Determine a third access switch from the access switches included in the block to which the first access switch belongs; Determine a target network card corresponding to the third access switch from a preset correspondence relationship between candidate network cards and candidate access switches; Using the path between the target network card and the third access switch as a new first path; Using the path between the third access switch and the aggregation switch as a new second path; Determining a new routing path based on the new first path and the new second path; The target network card is configured to forward the data of the network card to the network card after receiving the data of the network card sent by the second access switch based on the new routing path.

11. The method according to claim 8, characterized in that The obtaining of a new routing path for transmitting data to the network card includes: When the abnormality of the routing path is caused by a failure of the aggregation switch or a failure of a line between the first access switch and the aggregation switch, determining a third aggregation switch from the aggregation switches included in the aggregation sublayer to which the aggregation switch belongs; Determine a fourth path based on the first access switch and the third aggregation switch; The second path in the routing path is replaced with the fourth path to obtain a new routing path.

12. The method according to claim 11, characterized in that The number of the convergence sublayers is multiple; The determining a fourth path based on the first access switch and the third aggregation switch includes: Taking the path between the first access switch and the third aggregation switch as the third sub-path; Based on the preset correspondence relationship between the candidate third aggregation switch and the candidate fourth aggregation switch, determine the fourth aggregation switch corresponding to the third aggregation switch, and the third aggregation switch and the fourth aggregation switch belong to different aggregation sublayers; Taking the path between the third aggregation switch and the fourth aggregation switch as the fourth sub-path; Based on the third sub-path and the fourth sub-path, a fourth path is determined.

13. The method according to claim 8, characterized in that After sending the new routing path to the second access switch in the access layer, the method further includes: If the operation information changes from indicating that the routing path is operating abnormally to operating normally, a new routing path deletion instruction is sent to the second access switch in the access layer, so that the second access switch deletes the new routing path.

14. A data transmission method, characterized in that: Applied to a multi-layer network architecture, the multi-layer network architecture includes an access layer and a convergence layer, the convergence layer includes at least one convergence sublayer, the access layer includes a plurality of access switches, each of the access switches is connected to at least one first computing device, each of the first computing devices is provided with at least one network card, the convergence sublayer includes a plurality of convergence switches, and the method includes: The second access switch in the access layer receives a routing path for transmitting data to a network card in the first computing device, wherein the routing path has a one-to-one correspondence with the network card; The second access switch is connected to at least one second computing device, and the second access switch and the first access switch belong to different blocks; the routing path includes: a first path between the network card and the first access switch in the access layer, and a second path between the first access switch and a convergence switch in the at least one convergence sublayer; After receiving the data sent by the second computing device and having a destination address corresponding to the network card, the data is sent to the network card based on the routing path.

15. A data transmission device, characterized in that: Applied to a multi-layer network architecture, the multi-layer network architecture includes an access layer and a convergence layer, the convergence layer includes at least one convergence sublayer, the access layer includes a plurality of access switches, each of the access switches is connected to at least one first computing device, each of the first computing devices is provided with at least one network card, the convergence sublayer includes a plurality of convergence switches, and the device includes: an acquisition module, configured to acquire, for any network card in the first computing device, a routing path for transmitting data to the network card, wherein the routing path and the network card have a one-to-one correspondence; wherein the routing path includes: a first path between the network card and a first access switch in the access layer, and a second path between the first access switch and a convergence switch in the at least one convergence sublayer; A first sending module is configured to send the routing path to a second access switch in the access layer, where the second access switch is connected to at least one second computing device, and the second access switch and the first access switch belong to different blocks; The second access switch is used to forward the data sent by the second computing device and having a destination address corresponding to the network card to the network card based on the routing path.

16. A data transmission device, characterized in that: Applied to a multi-layer network architecture, the multi-layer network architecture includes an access layer and a convergence layer, the convergence layer includes at least one convergence sublayer, the access layer includes a plurality of access switches, each of the access switches is connected to at least one first computing device, each of the first computing devices is provided with at least one network card, the convergence sublayer includes a plurality of convergence switches, and the device includes: A receiving module, used for a second access switch in the access layer, to receive a routing path for transmitting data to a network card in the first computing device, wherein the routing path and the network card have a one-to-one correspondence; The second access switch is connected to at least one second computing device, and the second access switch and the first access switch belong to different blocks; the routing path includes: a first path between the network card and the first access switch in the access layer, and a second path between the first access switch and a convergence switch in the at least one convergence sublayer; A second sending module is configured to send the data to the network card based on the routing path after receiving the data sent by the second computing device and whose destination address corresponds to the network card.

17. An electronic device, characterized in that: The electronic device comprises: A memory for storing computer executable instructions or computer programs; A processor, used to implement the data transmission method according to any one of claims 1 to 14 when executing the computer executable instructions or computer programs stored in the memory.

18. A computer-readable storage medium storing computer-executable instructions or a computer program, characterized in that: When the computer executable instructions or computer program are executed by a processor, the data transmission method according to any one of claims 1 to 14 is implemented.

19. A computer program product comprising computer executable instructions or a computer program, characterized in that When the computer executable instructions or computer program are executed by a processor, the data transmission method according to any one of claims 1 to 14 is implemented.