A link test method
By sending and receiving test data packets between the server and the switch, the link signal quality can be quickly tested, solving the testing challenges in the production process of rack-mounted servers and ensuring signal integrity.
Patent Information
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- XFUSION DIGITAL TECH CO LTD
- Filing Date
- 2023-05-15
- Publication Date
- 2026-05-15
AI Technical Summary
In the production process of rack-mount servers, the inability to effectively test the link signal quality leads to signal integrity issues and affects data transmission.
By sending and receiving test data packets between the server's network card port and the switch, and comparing the data packets before and after transmission, the link test results can be determined. No separate test fixture needs to be developed; only the network card and the switch need to be connected to perform a full-link test.
It enables fast and effective link testing, ensuring that the link signal quality meets normal business requirements and solving the testing challenges in the production process of rack-mounted servers.
Smart Images

Figure CN116668330B_ABST
Abstract
Description
Technical Field
[0001] This application relates to the field of server technology, and in particular to a link testing method. Background Technology
[0002] With the large-scale construction and rapid development of data centers, the shortcomings of traditional air-cooled rack servers have become increasingly prominent. To meet customer needs, related technologies integrate servers, switches, and liquid cooling equipment into a single rack, forming a rack-mount server. Rack-mount servers utilize L1 / L2 vertical integration for centralized power supply and cooling, reducing power consumption. By shifting from traditional distributed delivery to prefabricated rack-mount production, rack-mount servers offer factory prefabrication and complete unit delivery capabilities, allowing for pre-installation during production and increasing server deployment rates.
[0003] Rack-mount servers need to be pre-installed during the production process. In rack-mount servers, the server and the switch are connected via cables and module connectors. However, long cable runs and poor quality module connectors can both affect the signal integrity (SI) of data transmission between the server and the switch.
[0004] Therefore, there is an urgent need for a link testing method to test the links during the production of rack-mounted servers in order to ensure that the link signal quality can meet the normal business requirements. Summary of the Invention
[0005] This application provides a link testing method for testing links during the production of rack-mounted servers to ensure that the link signal quality meets normal business requirements.
[0006] In a first aspect, embodiments of this application provide a link testing method applied to a computing device, the computing device including a server, a first switch, and a second switch;
[0007] The server includes a network interface card (NIC), which has a first NIC port and a second NIC port. The server is electrically connected to a first switch through the first NIC port. The link between the first NIC port and the first switch is a first link. The server is electrically connected to a second switch through the second NIC port. The link between the second NIC port and the second switch is a second link. The first switch and the second switch are electrically connected.
[0008] The methods include:
[0009] Upon receiving a link test request, the server sends a first test data packet to the first switch through the first network interface card port in the network interface card.
[0010] After receiving the second test data packet, the first switch sends the second test data packet to the second switch; wherein the second test data packet is the data packet after the first test data packet has flowed through the first link;
[0011] After receiving the second test data packet, the second switch sends the second test data packet to the server;
[0012] When the server receives the third test data packet through the second network interface card port, it determines the link test result based on the first test data packet and the third test data packet; wherein, the third test data packet is the data packet after the second test data packet flows through the second link.
[0013] With the first and second switches electrically connected, test data packets can be transmitted directly along the entire link from the first network interface card (NIC) port to the first switch, then to the second switch, and back to the second NIC port. Comparing the data packets before transmission (the first test data packet) and after transmission (the third test data packet) determines the effectiveness of the link's data packet transmission, thus enabling link testing. This method eliminates the need for separately developed test fixtures; simply connecting the first switch (connected to the first NIC port) and the second switch (connected to the second NIC port) allows for rapid testing of the entire link between the NIC and the switches. This solves the problem in related technologies where link testing is impossible during the production of rack-mount servers, ensuring the link signal quality of tested computing devices (rack-mount servers) meets normal business requirements.
[0014] In one implementation, after the server sends the first test data packet to the first switch through the first network interface card (NIC) port, the method further includes:
[0015] The server determines whether it has received a third test data packet through the second network interface port in the network card within a preset time period;
[0016] When the server receives the third test data packet through the second network interface card (NIC) port, it determines the link test result based on the first and third test data packets, including:
[0017] If the server determines that it has received the third test data packet through the second network interface card port within a preset time period, it determines the link test result based on the first test data packet and the third test data packet.
[0018] If the server receives a third test data packet through the second network interface card (NIC) port within a preset time period, it can determine the link test result based on the first and third test data packets. This ensures that the link test result determined based on the transmission effect of the test data packets reflects the actual link status between the NIC and the switch.
[0019] In one implementation, the link test result is determined based on the first test data packet and the third test data packet, including:
[0020] The server determines the bit error rate based on the first test data packet and the third test data packet;
[0021] The server determines the link test result as passed when it determines that the bit error rate is greater than a preset threshold; or,
[0022] The server determines the link test result as failed when it determines that the bit error rate is less than or equal to a preset threshold.
[0023] The server can determine the bit error rate based on the first and third test data packets. Based on the bit error rate (which reflects the signal integrity of the data packets transmitted in the link), the server determines the link test result, ensuring that the link test result reflects the real link situation between the network card and the switch.
[0024] In one implementation, the first test data packet includes a first test bitstream, and the third test data packet includes a second test bitstream;
[0025] The server determines the bit error rate based on the first and third test data packets, including:
[0026] The server determines the bit error rate based on the first test bitstream and the second test bitstream.
[0027] The beneficial effects of this embodiment are: the server can determine the bit error rate that reflects the real link situation by comparing the first test bit stream in the first test data packet and the second test bit stream in the second test data packet, thus ensuring that the link test results can reflect the real link situation between the network card and the switch.
[0028] In one implementation, the first and second test streams are pseudo-random binary sequence streams, or custom streams.
[0029] The beneficial effects of this embodiment are that the first test stream and the second test stream can be pseudo-random binary streams or custom streams, ensuring that the test scheme can be applied to a variety of test environments.
[0030] In one implementation, the method further includes:
[0031] If the server determines that the link test result is unsuccessful if it fails to receive the third test data packet through the second network interface port within the preset time period.
[0032] If the server fails to receive a third test data packet through the second network interface card (NIC) port within a preset time period, the link test result is determined to be unsuccessful. By monitoring whether a third test data packet is received within the preset time period, problematic links are filtered out, ensuring that the link test results reflect the true link status between the NIC and the switch.
[0033] In one implementation, the method further includes:
[0034] The server outputs the link test results; the link test results are used to indicate whether the test results of the first link and the second link are pass or fail.
[0035] After determining the link test results, the server can output the link test results to notify the testers whether the test results of the first and second links are pass or fail.
[0036] In one implementation,
[0037] If the link test result is determined to be unsuccessful, the server outputs an alarm message; or, the alarm indicator light on the control network card is illuminated.
[0038] When the server determines that the link test result is unsuccessful, it can output an alarm message or control the alarm indicator light on the network card to remind the tester that the link test result is unsuccessful.
[0039] In one implementation, before the server sends the first test data packet to the first switch through the first network interface card (NIC) port, the method further includes:
[0040] The server configures the network card to promiscuous mode.
[0041] When the network card is operating in promiscuous mode, it can listen to and receive all data packets passing through it without verifying the address of the data packets. This allows the first test data packet to be sent from the network card to the first switch, rather than being limited to the server.
[0042] In one implementation, the method further includes:
[0043] If the link test result is confirmed to be successful, the server will configure the network card's operating mode to broadcast mode.
[0044] After the server confirms that the link test result is passed, it can reconfigure the network card's operating mode from promiscuous mode to broadcast mode to clear the network card's configuration. This ensures that during subsequent use of the server, the network card will only receive data packets destined for that network card, thus avoiding the network card indiscriminately receiving all data packets and increasing the processing load on the server's processor.
[0045] Secondly, embodiments of this application provide a link testing method applied to a server. The server includes a network interface card (NIC), which includes a first NIC port and a second NIC port. The server is electrically connected to a first switch through the first NIC port. The link between the first NIC port and the first switch is a first link. The server is electrically connected to a second switch through the second NIC port. The link between the second NIC port and the second switch is a second link. The first switch and the second switch are electrically connected.
[0046] The method includes:
[0047] Upon receiving a link test request, the server sends a first test data packet to the first switch through the first network interface card port in the network interface card.
[0048] When the server receives the third test data packet through the second network interface card port, it determines the link test result based on the first test data packet and the third test data packet; wherein, the third test data packet is the data packet after the second test data packet flows through the second link.
[0049] With the first and second switches electrically connected, test data packets can be transmitted directly along the entire link from the first network interface card (NIC) port to the first switch, then to the second switch, and back to the second NIC port. Comparing the data packets before transmission (the first test data packet) and after transmission (the third test data packet) determines the effectiveness of the link's data packet transmission, thus enabling link testing. This method eliminates the need for separately developed test fixtures; simply connecting the first switch (connected to the first NIC port) and the second switch (connected to the second NIC port) allows for rapid testing of the entire link between the NIC and the switches. This solves the problem in related technologies where link testing is impossible during the production of rack-mount servers, ensuring the link signal quality of tested computing devices (rack-mount servers) meets normal business requirements.
[0050] Thirdly, embodiments of this application provide a link testing method applied to a first switch, the method comprising:
[0051] After receiving the second test data packet, the first switch sends the second test data packet to the second switch; wherein the second test data packet is the data packet after the first test data packet has flowed through the first link.
[0052] Test data packets can be transmitted directly along the entire link from the first network interface card (NIC) port to the first switch, then to the second switch, and back to the second NIC port. The effectiveness of the link transmission is determined by comparing the data packets before transmission (the first test data packet) and the data packets after transmission (the third test data packet), thus enabling link testing. This method eliminates the need for separately developed test fixtures; simply connecting the first switch (connected to the first NIC port) and the second switch (connected to the second NIC port) allows for rapid testing of the entire link between the NIC and the switches. This solves the problem in related technologies where link testing is impossible during the production of rack-mount servers, ensuring the link signal quality of tested computing devices (rack-mount servers) meets normal business requirements.
[0053] Fourthly, embodiments of this application provide a link testing method applied to a second switch, the method comprising:
[0054] After receiving the second test data packet, the second switch sends the second test data packet to the server.
[0055] Test data packets can be transmitted along the entire link from the first network interface card (NIC) port to the first switch, then to the second switch, and back to the second NIC port. Comparing the data packets before transmission (the first test data packet) and after transmission (the third test data packet) determines the effectiveness of the link's data packet transmission, thus enabling link testing. This method eliminates the need for separately developed test fixtures; simply connecting the first switch (connected to the first NIC port) and the second switch (connected to the second NIC port) allows for rapid testing of the entire link between the NIC and the switches. This solves the problem in related technologies where link testing is impossible during the production of rack-mount servers, ensuring the link signal quality of tested computing devices (rack-mount servers) meets normal business requirements.
[0056] Fifthly, embodiments of this application provide a server, the server including a network interface card (NIC), the NIC including a first NIC port and a second NIC port; the server is electrically connected to a first switch through the first NIC port; the link between the first NIC port and the first switch is a first link; the server is electrically connected to a second switch through the second NIC port; the link between the second NIC port and the second switch is a second link; the first switch and the second switch are electrically connected.
[0057] The server also includes:
[0058] The sending module is used to send a first test data packet to the first switch through the first network interface port in the network interface card in response to receiving a link test request;
[0059] The processing module is used to determine the link test result based on the first test data packet and the third test data packet when a third test data packet is received through the second network interface port in the network interface card; wherein the third test data packet is the data packet after the second test data packet flows through the second link.
[0060] The server provided in this embodiment can execute the technical solution in the above method embodiment where the execution subject is a server, and its beneficial effects are similar, so they will not be described again here.
[0061] In one implementation, the processing module is also used for:
[0062] After sending the first test data packet to the first switch through the first network interface card (NIC) port, determine whether the third test data packet is received through the second NIC port within a preset time period.
[0063] If a third test data packet is received through the second network interface card port within a preset time period, the link test result is determined based on the first and third test data packets.
[0064] The server provided in this embodiment can execute the technical solution in the above method embodiment where the execution subject is a server, and its beneficial effects are similar, so they will not be described again here.
[0065] In one implementation, the processing module is specifically used for:
[0066] The bit error rate is determined based on the first and third test data packets;
[0067] If the bit error rate is determined to be greater than a preset threshold, the link test result is determined to be passed; or,
[0068] If the bit error rate is determined to be less than or equal to a preset threshold, the link test result is determined to be unsuccessful.
[0069] The server provided in this embodiment can execute the technical solution in the above method embodiment where the execution subject is a server, and its beneficial effects are similar, so they will not be described again here.
[0070] In one implementation, the first test data packet includes a first test bitstream, and the third test data packet includes a second test bitstream; the processing module is specifically used for:
[0071] The bit error rate is determined based on the first test bitstream and the second test bitstream.
[0072] The server provided in this embodiment can execute the technical solution in the above method embodiment where the execution subject is a server, and its beneficial effects are similar, so they will not be described again here.
[0073] In one implementation, the first and second test streams are pseudo-random binary sequence streams, or custom streams.
[0074] The server provided in this embodiment can execute the technical solution in the above method embodiment where the execution subject is a server, and its beneficial effects are similar, so they will not be described again here.
[0075] In one implementation, the processing module is also used for:
[0076] If the third test data packet is not received through the second network interface port within the preset time period, the link test result is determined to be unsuccessful.
[0077] In one implementation,
[0078] The sending module is also used to output link test results; the link test results are used to indicate whether the test results of the first link and the second link are passed or failed.
[0079] The server provided in this embodiment can execute the technical solution in the above method embodiment where the execution subject is a server, and its beneficial effects are similar, so they will not be described again here.
[0080] In one implementation, the processing module is also used for:
[0081] If the link test result is determined to be unsuccessful, an alarm message will be output; alternatively, the alarm indicator light on the network card will be illuminated.
[0082] The server provided in this embodiment can execute the technical solution in the above method embodiment where the execution subject is a server, and its beneficial effects are similar, so they will not be described again here.
[0083] In one implementation, the server also includes a configuration module;
[0084] Before the sending module sends the first test data packet to the first switch through the first network interface card port in the network interface card, the configuration module is used to configure the network interface card's working mode to promiscuous mode.
[0085] The server provided in this embodiment can execute the technical solution in the above method embodiment where the execution subject is a server, and its beneficial effects are similar, so they will not be described again here.
[0086] In one implementation, the configuration module is also used for:
[0087] If the link test result is confirmed to be successful, configure the network card's operating mode to broadcast mode.
[0088] The server provided in this embodiment can execute the technical solution in the above method embodiment where the execution subject is a server, and its beneficial effects are similar, so they will not be described again here.
[0089] Sixthly, embodiments of this application provide a first switch, the first switch comprising:
[0090] The receiving module is used to receive the second test data packet;
[0091] The sending module is used to send a second test data packet to the second switch; wherein the second test data packet is the data packet after the first test data packet has flowed through the first link.
[0092] The first switch provided in this embodiment can execute the technical solution in the above method embodiment where the execution subject is the first switch, and its beneficial effects are similar, so they will not be described again here.
[0093] Seventhly, embodiments of this application provide a second switch, the second switch comprising:
[0094] The receiving module is used to receive the second test data packet;
[0095] The sending module is used to send a second test data packet to the server.
[0096] The second switch provided in this embodiment can execute the technical solution in the above method embodiment where the execution subject is the second switch, and its beneficial effects are similar, so they will not be described again here.
[0097] Eighthly, embodiments of this application provide a computing device, which includes a server according to the fifth aspect, a first switch according to the sixth aspect, and a second switch according to the seventh aspect, wherein the first switch and the second switch are electrically connected.
[0098] The computing device provided in this embodiment can execute the technical solution of the first aspect, and its beneficial effects are similar, so they will not be described again here. Attached Figure Description
[0099] To more clearly illustrate the technical solutions in the embodiments or related technologies of this application, the accompanying drawings used in the description of the embodiments or related technologies will be briefly introduced below. Obviously, the accompanying drawings described below are some embodiments of this application. For those skilled in the art, other drawings can be obtained based on these drawings without creative effort.
[0100] Figure 1 This is a schematic diagram of the internal structure of a computing device provided in an embodiment of this application;
[0101] Figure 2This is a schematic diagram of the structure of a computing device provided in an embodiment of this application;
[0102] Figure 3 A flowchart illustrating an embodiment of a link testing method provided in this application;
[0103] Figure 4 A flowchart illustrating a second embodiment of a link testing method provided in this application;
[0104] Figure 5 A flowchart illustrating a third embodiment of a link testing method provided in this application;
[0105] Figure 6 This application provides a schematic diagram of the structure of a server according to an embodiment of the present application.
[0106] Figure 7 This is a schematic diagram of the structure of a first switch provided in an embodiment of this application;
[0107] Figure 8 This is a schematic diagram of the structure of a second switch provided in an embodiment of this application. Detailed Implementation
[0108] To make the objectives, technical solutions, and advantages of the embodiments of this application clearer, the technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, not all embodiments. Based on the embodiments of this application, all other embodiments made by those skilled in the art under the guidance of these embodiments are within the scope of protection of this application.
[0109] The terms “first,” “second,” “third,” “fourth,” etc. (if present) in the specification, claims, and accompanying drawings of this application are used to distinguish similar objects and are not necessarily used to describe a particular order or sequence. It should be understood that such data can be interchanged where appropriate so that the embodiments of this application described herein can be implemented in orders other than those illustrated or described herein. Furthermore, the terms “comprising” and “having,” and any variations thereof, are intended to cover a non-exclusive inclusion; for example, a process, method, system, product, or apparatus that comprises a series of steps or units is not necessarily limited to those steps or units explicitly listed, but may include other steps or units not explicitly listed or inherent to such processes, methods, products, or apparatus.
[0110] With the large-scale construction and rapid development of data centers, the shortcomings of traditional air-cooled rack servers have become increasingly prominent. First, the ratio of total data center energy consumption (including IT equipment energy consumption and energy consumption of cooling, power distribution, etc.) to the value of IT equipment energy consumption (Power Usage Effectiveness, PUE) is too high, ranging from 1.5 to 1.8, indicating low energy efficiency and failing to meet the growing demands for energy conservation and emission reduction. Second, the lack of coordination between L0 / L1 / L2 servers in data centers requires on-site installation by personnel to run cabling to connect servers and switches via signal cables (fiber optic or cable), resulting in long delivery cycles and hindering automated server operation and maintenance. Third, the maximum power of the rack is 8KW, limiting the number of servers that can be placed in each air-cooled rack server, severely impacting the server utilization rate within the rack.
[0111] Addressing the shortcomings of air-cooled rack servers, related technologies integrate servers, switches, and liquid cooling equipment into a single rack, creating a rack-mount server. This rack-mount server utilizes L1 / L2 vertical integration for centralized power supply and cooling, reducing PUE (Power Usage Effectiveness). By shifting from traditional distributed delivery to prefabricated rack-mount production, the need for on-site cabling is avoided. Rack-mount servers offer factory prefabrication and complete unit delivery capabilities, allowing for pre-installation during production and increasing server deployment rates.
[0112] Figure 1 This is a schematic diagram of the internal structure of a computing device provided in an embodiment of this application. Figure 1 As shown, in a computing device, the network interface card (NIC) in a server is electrically connected to a switch via a module connector (module connector in the server), a cable, and a module connector (module connector in the switching node). The module connector includes a module head, a cable, a female connector, and a male connector. The male connector is plugged into a cable backplane and connected to another male connector plugged into the cable backplane via a cable. Exemplarily, the module head can be a Quad Small Form-factor Pluggable (QSFP) 28 type Direct Attach Cable (DAC) module head, or a Small Form Pluggable (SFP) 28 type DAC module head, or an SFP type DAC module head. This application embodiment does not limit the type of module head.
[0113] However, the long cable backplane height results in long cable routing links. Long cable routing links and quality issues with module connectors can both affect signal integrity and even prevent data signal transmission. Therefore, there is an urgent need for a link testing method to test the links of computing devices (such as rack-mount servers) to ensure that the link signal quality meets normal business requirements.
[0114] Based on the above-mentioned technical problems, this application provides a link testing method that can perform packet reloading tests on network cards and switches during the pre-installation of computing devices (such as rack servers). Through packet reloading tests, the signal quality of the entire link is covered, ensuring that the link signal quality of the computing devices that pass the test can meet normal business needs.
[0115] The link testing scheme of this application embodiment will be described in detail below.
[0116] Figure 2 This is a schematic diagram of the structure of a computing device provided in an embodiment of this application. Figure 2 As shown, the computing device includes at least one server and at least two switches. Each server includes at least one Network Interface Card (NIC), and each NIC includes at least two NIC ports, wherein the number of NIC ports is even. The server can be electrically connected to the switch through the NIC ports. Additionally, the server may include a processor, which can be electrically connected to the NIC within the server.
[0117] For example, the server's processor can be a Central Processing Unit (CPU). It should be noted that the switch can be a management switch or a service switch. When the switch is a management switch, it can be used to forward data packets used for managing the server to the server; when the switch is a service switch, it can be used to forward data packets from users to the server.
[0118] For example, Figure 2 Two servers are shown, namely server 201 and server 202.
[0119] Server 201 includes processor 2011, network interface card (NIC) 2012, and NIC 2013. NIC 2012 includes two NIC ports, designated as a first NIC port and a second NIC port. NIC 2013 includes two NIC ports, designated as a first NIC port and a second NIC port.
[0120] Server 202 includes processor 2021, network interface card (NIC) 2022, and NIC 2023. NIC 2022 includes two NIC ports, designated as a first NIC port and a second NIC port. NIC 2023 includes two NIC ports, designated as a first NIC port and a second NIC port.
[0121] For example, Figure 1 Four switches are also shown: switch 203, switch 204, switch 205, and switch 206. Switches 203, 204, 205, and 206 can be installed as top-of-rack (TOR) switches on top of servers 201 and 202.
[0122] The first network interface card (NIC) port of NIC 2012 in server 201 can be electrically connected to switch 203 via the first port of switch 203, and the second NIC port of NIC 2012 can be electrically connected to switch 204 via the first port of switch 204. It should be noted that when the computing device is located on an Ethernet network, both the first and second NIC ports of NIC 2012 can be Ethernet interfaces (ETH).
[0123] The first network card port of network card 2013 can be electrically connected to switch 205 through the first port of switch 205, and the second network card port of network card 2013 can be electrically connected to switch 206 through the first port of switch 206.
[0124] The first network interface card (NIC) port of NIC 2022 in server 202 can be electrically connected to switch 203 through the second port of switch 203, and the second NIC port of NIC 2022 can be electrically connected to switch 204 through the second port of switch 204.
[0125] The first network interface card (NIC) port of NIC 2023 can be electrically connected to switch 205 through the second port of switch 205, and the second NIC port of NIC 2023 can be electrically connected to switch 206 through the second port of switch 206.
[0126] Furthermore, switches 203 and 204, which are electrically connected to different network interface card (NIC) ports, can be electrically connected via the third port (upstream port) of switch 203 and the third port (upstream port) of switch 204. It should be noted that when switch 203 is electrically connected to switch 204, switch 203 can be connected to switch 204 through one third port (upstream port) of switch 203 and one third port (upstream port) of switch 204. Switch 203 can also be connected to switch 204 through multiple third ports (upstream ports) of switch 203 and multiple third ports (upstream ports) of switch 204. The number of ports required for electrical connection between switch 203 and switch 204 depends on the number of servers included in the computing device, the convergence ratio, and the NIC port type. Additionally, the number of ports is also related to the switch port type.
[0127] Switches 205 and 206, which are electrically connected to different network interface card (NIC) ports of the same NIC, can be electrically connected through the third port (upstream port) of switch 205 and the third port (upstream port) of switch 206.
[0128] It should also be noted that when a network card is connected to a switch through its port and the switch's port, the connection is made through a module connector, a cable, and the module connectors (including module heads, cables, female connectors, and male connectors).
[0129] When a switch is electrically connected to another switch via one switch port and another switch port, the electrical connection can be made through two optical modules and the optical fiber between the two optical modules. It should be noted that the optical modules can be SFP optical modules, QSFP28 optical modules, or other types of optical modules; this application does not limit the specific type of optical module used.
[0130] When a switch makes an electrical connection to another switch through one switch port and another switch port, it can also make an electrical connection through a direct attach cable (DAC) (consisting of a cable and module heads at both ends).
[0131] It should also be noted that the computing device can be a rack-mount server, or other computing devices including servers and switches.
[0132] It should also be noted that, Figure 2 This is merely a schematic diagram of the structure of a computing device provided in an embodiment of this application. This embodiment of the application does not represent... Figure 2 The document does not limit the actual form of the various devices included, nor does it specify the form of the devices. Figure 1The interaction methods between devices are limited, and can be set according to actual needs when applying the solution.
[0133] The technical solution of this application will now be described in detail through specific embodiments. It should be noted that the following specific embodiments can be combined with each other, and the same or similar concepts or processes may not be described again in some embodiments.
[0134] Figure 3 This is a flowchart illustrating an embodiment of a link testing method provided in this application. See also... Figure 3 The method specifically includes the following steps:
[0135] S301: Upon receiving a link test request, the server sends the first test data packet to the first switch through the first network interface card port in the network interface card.
[0136] In this implementation, the server can receive link test requests. In one implementation, the server displays a visual interface, and the server can obtain link test requests input by the user through the visual interface. In another implementation, the server can obtain link test requests sent by other computing devices; for example, the server can obtain link test requests sent by terminal devices connected to the server.
[0137] Upon receiving a link test request, the server responds by sending a first test data packet to the first switch via the first network interface card (NIC) port. The source address of the first test data packet is the address of the first NIC port, and the destination address is the address of the second NIC port. Furthermore, the first test data packet may include a first test bitstream. In one implementation, this first test bitstream may be a pseudo-random binary sequence (PRBS) bitstream; in another implementation, it may be a custom bitstream. This embodiment does not limit the specific content of the first test bitstream.
[0138] In one implementation, before the server sends the first test data packet, the processor in the server (such as a central processing unit) can run packet-sending software to generate the first test data packet. After generating the first test data packet, the processor in the server can send the first test data packet to the network interface card (NIC) and then send the first test data packet to the first switch through the first NIC port. It should be noted that the processor can communicate with the NIC through a Peripheral Component Interconnect Express (PCIE) interface to send the first test data packet to the NIC.
[0139] In one implementation, in response to receiving a link test request, the server can configure the network interface card (NIC) to promiscuous mode, so that the NIC can receive all data packets flowing through it without verifying the packet address.
[0140] Specifically, network interface cards (NICs) have two operating modes: broadcast mode and promiscuous mode.
[0141] Data packets are transmitted in plaintext over a network.
[0142] When the network interface card (NIC) is operating in broadcast mode, when a server sends a data packet to the network, the network, during packet transmission, delivers the packet to various network nodes (network nodes refer to the servers joined to the network, such as the servers in a computing device). Network nodes matching the destination address receive these packets; other network nodes, if they determine that the packet does not match the destination address, simply discard these packets.
[0143] The network interface card (NIC) is responsible for controlling whether to receive or discard data packets. Specifically, the NIC filters out data packets whose destination address is its own address and sends such packets to the processor (such as the central processing unit) for processing. Conversely, the NIC discards data packets whose destination address is not its own address.
[0144] When the network card is operating in promiscuous mode, it can listen to and receive all data packets passing through it without needing to verify the address of the data packets.
[0145] When the network interface card (NIC) operates in broadcast mode, and the source address of the first test data packet is the address of the first NIC port, and the destination address of the first test data packet is the address of the second NIC port (meaning the sender and receiver of the first test data packet are the same NIC), the NIC, after receiving the first test data packet sent by the processor, determines that the destination address of the first test data packet is the NIC's second NIC port. Given this, the NIC can directly send the first test data packet to the processor. However, this first test data packet can only be transmitted within the server and cannot be sent to the first or second switch. Consequently, the link between the computing devices cannot be tested; that is, the first link (NIC's first NIC port → first switch) and the second link (NIC's second NIC port → second switch) cannot be tested.
[0146] When the network interface card (NIC) operates in promiscuous mode, it does not need to verify the destination address of the first test data packet it receives. On one hand, the NIC can send the first test data packet to the processor; on the other hand, it can act as a forwarding component, sending the first test data packet into the network. In other words, the first test data packet is not limited to the server's internal network but can be sent by the NIC to the first switch.
[0147] S302: After receiving the second test data packet, the first switch sends the second test data packet to the second switch.
[0148] In this embodiment, the first test data packet becomes the second test data packet after flowing through the first link (the first network interface card port of the network interface card → the first switch). The source address of the second test data packet is the address of the first network interface card port, and the destination address of the second test data packet is the address of the second network interface card port. Additionally, the second test data packet includes a third test bitstream. In one implementation, the third test bitstream can be a pseudo-random binary bitstream; in another implementation, the third test bitstream can be a custom bitstream. This embodiment does not limit the specific content of the third test bitstream.
[0149] After receiving the second test data packet, the first switch sends the second test data packet to the second switch based on the destination address of the second test data packet being the address of the second network card port.
[0150] S303: After receiving the second test data packet, the second switch sends the second test data packet to the server.
[0151] In this embodiment, based on the purpose of testing the first link and the second link in this application, and considering that the first switch and the second switch are electrically connected by two pre-prepared optical modules and optical fibers, or by direct copper cables, it is determined that there are no quality problems in the link between the first switch and the second switch. In other words, it is determined that the second test data packet will not be lost when it flows through the first switch and the second switch, and the second test data packet will still be the second test data packet after flowing through the link (first switch → second switch).
[0152] After receiving the second test data packet sent by the first switch, the second switch sends the second test data packet to the server based on the destination address of the second test data packet being the address of the second network card port.
[0153] S304: When the server receives a third test data packet through the second network interface card port in the network interface card, it determines the link test result based on the first test data packet and the third test data packet.
[0154] In this embodiment, the second test data packet becomes the third test data packet after flowing through the second link (second switch → second network card port of the network card). The source address of the third test data packet is the address of the first network card port, and the destination address is the address of the second network card port. Additionally, the third test data packet includes a second test bitstream. In one implementation, the second test bitstream can be a pseudo-random binary bitstream; in another implementation, the second test bitstream can be a custom bitstream. This embodiment does not limit the specific content of the second test bitstream.
[0155] The server can receive the third test data packet through the second network interface port in the network card.
[0156] After the processor in the server receives the third test data packet through the second network interface card port, it can determine the link test result based on the first test data packet generated by the processor and the received third test data packet.
[0157] Specifically, when the first test data packet includes a first test bitstream and the third test data packet includes a second test bitstream, the processor can determine the bit error rate based on the first test bitstream and the second test bitstream, and determine the link test result based on the bit error rate.
[0158] It should be noted that after the server confirms that the link test result is passed, the network card's working mode can be reconfigured from promiscuous mode to broadcast mode to clear the network card's configuration. This ensures that during subsequent use of the server, the network card will only receive data packets destined for that network card, thus avoiding the network card indiscriminately receiving all data packets, which would increase the processor's processing load.
[0159] In this embodiment, with the first switch (the switch connected to the first network interface card (NIC) port of the server's NIC) and the second switch (the switch connected to the second NIC port of the server's NIC) electrically connected, test data packets can be directly transmitted on the links of the NIC's first NIC port → the first switch, the first switch → the second switch, and the second switch → the NIC's second NIC port. This embodiment determines the effectiveness of the link's data transmission by comparing the test data packets before transmission (the first test data packet) and the test data packets after transmission (the third test data packet). This method eliminates the need for separately developed test fixtures; simply connecting the first switch (connected to the NIC's first NIC port) and the second switch (connected to the NIC's second NIC port) electrically allows for rapid testing of the entire link between the NIC and the switches. This solves the problem in related technologies where link testing is impossible during the production of rack-mount servers, ensuring the link signal quality of rack-mount servers that pass testing meets normal business requirements.
[0160] Based on the above method embodiment one, the process of determining the link test result by the server will be described in detail below through method embodiment two.
[0161] Figure 4 This is a flowchart illustrating a second embodiment of a link testing method provided in this application. See also... Figure 4 The method specifically includes the following steps:
[0162] S401: After the server sends the first test data packet to the first switch through the first network interface card port in the network interface card, it determines whether the third test data packet is received through the second network interface card port in the network interface card within a preset time period.
[0163] In this embodiment, after the server sends the first test data packet to the first switch through the first network interface card port in the network interface card, it determines whether the server receives the third test data packet through the second network interface card port in the network interface card within a preset time period.
[0164] If the server determines that it has received the third test data packet through the second network interface card port within a preset time period, it executes S402; if the server determines that it has not received the third test data packet through the second network interface card port within a preset time period, it executes S403.
[0165] S402: The server determines the link test result based on the first test data packet and the third test data packet.
[0166] In this embodiment, when the server determines that it has received a third test data packet through the second network interface port of the network interface card within a preset time period, the server determines the link test result based on the first test data packet generated by the server and the received third test data packet.
[0167] Specifically, the server can compare the first test bitstream in the first test data packet with the second test bitstream in the third test data packet to determine the number of erroneous symbols in the second test bitstream. The server can determine the total number of symbols in the first test bitstream and, based on the number of erroneous symbols in the second test bitstream and the total number of symbols in the first test bitstream in the first test data packet, determine the bit error rate.
[0168] After determining the bit error rate, the server can compare it with a preset threshold. If the server determines that the bit error rate is greater than the preset threshold, the link test result is considered passed. If the server determines that the bit error rate is less than or equal to the preset threshold, the link test result is considered failed.
[0169] After determining the link test results, the server can output the link test results; the link test results are used to indicate whether the test results of the first link (the first network card port of the network card → the first switch) and the second link (the second switch → the second network card port of the network card) are passed or failed.
[0170] In one implementation, the server can generate an alarm message to notify the tester that the link test has failed. In another implementation, after generating the alarm message, the server can control a computing device to display or play the alarm message. Specifically, the computing device has a visual interface, and the computing device can control the visual interface to display the alarm message. The computing device may also include a playback component, which can control the playback component to play the alarm message. In yet another implementation, after generating the alarm message, the server can send the alarm message to other computing devices (such as terminal devices, exemplarily mobile phones or computers), causing the other computing devices to display or play the alarm message.
[0171] In one implementation, if the server determines that the link test result is unsuccessful, it can control the first alarm indicator light on the network card to light up, so as to remind the tester that the link test result is unsuccessful.
[0172] Similarly, if the server determines that the link test result is passed, it can generate a pass message to notify the tester. In one implementation, after generating the pass message, the server can control the visualization interface of the computing device to display the pass message, or it can control the playback component to play the pass message. When generating the pass message, the server can also send the pass message to other computing devices (such as terminal devices) so that other computing devices can display or play the pass message. When the server determines that the link test result is passed, it can control the second alarm indicator light on the network card to illuminate to notify the tester that the link test result is passed.
[0173] It should be noted that the first alarm indicator and the second alarm indicator can be different indicators or the same indicator. When the first alarm indicator and the second alarm indicator are the same indicator, they can be marked with different colors to indicate different information. For example, when the alarm indicator is red, it indicates that the link test result is failed; when the alarm indicator is green, it indicates that the link test result is passed.
[0174] S403: The server has determined that the link test result is unsuccessful.
[0175] In this embodiment, if the server determines that it has not received the third test data packet through the second network interface port in the network interface card within a preset time period, it can directly determine that the link test result is unsuccessful.
[0176] It should be noted that if the server does not receive the third test data packet through the second network interface card port within the preset time period, it can be determined that the link may be interrupted, or that the switch may be faulty, or that the network interface card is faulty.
[0177] In this embodiment, after the server sends a first test data packet to the first switch through the first network interface card (NIC) port, if it determines that a third test data packet has been received through the second NIC port within a preset time period, the server determines the link test result based on the first and third test data packets. If the server determines that a third test data packet has not been received through the second NIC port within the preset time period, it can directly determine that the link test result is failed. This embodiment illustrates the process by which the server determines the link test result based on the first and third test data packets, ensuring that the link test result reflects the actual link status between the NIC and the switch.
[0178] Figure 5 This is a flowchart illustrating a third embodiment of a link testing method provided in this application. See also... Figure 5 The method specifically includes the following steps:
[0179] S501: Upon receiving a link test request, the server writes the identifier of the first network interface card port of the network interface card into the first test data packet.
[0180] In this embodiment, when the server receives a link test request, it can write the identifier of the first network interface card (NIC) port into the first test data packet and send the first test data packet to the first switch through the first NIC port. Exemplarily, the identifier of the first NIC port can be the serial number of the NIC port, or it can be the name of the NIC port. The identifier of the first NIC port can also be the MAC address of the NIC port, or it can be the IP address of the NIC port.
[0181] S502: The server sends the first test data packet to the first switch through the first network interface card port in the network interface card.
[0182] S503: After receiving the second test data packet, the first switch writes its own identifier into the second test data packet.
[0183] In this embodiment, after receiving the second test data packet, the first switch can write its identifier into the second test data packet. For example, the identifier of the first switch can be its serial number, or it can be its name.
[0184] In other words, the second test data packet at this time includes the identifier of the first network card port of the network card and the identifier of the first switch.
[0185] S504: The first switch sends the second test data packet to the second switch.
[0186] S505: After receiving the second test data packet, the second switch writes its identifier into the second test data packet.
[0187] In this embodiment, after receiving the second test data packet, the second switch can write its identifier into the second test data packet. For example, the identifier of the second switch can be its serial number, or it can be its name.
[0188] In other words, the second test data packet at this time includes the identifier of the first network card port of the network card, the identifier of the first switch, and the identifier of the second switch.
[0189] S506: The second switch sends the second test data packet to the server.
[0190] S507: When the server receives a third test data packet through the second network interface card port in the network interface card, it determines the link test result based on the first test data packet and the third test data packet.
[0191] In this embodiment, the second test data packet becomes the third test data packet after flowing through the second link. When the server receives the third test data packet through the second network interface card (NIC) port, it can write the identifier of the second NIC port into the third test data packet. For example, the identifier of the second NIC port can be the serial number of the NIC port, or it can be the name of the NIC port.
[0192] In other words, the third test data packet at this time includes the identifier of the first network card port of the network card, the identifier of the first switch, the identifier of the second switch, and the identifier of the second network card port of the network card.
[0193] S508: The server determines the link test report based on the link test results and the third test data packet.
[0194] In this embodiment, after determining the link test result based on the first test data packet and the third test data packet, the server can generate a link test report based on the link test result and the identifiers of the nodes through which the test data packet flows, which are included in the third test data packet. The link test report includes the link test result and the nodes through which the test data packet flows.
[0195] For example, Table 1 is a link test report.
[0196] Table 1 Link Test Report
[0197] Link test results Network card port switch switch Network card port pass The first network interface card port of the network card First switch Second switch The second network interface port of the network card
[0198] In one implementation, after generating the link test report, the server can control the visualization interface of the computing device to display the link test report.
[0199] In one implementation, after generating a link test report, the server can control the playback component to play the link test report.
[0200] In one implementation, after generating a link test report, the server can send the link test report to other computing devices so that the other computing devices can display or play the link test report.
[0201] In this embodiment, the server can write the identifier of the first network interface card (NIC) port into the test data packet. When the test data packet flows through the first switch and the second switch, the first and second switches can write its identifier into the test data packet. When the server receives the test data packet through the second NIC port, it can write the identifier of the second NIC port into the test data packet. The server can determine the test result of each complete link (first NIC port → first switch → second switch → second NIC port) based on the nodes through which the test data packet flows, and generate a link test report corresponding to each complete link, so that testers can clearly know the test result of each link.
[0202] The computing device will now be described using Example 4.
[0203] In this embodiment, the first switch (the switch connected to the first network card port of the network card) and the second switch (the switch connected to the second network card port of the network card) are interconnected. Specifically, the uplink ports of the first switch and the uplink ports of the second switch can be interconnected through optical modules or through DACs.
[0204] It should be noted that the port type and number of ports used by each switch are related to the total number of servers included in the computing device, the preset convergence ratio, and the network interface card (NIC) port type. For example, when the computing device includes 36 servers, the preset convergence ratio is 3:2, and the NIC port type is 25GE, the total data flow bandwidth of all nodes is 36 × 25GE = 900GE. Based on the preset convergence ratio of 3:2, uplink forwarding requires at least 600GE. That is, uplink forwarding requires six 100GE switch ports, or three 200GE switch ports. This application does not limit the type and number of switch ports used.
[0205] When uplink forwarding requires six 100GE switch ports, the first switch can be electrically connected to the second switch via six third-party ports (uplink ports) and six third-party ports (uplink ports) of the second switch. In other words, when electrically connecting the ports of the first switch to the ports of the second switch, it is necessary to use either six 100GE DACs or twelve 100GE optical modules (six on the first switch side and six on the second switch side) to connect the ports of the first switch to the ports of the second switch.
[0206] In this embodiment, only the DAC or optical module interconnecting the two switches is needed during the testing of the computing device's link. No other testing environment is required, which ensures that testers can easily and quickly deploy the testing environment when testing the computing device's link, thereby improving testing efficiency and reducing testing costs.
[0207] The following are embodiments of the apparatus described in this application, which can be used to execute the embodiments of the method described in this application. For details not disclosed in the apparatus embodiments of this application, please refer to the embodiments of the method described in this application.
[0208] This application also provides a server. Figure 6 This application provides a schematic diagram of the structure of a server according to an embodiment of the present application; as shown below. Figure 6 As shown, the server 60 includes a configuration module 61, a processing module 62, and a sending module 63. The sending module 63, in response to receiving a link test request, sends a first test data packet to a first switch through a first network interface card (NIC) port. The processing module 62, upon receiving a third test data packet through a second NIC port, determines the link test result based on the first and third test data packets; wherein the third test data packet is the data packet generated after the second test data packet has passed through the second link.
[0209] The server provided in this application embodiment can execute the technical solution in the above method embodiment where the execution subject is a server. Its implementation principle and beneficial effects are similar, and will not be repeated here.
[0210] In one implementation, the processing module 62 is further configured to: after sending a first test data packet to the first switch through the first network interface card port in the network interface card, determine whether a third test data packet is received through the second network interface card port in the network interface card within a preset time period; if it is determined that a third test data packet is received through the second network interface card port in the network interface card within a preset time period, determine the link test result based on the first test data packet and the third test data packet.
[0211] The server provided in this application embodiment can execute the technical solution in the above method embodiment where the execution subject is a server. Its implementation principle and beneficial effects are similar, and will not be repeated here.
[0212] In one implementation, the processing module 62 is specifically used to: determine the bit error rate based on the first test data packet and the third test data packet; determine the link test result as passed when the bit error rate is determined to be greater than a preset threshold; or determine the link test result as failed when the bit error rate is determined to be less than or equal to the preset threshold.
[0213] The server provided in this application embodiment can execute the technical solution in the above method embodiment where the execution subject is a server. Its implementation principle and beneficial effects are similar, and will not be repeated here.
[0214] In one implementation, the first test data packet includes a first test bitstream, and the third test data packet includes a second test bitstream; the processing module 62 is specifically used to: determine the bit error rate based on the first test bitstream and the second test bitstream.
[0215] The server provided in this application embodiment can execute the technical solution in the above method embodiment where the execution subject is a server. Its implementation principle and beneficial effects are similar, and will not be repeated here.
[0216] In one implementation, the first and second test streams are pseudo-random binary sequence streams, or custom streams.
[0217] The server provided in this application embodiment can execute the technical solution in the above method embodiment where the execution subject is a server. Its implementation principle and beneficial effects are similar, and will not be repeated here.
[0218] In one implementation, the processing module 62 is further configured to: determine that the link test result is unsuccessful if, within a preset time period, no third test data packet is received through the second network interface port in the network interface card.
[0219] The server provided in this application embodiment can execute the technical solution in the above method embodiment where the execution subject is a server. Its implementation principle and beneficial effects are similar, and will not be repeated here.
[0220] In one implementation, the sending module 63 is further configured to output link test results; the link test results are used to indicate whether the test results of the first link and the second link are passed or failed.
[0221] In one implementation, the processing module 62 is further configured to: output an alarm message when the link test result is determined to be unsuccessful; or, control the alarm indicator light of the network card to illuminate.
[0222] The server provided in this application embodiment can execute the technical solution in the above method embodiment where the execution subject is a server. Its implementation principle and beneficial effects are similar, and will not be repeated here.
[0223] In one implementation, before the sending module 63 sends the first test data packet to the first switch through the first network interface port in the network interface card, the configuration module 61 is used to configure the network interface card's operating mode to promiscuous mode.
[0224] The server provided in this application embodiment can execute the technical solution in the above method embodiment where the execution subject is a server. Its implementation principle and beneficial effects are similar, and will not be repeated here.
[0225] In one implementation, the configuration module 61 is further configured to: configure the network card's operating mode to broadcast mode if the link test result is determined to be passed.
[0226] The server provided in this application embodiment can execute the technical solution in the above method embodiment where the execution subject is a server. Its implementation principle and beneficial effects are similar, and will not be repeated here.
[0227] This application also provides a first switch. Figure 7 This is a schematic diagram of the structure of a first switch provided in an embodiment of this application; as shown below. Figure 7 As shown, the first switch 70 includes a receiving module 71 and a sending module 72. The receiving module 71 is used to receive a second test data packet; the sending module 72 is used to send the second test data packet to the second switch; wherein the second test data packet is the data packet generated after the first test data packet has passed through the first link.
[0228] The first switch provided in this application embodiment can execute the technical solution in the above method embodiment where the execution subject is the first switch. Its implementation principle and beneficial effects are similar, and will not be repeated here.
[0229] This application also provides a second switch. Figure 8 This is a schematic diagram of the structure of a second switch provided in an embodiment of this application; as shown below. Figure 8 As shown, the second switch 80 includes a receiving module 81 and a sending module 82. The receiving module 81 is used to receive the second test data packet; the sending module 82 is used to send the second test data packet to the server.
[0230] The second switch provided in this application embodiment can execute the technical solution in the above method embodiment where the execution subject is the second switch. Its implementation principle and beneficial effects are similar, and will not be repeated here.
[0231] This application also provides a computing device, including a server, a first switch, and a second switch. The first switch and the second switch are electrically connected.
[0232] Computing devices can be rack-mount servers, or they can be other devices including servers and switches.
[0233] The server in the computing device provided in this application embodiment can execute the technical solution in the method embodiment where the execution subject is the server. The first switch in the computing device provided in this application embodiment can execute the technical solution in the method embodiment where the execution subject is the first switch. The second switch in the computing device provided in this application embodiment can execute the technical solution in the method embodiment where the execution subject is the second switch. Their implementation principles and beneficial effects are similar, and will not be described again here.
[0234] Those skilled in the art will understand that all or part of the steps of the above-described method embodiments can be implemented by hardware related to program instructions. The aforementioned program can be stored in a computer-readable storage medium. When executed, the program performs the steps of the above-described method embodiments; and the aforementioned storage medium includes various media capable of storing program code, such as ROM, RAM, magnetic disks, or optical disks.
[0235] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of this application, and are not intended to limit them. Although this application has been described in detail with reference to the foregoing embodiments, those skilled in the art should understand that modifications can still be made to the technical solutions described in the foregoing embodiments, or equivalent substitutions can be made to some or all of the technical features therein. Such modifications or substitutions do not cause the essence of the corresponding technical solutions to deviate from the scope of the technical solutions of the embodiments of this application.
Claims
1. A link testing method for the production process, applied to a rack server, wherein the rack server includes a server, a first switch, and a second switch; in, The server includes a network interface card (NIC), which includes a first NIC port and a second NIC port; the server is electrically connected to the first switch through the first NIC port; the link between the first NIC port and the first switch is a first link; The server is electrically connected to the second switch through the second network interface card (NIC) port in the NIC; the link between the second NIC port in the NIC and the second switch is the second link; The feature is that, for the purpose of testing the first link and the second link, the first switch and the second switch are electrically connected using two pre-prepared optical modules and optical fibers, or by direct copper cables, in order to determine that there are no quality problems in the link between the first switch and the second switch; The method includes: In response to receiving a link test request, the server configures the network interface card (NIC) to promiscuous mode and sends a first test data packet to the first switch through the first NIC port. The source address of the first test data packet is the address of the first NIC port, and the destination address of the first test data packet is the address of the second NIC port. After receiving the second test data packet, the first switch sends the second test data packet to the second switch; wherein the second test data packet is the data packet after the first test data packet has flowed through the first link; After receiving the second test data packet, the second switch sends the second test data packet to the server; When the server receives a third test data packet through the second network interface port of the network interface card, it determines the bit error rate based on the first test data packet and the third test data packet, and determines the link test result based on the bit error rate; wherein, the third test data packet is the data packet after the second test data packet flows through the second link; If the link test result is determined to be successful, the server will configure the network card's operating mode to broadcast mode.
2. The link testing method according to claim 1, characterized in that, After the server sends the first test data packet to the first switch through the first network interface card port in the network interface card, the method further includes: The server determines whether it receives the third test data packet through the second network interface port of the network interface card within a preset time period; When the server receives a third test data packet through the second network interface card port of the network interface card, it determines the bit error rate based on the first test data packet and the third test data packet, and determines the link test result based on the bit error rate, including: If the server determines that it receives the third test data packet through the second network interface port of the network interface card within the preset time period, it determines the bit error rate based on the first test data packet and the third test data packet, and determines the link test result based on the bit error rate.
3. The link testing method according to claim 1, characterized in that, The step of determining the bit error rate based on the first test data packet and the third test data packet, and then determining the link test result based on the bit error rate, includes: When the server determines that the bit error rate is greater than a preset threshold, it determines that the link test result is passed; or, When the server determines that the bit error rate is less than or equal to the preset threshold, the link test result is deemed unsuccessful.
4. The link testing method according to claim 3, characterized in that, The first test data packet includes a first test bitstream, and the third test data packet includes a second test bitstream; The server determines the bit error rate based on the first test data packet and the third test data packet, including: The server determines the bit error rate based on the first test bitstream and the second test bitstream.
5. The link testing method according to claim 4, characterized in that, The first test stream and the second test stream are pseudo-random binary sequence streams, or custom streams.
6. The link testing method according to any one of claims 2-5, characterized in that, The method further includes: If the server determines that the link test result is failed if it fails to receive the third test data packet through the second network interface port of the network interface card within the preset time period, the link test result is determined to be failed.
7. The link testing method according to any one of claims 3-5, characterized in that, The method further includes: The server outputs the link test results; the link test results are used to indicate whether the test results of the first link and the second link are passed or failed.
8. The link testing method according to claim 7, characterized in that, If the link test result is determined to be unsuccessful, the server outputs an alarm message; or, it controls the alarm indicator light of the network card to illuminate.