Link interruption error reporting method and device, computer equipment and storage medium
By acquiring and analyzing link information, accurately identifying the cause of link interrupts and handling them, the frequent errors and system management interrupts caused by link interrupts are solved, and network stability and availability are improved.
Patent Information
- Application Number
- CN202411889048.2
- Authority / Receiving Office
- CN · China
- Patent Type
- Applications(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-20
- Publication Date
- 2025-03-21
- Estimated Expiration
- 2044-12-20
AI Technical Summary
During the server service opening process, link interruption causes frequent errors from high-speed bus devices, which in turn affects the performance of the central processor and link stability, and system management interrupts triggered by false alarms affect system stability.
By obtaining the link information of the disconnected link, the device type of the disconnected device is judged. If it is a terminal node device, the link interrupt error information will be reported immediately; if it is an intermediate node device, the type of the downstream device is judged and the link interrupt error will be handled according to the preset rules.
It realizes accurate positioning of the causes of link interruptions, reduces the link performance reduction caused by frequent error reporting, improves the stability and availability of the network, and ensures smooth transmission of data in the network.
Smart Images

Figure CN119676058A_ABST
Abstract
Description
Technical Field
[0001] The present application relates to the technical field of error reporting, and in particular to a link interruption error reporting method, apparatus, computer equipment and storage medium. Background Art
[0002] During the server startup process, a variety of high-speed bus devices are usually connected to the switching device adapter board, so there will be multiple links and the links are long. When a high-speed bus device on the link fails and the link is disconnected, it will cause the high-speed bus device to frequently report errors, which in turn causes the central processor to frequently enter the system management interrupt program. The cause of the link interruption is likely to be the frequent abnormal error reporting of the downstream high-speed bus device of the link, resulting in instability of the upstream link connected to the downstream high-speed bus device, triggering a link interruption exception. The system management interruption triggered by this false alarm affects the performance of the central processor and reduces the stability of the link. Summary of the invention
[0003] Based on this, it is necessary to provide a link interruption error reporting method, device, computer equipment and storage medium that can accurately locate the cause of link interruption and avoid link performance degradation due to frequent error reporting in order to solve the above technical problems.
[0004] On the one hand, a link interruption error reporting method is provided, the method comprising:
[0005] In response to a link disconnection, obtaining link information of the disconnected link,
[0006] Determine the device type of the disconnected device based on the link information. The device types include intermediate node devices and terminal node devices. The intermediate node device is connected to the downstream device.
[0007] In response to the device type of the disconnected device being a terminal node device, a link interruption error message is reported,
[0008] In response to the device type of the disconnected device being an intermediate node device, determining the device type of the downstream device,
[0009] Link interruption errors are handled according to preset rules based on the device type of the downstream device.
[0010] In one embodiment, the link information includes device information and bus topology information, and the device type of the disconnected device is determined based on the link information, including:
[0011] According to the link information, the device information of the disconnected device is determined; according to the bus topology information, the connection information of the disconnected device is determined; according to the device information and the connection information of the disconnected device, the device type of the disconnected device is determined.
[0012] In one embodiment, processing a link interruption error according to a preset rule based on a device type of a downstream device includes:
[0013] In response to the device type of the downstream device being an intermediate node device, link interruption error information is reported; in response to the device type of the downstream device being a terminal node device, the number of correctable errors of the terminal node device is monitored, and the link interruption error information is reported according to a preset threshold.
[0014] In one of the embodiments, monitoring the number of correctable errors of the terminal node device and reporting link interruption error information according to a preset threshold value includes:
[0015] Set the reporting threshold for the number of correctable errors. By monitoring, obtain the number of correctable errors of the terminal node device within the preset time, determine whether the number of correctable errors of the terminal node device exceeds the reporting threshold for the number of correctable errors. If the number of correctable errors exceeds the preset threshold, report the link interruption error information.
[0016] In one of the embodiments, before monitoring the number of correctable errors of the terminal node device and reporting link interruption error information according to a preset threshold, the method further includes:
[0017] Obtain the information to be verified of the terminal node device, determine whether the terminal node device is added to the whitelist based on the information to be verified of the terminal node device, and in response to the terminal node device being added to the whitelist, monitor the number of correctable errors of the terminal node device and report link interruption error information based on a preset threshold; in response to the terminal node device not being added to the whitelist, add the terminal node device to the whitelist.
[0018] In one embodiment, obtaining the information to be verified of the terminal node device includes:
[0019] Acquire and parse terminal node device information, remove redundant information of terminal node devices, generate information to be unified for terminal node devices, convert the information to be unified for terminal node devices into a standard format, and generate information to be verified for terminal node devices.
[0020] In one embodiment, reporting link interruption error information includes:
[0021] Obtain link interruption error information, which includes one or more of the following: error time, error type, device information and bus topology information. Report the link interruption error information to the processing system. In response to receiving the interruption error information, the processing system sends a system management interruption request to the central processing unit; in response to receiving the system management interruption request, the central processing unit suspends the current execution task, obtains the task information of the current execution task, stores the task information in the memory and enters the management mode; in response to the central processing unit entering the management mode, the processing system parses the link interruption error information; determines the cause of the link interruption according to the link interruption error information and processes it. In response to the completion of the processing, the task information is obtained through the memory; the central processing unit exits the management mode and resumes the execution of the task.
[0022] On the other hand, a link interruption error reporting device is provided, the device comprising:
[0023] An acquisition module, configured to acquire link information of a disconnected link in response to the link being disconnected;
[0024] A first determination module, used to determine the device type of the disconnected device according to the link information;
[0025] A reporting module, configured to report link interruption error information in response to the device type of the disconnected device being a terminal node device;
[0026] A second determination module, configured to determine a device type of a downstream device in response to the device type of the disconnected device being an intermediate node device;
[0027] The processing module is used to process the link interruption error according to the device type of the downstream device and the preset rules.
[0028] In another aspect, a computer device is provided, comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein when the processor executes the computer program, the following steps are implemented:
[0029] In response to a link disconnection, obtaining link information of the disconnected link,
[0030] Determine the device type of the disconnected device based on the link information. The device types include intermediate node devices and terminal node devices. The intermediate node device is connected to the downstream device.
[0031] In response to the device type of the disconnected device being a terminal node device, a link interruption error message is reported,
[0032] In response to the device type of the disconnected device being an intermediate node device, determining the device type of the downstream device,
[0033] Link interruption errors are handled according to preset rules based on the device type of the downstream device.
[0034] In another aspect, a computer-readable storage medium is provided, on which a computer program is stored, and when the computer program is executed by a processor, the following steps are implemented:
[0035] In response to a link disconnection, obtaining link information of the disconnected link,
[0036] Determine the device type of the disconnected device based on the link information. The device types include intermediate node devices and terminal node devices. The intermediate node device is connected to the downstream device.
[0037] In response to the device type of the disconnected device being a terminal node device, a link interruption error message is reported,
[0038] In response to the device type of the disconnected device being an intermediate node device, determining the device type of the downstream device,
[0039] Link interruption errors are handled according to preset rules based on the device type of the downstream device.
[0040] The above-mentioned link interruption error reporting method, device, computer equipment and storage medium, by accurately monitoring the link disconnection and collecting detailed link information, the system can quickly identify the type of connection device that disconnects the link, that is, the intermediate node device or the terminal node device. For the disconnection of the terminal node device, the system immediately reports the link interruption error information, which helps to quickly locate the source of the problem and promptly notify the relevant personnel to handle it, thereby reducing the service interruption time caused by the disconnection of the terminal node device and improving the stability and availability of the network. For the disconnection of the intermediate node device, the system further determines the type of its downstream device and performs corresponding processing according to the preset rules. Ensures the smooth transmission of data in the network and avoids other problems that may be caused by blind processing. By flexibly responding to different types of disconnection situations, the system can more effectively utilize network resources and improve the overall network operation efficiency. BRIEF DESCRIPTION OF THE DRAWINGS
[0041] Figure 1 A diagram showing an application environment of a link interruption error reporting method in an embodiment;
[0042] Figure 2 A schematic diagram of a process of reporting a link interruption error in an embodiment;
[0043] Figure 3 A schematic diagram of a process of reporting a link interruption error in an embodiment;
[0044] Figure 4 It is a structural block diagram of a link interruption error reporting device in one embodiment;
[0045] Figure 5FIG. 4 is a diagram showing the internal structure of a computer device in one embodiment. DETAILED DESCRIPTION
[0046] In order to make the purpose, technical solution and advantages of the present application more clearly understood, the present application is further described in detail below in conjunction with the accompanying drawings and embodiments. It should be understood that the specific embodiments described herein are only used to explain the present application and are not used to limit the present application.
[0047] The link interruption error reporting method provided in this application can be applied to Figure 1 In the application environment shown, the terminal 102 communicates with the server 104 through a network. The terminal 102 may be, but is not limited to, various personal computers, laptops, smart phones, tablet computers, and portable wearable devices, and the server 104 may be implemented as an independent server or a server cluster consisting of multiple servers.
[0048] In one embodiment, Figure 2 As shown, a link interruption error reporting method is provided, which is applied to Figure 1 The server in the example is used to illustrate the following steps:
[0049] Step 201: In response to a link disconnection, obtain link information of the disconnected link.
[0050] Among them, link disconnection refers to Surprise Link Down (SLD for short), that is, the link is unexpectedly disconnected, which is an error condition that may occur in the PCIe (PCIExpress) system. When a PCIe device fails or a power problem causes Surprise Link Down, the hardware will trigger an exception. In the case of Surprise Down, the state of the PCIe link may change from a normal operating state (such as L0 or L0s) to an error state, such as Hot Reset, Electrical Idle, or Link Down. At this time, the PCIe controller will detect the exception and update its internal status register to reflect the state change of the device. At the same time, the PCIe driver will call the corresponding error handling function to try to restore the device, disable the device, or mark the device as invalid. SLD may cause the interruption of ongoing transactions, data corruption, or even system crash.
[0051] Step 203: Determine the device type of the disconnected device according to the link information.
[0052] The intermediate node refers to the Switch Bridge, which can divide the PCIe bus into multiple sub-buses like the PCIe Switch, allowing multiple PCIe devices to be connected to the same PCIe port to achieve data forwarding and communication; it can also achieve connection and data transmission between different PCIe buses or other types of buses (such as PCI, PCI-X) like the PCIe Bridge. Through the function of PCIe Switch, the device can connect multiple PCIe devices to improve the connectivity and scalability of the system; using the function of Bridge, the device can achieve connection and data transmission between the PCIe bus and other types of buses, thereby achieving compatibility and interoperability between different devices; according to the target address or other routing information of the data packet, the device can intelligently select the forwarding path of the data packet to ensure that the data can be accurately and efficiently transmitted to the target device.
[0053] Endpoint refers to a specific location or node in a network or system, which can be the starting point or end point of network communication. As the starting point or end point of data transmission and communication, Endpoint can receive and send data, and interact with other devices or systems through different protocols and communication methods. It can expand and integrate other functions, such as calling remote services, accessing databases, performing specific computing tasks, etc., to provide flexibility and scalability for the system.
[0054] Step 205: In response to the device type of the disconnected device being the terminal node device, reporting link interruption error information.
[0055] Among them, reporting link interruption error information means that when an SLD situation occurs, the system triggers an SMI interrupt to notify the operating system or system management software so that the system can respond and handle this abnormal situation in a timely manner to avoid data loss or system crash.
[0056] Step 207: In response to the device type of the disconnected device being the intermediate node device, determine the device type of the downstream device.
[0057] Step 209: Process the link interruption error according to a preset rule based on the device type of the downstream device.
[0058] In the above-mentioned link interruption error reporting method, the above-mentioned link interruption error reporting method, device, computer equipment and storage medium, by accurately monitoring the link disconnection and collecting detailed link information, the system can quickly identify the type of connection device that disconnects the link, that is, the intermediate node device or the terminal node device. For the disconnection of the terminal node device, the system immediately reports the link interruption error information, which helps to quickly locate the source of the problem and promptly notify the relevant personnel to handle it, thereby reducing the service interruption time caused by the disconnection of the terminal node device and improving the stability and availability of the network. For the disconnection of the intermediate node device, the system further determines the type of its downstream device and performs corresponding processing according to the preset rules. Ensures the smooth transmission of data in the network and avoids other problems that may be caused by blind processing. By flexibly responding to different types of disconnection situations, the system can more effectively utilize network resources and improve the overall network operation efficiency.
[0059] In one embodiment, the link information includes device information and bus topology information, and the device type of the disconnected device is determined according to the link information, including:
[0060] According to the link information, determine the device information of the disconnected device. The link information includes the BDF (Bus, Device, Function) information of the device. Bus (bus number) identifies a bus in the PCIe bus system; Device (device number) identifies a device connected to a specific bus; Function (function number) identifies a specific function or unit in the device. According to the bus topology information, determine the connection information of the disconnected device; determine the device type of the disconnected device based on the device information and connection information of the disconnected device. By identifying the link topology information and BDF information, you can clearly understand the physical connection and topology structure of the PCIe device in the system, which helps to quickly locate the fault point and determine whether it is a problem with a Bridge device in the link or a problem with the EndPoint device.
[0061] The Bus number is the unique identifier of the PCIe bus system, the Device number locks the specific device on a specific bus, and the Function number further refines the functional modules inside the device. BDF information together constitutes a device positioning system, which can quickly identify the source of the problem as the Switch Bridge device or the End Point device in the link. Combined with the bus topology information, it can track the upstream and downstream connection relationship of the disconnected device, and then determine whether the fault is caused by the device itself, the connecting cable, or the adjacent device. Improving the accuracy of troubleshooting and significantly shortening the positioning and repair time are crucial to maintaining system stability and efficient operation.
[0062] In one embodiment, according to the device type of the downstream device, processing the link interruption error according to a preset rule includes:
[0063] In response to the device type of the downstream device being an intermediate node device, the link interruption error information is reported; in response to the device type of the downstream device being a terminal node device, the number of correctable errors of the terminal node device is monitored, and the link interruption error information is reported according to the preset threshold. That is, after determining the device type of the faulty device, a corresponding strategy is adopted according to the device type of the faulty device. When the device type of the faulty device is End Point, the link interruption error information is directly reported, which is an End Point device problem that needs to be located. When the device type of the faulty device is Switch Bridge, the downstream device type of Switch Bridge is further determined. The determination method is the same as the method described in the previous embodiment. If the downstream device is Switch Bridge, the link interruption error information is directly reported, which is a Switch Bridge link problem that needs to be located; if the downstream device is End Point, the End Point is monitored, and the next processing strategy is selected according to the preset threshold.
[0064] When the faulty device is detected as an End Point, the system directly reports the link interruption error information, which helps to quickly locate and solve the problem of the end node itself, reducing unnecessary troubleshooting steps. For the Switch Bridge device as an intermediate node, the system further analyzes the type of its downstream device. If the downstream is also a Switch Bridge, it also reports the link interruption information, which helps to quickly locate the problem area of the intermediate link; if the downstream is an End Point, the system monitors the End Point. This method simplifies the fault handling process, avoids the blind troubleshooting and resource waste in traditional methods, and makes fault location faster and more accurate.
[0065] In one embodiment, monitoring the number of correctable errors of the terminal node device and reporting link interruption error information according to a preset threshold includes:
[0066] Set the reporting threshold for the number of correctable errors. Obtain the number of correctable errors of the terminal node device within the preset time through monitoring, and determine whether the number of correctable errors of the terminal node device exceeds the reporting threshold for the number of correctable errors. If the number of correctable errors exceeds the preset threshold, report the link interruption error information. Set the reporting threshold for the number of correctable errors. The reporting number can be determined based on factors such as historical error data. Configure the whitelist device information (such as device ID, IP address, etc.) to be monitored into the monitoring system. The monitoring system starts to monitor the whitelist devices in real time. The monitoring system will store the number of errors and the time of occurrence of each device in the database for subsequent analysis and query. And check whether the number of correctable errors of each whitelist device exceeds the preset threshold. If the number of errors of a device exceeds the threshold, the monitoring system will immediately report the link interruption error information. The information may include detailed information such as device ID, error type, number of errors, and time of occurrence. Among them, the correctable error (CE: CorrectableError) may be caused by hardware connection problems, device compatibility problems, driver problems, system settings problems, power problems, etc. The whitelist system suppresses the Surprise Link Down errors triggered by End Point intensive CE errors, and then filters out the real Surprise Link Down abnormal error information that needs to be processed.
[0067] The setting of the reporting threshold for the number of correctable errors may include a first threshold and a second threshold, the second threshold is greater than the first threshold, if the number of correctable errors exceeds the first threshold and does not exceed the second threshold, it means that the number of CE occurrences has not reached a high level, it can be determined that the situation belongs to a low-level interruption, through the delayed reporting mechanism, the error information is recorded and reported and processed in a centralized manner at a preset time, such as 5 minutes; if the number of correctable errors continues to increase and exceeds the second threshold, it means that the number of CE occurrences has reached a high level, it is considered to be a high-level interruption, and the link interruption error information is immediately reported for interruption processing. Centrally processing error information through the delayed reporting mechanism can avoid frequent interruption triggering and reduce CPU resource usage; when the number of CE occurrences exceeds the second threshold, it is determined to be a high-level interruption, the system immediately reports the error and triggers the system management interruption (SMI) to ensure the rapid repair of the link interruption problem. In addition, the delayed reporting mechanism batches error information in low-level interruption scenarios to reduce system load, while ensuring rapid response to serious errors in high-level interruption scenarios, balancing resource utilization and error handling efficiency.
[0068] The above-mentioned embodiment determines the reporting threshold by combining historical error data and other factors, monitors and determines the health status of the devices in the whitelist, and when the number of CE errors of a certain device exceeds the preset threshold, the monitoring system can respond quickly and report link interruption error information, including detailed data such as device ID, error type, number of errors and occurrence time, to help quickly locate and solve the problem. In addition, the whitelist system suppresses Surprise Link Down errors triggered by dense CE errors of End Points, effectively reducing false alarms and interference, so that the monitoring system can more accurately screen out Surprise Link Down abnormal error information that really needs to be processed. It improves the efficiency of equipment management, enhances the stability and reliability of the system, provides a strong guarantee for the continuous operation of the business, and reduces the risk of business interruption due to equipment failure.
[0069] In one embodiment, before monitoring the number of correctable errors of the terminal node device and reporting link interruption error information according to a preset threshold, the method further includes:
[0070] The system obtains the information to be verified of the terminal node device, determines whether the terminal node device is added to the whitelist based on the information to be verified of the terminal node device, and in response to the terminal node device being added to the whitelist, monitors the number of correctable errors of the terminal node device, and reports the link interruption error information according to the preset threshold; in response to the terminal node device not being added to the whitelist, the terminal node device is added to the whitelist. That is, when the downstream device is determined to be an End Point, the system obtains the information to be verified of the End Point, determines whether the End Point has been added to the whitelist, and performs subsequent operations based on whether it has been added to the whitelist; if it has been added to the whitelist, the Surprise Link Down report of the upstream link of this End Point is suppressed, and the SMI interruption is not triggered. If it has not been added to the whitelist, this End Point is added to the whitelist to reduce the number of false alarms.
[0071] In the above embodiment, when the system identifies that the downstream device is a terminal node, the information to be verified of the device is obtained, and it is determined whether it has been added to the whitelist, thereby optimizing the response speed and accuracy of the system. If the terminal node device has been added to the whitelist, the reporting of the Surprise Link Down error information of the upstream link is suppressed, thereby avoiding unnecessary interference such as SMI caused by false alarms. The stability and reliability of the system are improved, and the continuous operation of key services is ensured. For devices that have not yet been added to the whitelist, the End Point is automatically added to the whitelist, reducing the risk of false alarms caused by failure to update device information in a timely manner. By introducing a whitelist verification mechanism, the security and stability of the system are further enhanced, ensuring that only terminal node devices that meet the preset rules can be normally accessed and processed, thereby effectively preventing potential security risks. By dynamically managing and updating the whitelist, the system can better adapt to the ever-changing device environment and improve overall security and compliance.
[0072] In one embodiment, obtaining the information to be verified of the terminal node device includes:
[0073] Obtain and parse the terminal node device information, remove the redundant information of the terminal node device, generate the terminal node device information to be unified, convert the terminal node device information to be unified into a standard format, and generate the terminal node device information to be verified. Obtain and parse the terminal node device information, obtain the BDF information of the terminal node device, use regular expressions, XML / JSON parsers, etc. to convert the obtained BDF information into a structured data format, analyze the device information, identify and mark redundant or irrelevant information. Redundant information may include repeated data items, unnecessary device descriptions or irrelevant device states, etc., retain key information related to device identity authentication and verification, generate the terminal node device information to be unified, integrate the terminal node device information to be unified into a unified format or data structure, which can be an XML file, JSON object, database table structure, etc., encapsulate the converted standard format information into a data packet or object to be verified, that is, generate the terminal node device information to be verified; load the device information that has been added to the whitelist from the system, and this information has the same standard format storage as the information to be verified. Check the device information in the whitelist one by one, compare it with the information to be verified, and determine whether the terminal node device has been added to the whitelist.
[0074] The above-mentioned embodiment obtains and parses the BDF information of the device, and uses tools such as regular expressions to convert the device information into a data format with a clear structure and easy to process, thereby improving the readability and operability of the information. Further, by analyzing the device information, redundant or irrelevant information, such as repeated data items, unnecessary device descriptions, etc., is identified and eliminated, thereby reducing the workload of data processing and ensuring the accuracy and pertinence of the information. Based on this, key information directly related to device identity authentication and verification is retained, device information to be unified is generated, and the information to be unified is integrated into a unified format or data structure, thereby improving the efficiency of information exchange and sharing. The converted standard format information is encapsulated into a data packet or object to be verified. By checking the device information in the whitelist one by one and comparing it with the information to be verified, it is quickly and accurately determined whether the terminal node device has been added to the whitelist, effectively improving the security and efficiency of device management.
[0075] In one embodiment, the monitoring system continuously monitors the devices in the whitelist. When the CE error of the End Point is detected to be greater than the Surprise Link Down triggered by the preset threshold, the relevant error information is immediately collected, including but not limited to the error time, error type, device information and bus topology information. The collected link interruption error information is reported to the processing system. The processing system is usually a specially designed module or subsystem responsible for receiving, parsing and processing the error information from the monitoring system. After receiving the link interruption error information, the processing system sends a system management interruption request (SMI) to the central processing unit (CPU). After receiving the SMI, the CPU suspends the currently executing task and saves the status information of the current task (such as task ID, execution progress, etc.). The task information is stored in a specific area in the memory for subsequent resumption of execution. After completing the saving of the task information, the CPU switches to the management mode (also called SMI mode). In this mode, the CPU will execute the specific code or instruction provided by the processing system. In the management mode, the processing system starts to parse the link interruption error information and extracts key information such as the error time, error type, device information and bus topology information. Based on the parsed error information, the processing system further analyzes and determines the specific cause of the link interruption. Possible causes include hardware failure, driver errors, configuration problems, or power problems. Once the cause of the link interruption is determined, the processing system will take appropriate measures to deal with it. This may include restarting the device, updating the driver, adjusting the configuration, or repairing the hardware failure. After the processing is completed, the CPU restores the previously saved task information by accessing a specific area in the memory. After the CPU completes the task information recovery, it exits the management mode and continues the task from the pause point to ensure the normal operation of the system.
[0076] The above-mentioned embodiment avoids potential equipment failures and system interruptions by continuously monitoring whitelist devices and setting CE error thresholds, timely detecting and responding to Surprise Link Down events triggered by EndPoint intensive CE errors. When a link interruption is detected, the system quickly collects comprehensive error information, including error time, type, device information, and bus topology. The processing system is responsible for receiving and parsing error information and sending system management interrupt requests to the CPU to ensure that the CPU can intervene and handle emergencies in a timely manner. After receiving the request, the CPU can pause the current task, save the task status, and enter the management mode to execute specific processing codes or instructions. This mechanism ensures the efficiency and accuracy of the system when handling link interruptions, and also ensures the continuity of task execution and the stability of the system. Once the link interruption problem is resolved, the CPU can quickly resume the previous task execution, thereby minimizing the impact of equipment failure on business operations.
[0077] In one embodiment, specifically according to Figure 3 The escalation process shown executes the following example,
[0078] +-[0000:c0]-+-00.0Intel Corporation Device 09a2
[0079] +-00.1Intel Corporation Device 09a4
[0080] +-00.2Intel Corporation Device 09a3
[0081] +-00.4Intel Corporation Device 0b23
[0082] \-01.0-[с1-с6]---00.0-[c2-c6]--+-00.0-[c3]--+-00.0MellanoxTechnologies MT2910 Family[ConnectX-7]
[0083] +-00.1Mellanox Technologies MT2910 Family[ConnectX-7]
[0084] +-01.0-[с4----00.0NVIDIA Corporation Device 2329
[0085] +-02.0-[5]---00.0Samsung Electronics Co Ltd NVMe SSD ControllerPM9A1 / PM9A3 / 980PRO
[0086] +-1e.0-[c6]---00.0Broadcom / LSIPEX890xx PCle Gen 5Switch
[0087] +-[0000:8e]-+-00.0Intel Corporation Device 09a2
[0088] +-00.1Intel Corporation Device 09a4
[0089] +-00.2Intel Corporation Device 09a3
[0090] +-00.4Intel Corporation Device 0b23
[0091] \-01.0-[8f]--+-00.0Mellanox Technologies MT2910 Family[ConnectX-7]
[0092] \-00.1Mellanox Technologies MT2910 Family[ConnectX-7]
[0093] The downstream device BDF: c2:00.0 of the BDF: c1:00.0 where Surprise Link Down occurs is a Switch Bridge on the link. Then determine the downstream device type of this device.
[0094] If the BDF of the device connected to c2:00.0 is c3:00.0, this device is an End Point on the link, and the whitelist system is used to check whether it is in the whitelist system. If the BDF: c3:00.0 device is in the whitelist system, the Surprise Link Down report of the upstream link of this device is blocked and SMI is not triggered. If the BDF of the device connected to c2:01.0 is c4:00.0, this device is an End Point on the link, and the whitelist system is used to check whether it is in the whitelist system. If the BDF: c3:00.0 device is not a device in the whitelist system, it is added to the whitelist and monitored. According to the preset threshold, such as 30 times / minute PCIE device CE error, if the threshold is exceeded, the Surprise Link Down of the upstream link BDF: c2:01.0 is reported.
[0095] It should be understood that although Figure 1-3 The steps in the flowchart are shown in sequence as indicated by the arrows, but these steps are not necessarily executed in the order indicated by the arrows. Unless otherwise specified in this document, there is no strict order restriction for the execution of these steps, and these steps can be executed in other orders. Moreover, Figure 1-3 At least part of the steps may include multiple sub-steps or multiple stages. These sub-steps or stages are not necessarily executed at the same time, but can be executed at different times. The execution order of these sub-steps or stages is not necessarily sequential, but can be executed in turn or alternately with other steps or at least part of the sub-steps or stages of other steps.
[0096] In one embodiment, Figure 4 As shown, a link interruption error reporting device is provided, comprising: an acquisition module 21, a first judgment module 22, a reporting module 23, a second judgment module 24 and a processing module 25, wherein:
[0097] An acquisition module, configured to acquire link information of a disconnected link in response to the link being disconnected;
[0098] A first determination module, used to determine the device type of the disconnected device according to the link information;
[0099] A reporting module, configured to report link interruption error information in response to the device type of the disconnected device being a terminal node device;
[0100] A second determination module, configured to determine a device type of a downstream device in response to the device type of the disconnected device being an intermediate node device;
[0101] The processing module is used to process the link interruption error according to the device type of the downstream device and the preset rules.
[0102] In one embodiment, the first judgment module is used to judge the device type of the disconnected device based on the link information. The link information includes device information and bus topology information. The device information of the disconnected device is determined based on the link information; the connection information of the disconnected device is determined based on the bus topology information; and the device type of the disconnected device is determined based on the device information and connection information of the disconnected device.
[0103] In one embodiment, the processing module is used to process the link interruption error according to the preset rules according to the device type of the downstream device. According to the device type of the downstream device, processing the link interruption error according to the preset rules includes: in response to the device type of the downstream device being an intermediate node device, reporting the link interruption error information; in response to the device type of the downstream device being a terminal node device, acquiring and parsing the terminal node device information, removing the redundant information of the terminal node device, generating the terminal node device to be unified information, converting the terminal node device to be unified information into a standard format, generating the terminal node device to be verified information, judging whether the terminal node device is added to the whitelist according to the terminal node device to be verified information, and in response to the terminal node device being added to the whitelist, monitoring the number of correctable errors of the terminal node device, and reporting the link interruption error information according to the preset threshold; in response to the terminal node device not being added to the whitelist, adding the terminal node device to the whitelist. Setting the reporting threshold of the number of correctable errors, acquiring the number of correctable errors of the terminal node device within the preset time by monitoring, judging whether the number of correctable errors of the terminal node device exceeds the reporting threshold of the number of correctable errors, and reporting the link interruption error information if the number of correctable errors exceeds the preset threshold.
[0104] Obtain link interruption error information, which includes one or more of the following: error time, error type, device information and bus topology information. Report the link interruption error information to the processing system. In response to receiving the interruption error information, the processing system sends a system management interruption request to the central processing unit; in response to receiving the system management interruption request, the central processing unit suspends the current execution task, obtains the task information of the current execution task, stores the task information in the memory and enters the management mode; in response to the central processing unit entering the management mode, the processing system parses the link interruption error information; determines the cause of the link interruption according to the link interruption error information and processes it. In response to the completion of the processing, the task information is obtained through the memory; the central processing unit exits the management mode and resumes the execution of the task.
[0105] For the specific definition of the link interruption error reporting device, please refer to the definition of the link interruption error reporting method in the above text, which will not be repeated here. Each module in the above-mentioned link interruption error reporting device can be implemented in whole or in part by software, hardware and a combination thereof. The above-mentioned modules can be embedded in or independent of the processor in the computer device in the form of hardware, or can be stored in the memory in the computer device in the form of software, so that the processor can call and execute the operations corresponding to the above modules.
[0106] In one embodiment, a computer device is provided. The computer device may be a server, and its internal structure diagram may be as follows: Figure 5 As shown. The computer device includes a processor, a memory, a network interface and a database connected through a system bus. Among them, the processor of the computer device is used to provide computing and control capabilities. The memory of the computer device includes a non-volatile storage medium and an internal memory. The non-volatile storage medium stores an operating system, a computer program and a database. The internal memory provides an environment for the operation of the operating system and the computer program in the non-volatile storage medium. The database of the computer device is used to store data. The network interface of the computer device is used to communicate with an external terminal through a network connection. When the computer program is executed by the processor, a link interruption error reporting method is implemented.
[0107] Those skilled in the art will understand that Figure 5 The structure shown in the figure is only a block diagram of a part of the structure related to the solution of the present application, and does not constitute a limitation on the computer device to which the solution of the present application is applied. The specific computer device may include more or fewer components than those shown in the figure, or combine certain components, or have a different arrangement of components.
[0108] In one embodiment, a computer device is provided, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the following steps when executing the computer program:
[0109] In response to a link disconnection, obtaining link information of the disconnected link,
[0110] Determine the device type of the disconnected device based on the link information. The device types include intermediate node devices and terminal node devices. The intermediate node device is connected to the downstream device.
[0111] In response to the device type of the disconnected device being a terminal node device, a link interruption error message is reported,
[0112] In response to the device type of the disconnected device being an intermediate node device, determining the device type of the downstream device,
[0113] Link interruption errors are handled according to preset rules based on the device type of the downstream device.
[0114] In one embodiment, when the processor executes the computer program, the processor further implements the following steps:
[0115] Determine the device type of the disconnected device based on the link information. The link information includes device information and bus topology information. Determine the device information of the disconnected device based on the link information; determine the connection information of the disconnected device based on the bus topology information; and determine the device type of the disconnected device based on the device information and connection information of the disconnected device.
[0116] In one embodiment, when the processor executes the computer program, the processor further implements the following steps:
[0117] According to the device type of the downstream device, the link interruption error is processed according to the preset rules. According to the device type of the downstream device, the link interruption error is processed according to the preset rules, including: in response to the device type of the downstream device being an intermediate node device, the link interruption error information is reported; in response to the device type of the downstream device being a terminal node device, the terminal node device information is obtained and parsed, the terminal node device redundant information is removed, the terminal node device information to be unified is generated, the terminal node device information to be unified is converted into a standard format, the terminal node device information to be verified is generated, and whether the terminal node device is added to the whitelist is determined according to the terminal node device information to be verified. In response to the terminal node device being added to the whitelist, the number of correctable errors of the terminal node device is monitored, and the link interruption error information is reported according to the preset threshold; in response to the terminal node device not being added to the whitelist, the terminal node device is added to the whitelist. A threshold for reporting the number of correctable errors is set, the number of correctable errors of the terminal node device within a preset time is obtained by monitoring, and it is determined whether the number of correctable errors of the terminal node device exceeds the reporting threshold for the number of correctable errors. If the number of correctable errors exceeds the preset threshold, the link interruption error information is reported.
[0118] In one embodiment, when the processor executes the computer program, the processor further implements the following steps:
[0119] Obtain link interruption error information, which includes one or more of the following: error time, error type, device information and bus topology information. Report the link interruption error information to the processing system. In response to receiving the interruption error information, the processing system sends a system management interruption request to the central processing unit; in response to receiving the system management interruption request, the central processing unit suspends the current execution task, obtains the task information of the current execution task, stores the task information in the memory and enters the management mode; in response to the central processing unit entering the management mode, the processing system parses the link interruption error information; determines the cause of the link interruption according to the link interruption error information and processes it. In response to the completion of the processing, the task information is obtained through the memory; the central processing unit exits the management mode and resumes the execution of the task.
[0120] In one embodiment, a computer readable storage medium is provided, on which a computer program is stored, and when the computer program is executed by a processor, the following steps are implemented:
[0121] In response to a link disconnection, obtaining link information of the disconnected link,
[0122] Determine the device type of the disconnected device based on the link information. The device types include intermediate node devices and terminal node devices. The intermediate node device is connected to the downstream device.
[0123] In response to the device type of the disconnected device being a terminal node device, a link interruption error message is reported,
[0124] In response to the device type of the disconnected device being an intermediate node device, determining the device type of the downstream device,
[0125] Link interruption errors are handled according to preset rules based on the device type of the downstream device.
[0126] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:
[0127] Determine the device type of the disconnected device based on the link information. The link information includes device information and bus topology information. Determine the device information of the disconnected device based on the link information; determine the connection information of the disconnected device based on the bus topology information; and determine the device type of the disconnected device based on the device information and connection information of the disconnected device.
[0128] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:
[0129] According to the device type of the downstream device, the link interruption error is processed according to the preset rules. According to the device type of the downstream device, the link interruption error is processed according to the preset rules, including: in response to the device type of the downstream device being an intermediate node device, the link interruption error information is reported; in response to the device type of the downstream device being a terminal node device, the terminal node device information is obtained and parsed, the terminal node device redundant information is removed, the terminal node device information to be unified is generated, the terminal node device information to be unified is converted into a standard format, the terminal node device information to be verified is generated, and whether the terminal node device is added to the whitelist is determined according to the terminal node device information to be verified. In response to the terminal node device being added to the whitelist, the number of correctable errors of the terminal node device is monitored, and the link interruption error information is reported according to the preset threshold; in response to the terminal node device not being added to the whitelist, the terminal node device is added to the whitelist. A threshold for reporting the number of correctable errors is set, the number of correctable errors of the terminal node device within a preset time is obtained by monitoring, and it is determined whether the number of correctable errors of the terminal node device exceeds the reporting threshold for the number of correctable errors. If the number of correctable errors exceeds the preset threshold, the link interruption error information is reported.
[0130] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:
[0131] Obtain link interruption error information, which includes one or more of the following: error time, error type, device information and bus topology information. Report the link interruption error information to the processing system. In response to receiving the interruption error information, the processing system sends a system management interruption request to the central processing unit; in response to receiving the system management interruption request, the central processing unit suspends the current execution task, obtains the task information of the current execution task, stores the task information in the memory and enters the management mode; in response to the central processing unit entering the management mode, the processing system parses the link interruption error information; determines the cause of the link interruption according to the link interruption error information and processes it. In response to the completion of the processing, the task information is obtained through the memory; the central processing unit exits the management mode and resumes the execution of the task.
[0132] In one embodiment, a computer program product is provided, comprising a computer program, which, when executed by a processor, implements the following steps:
[0133] In response to a link disconnection, obtaining link information of the disconnected link,
[0134] Determine the device type of the disconnected device based on the link information. The device types include intermediate node devices and terminal node devices. The intermediate node device is connected to the downstream device.
[0135] In response to the device type of the disconnected device being a terminal node device, a link interruption error message is reported,
[0136] In response to the device type of the disconnected device being an intermediate node device, determining the device type of the downstream device,
[0137] Link interruption errors are handled according to preset rules based on the device type of the downstream device.
[0138] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:
[0139] Determine the device type of the disconnected device based on the link information. The link information includes device information and bus topology information. Determine the device information of the disconnected device based on the link information; determine the connection information of the disconnected device based on the bus topology information; and determine the device type of the disconnected device based on the device information and connection information of the disconnected device.
[0140] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:
[0141] According to the device type of the downstream device, the link interruption error is processed according to the preset rules. According to the device type of the downstream device, the link interruption error is processed according to the preset rules, including: in response to the device type of the downstream device being an intermediate node device, the link interruption error information is reported; in response to the device type of the downstream device being a terminal node device, the terminal node device information is obtained and parsed, the terminal node device redundant information is removed, the terminal node device information to be unified is generated, the terminal node device information to be unified is converted into a standard format, the terminal node device information to be verified is generated, and whether the terminal node device is added to the whitelist is determined according to the terminal node device information to be verified. In response to the terminal node device being added to the whitelist, the number of correctable errors of the terminal node device is monitored, and the link interruption error information is reported according to the preset threshold; in response to the terminal node device not being added to the whitelist, the terminal node device is added to the whitelist. A threshold for reporting the number of correctable errors is set, the number of correctable errors of the terminal node device within a preset time is obtained by monitoring, and it is determined whether the number of correctable errors of the terminal node device exceeds the reporting threshold for the number of correctable errors. If the number of correctable errors exceeds the preset threshold, the link interruption error information is reported.
[0142] In one embodiment, when the computer program is executed by a processor, the following steps are also implemented:
[0143] Obtain link interruption error information, which includes one or more of the following: error time, error type, device information and bus topology information. Report the link interruption error information to the processing system. In response to receiving the interruption error information, the processing system sends a system management interruption request to the central processing unit; in response to receiving the system management interruption request, the central processing unit suspends the current execution task, obtains the task information of the current execution task, stores the task information in the memory and enters the management mode; in response to the central processing unit entering the management mode, the processing system parses the link interruption error information; determines the cause of the link interruption according to the link interruption error information and processes it. In response to the completion of the processing, the task information is obtained through the memory; the central processing unit exits the management mode and resumes the execution of the task.
[0144] Those skilled in the art can understand that all or part of the processes in the above-mentioned embodiment methods can be completed by instructing the relevant hardware through a computer program, and the computer program can be stored in a non-volatile computer-readable storage medium. When the computer program is executed, it can include the processes of the embodiments of the above-mentioned methods. Among them, any reference to memory, storage, database or other media used in the embodiments provided in this application can include non-volatile and / or volatile memory. Non-volatile memory can include read-only memory (ROM), programmable ROM (PROM), electrically programmable ROM (EPROM), electrically erasable programmable ROM (EEPROM) or flash memory. Volatile memory can include random access memory (RAM) or external cache memory. As an illustration and not limitation, RAM is available in many forms, such as static RAM (SRAM), dynamic RAM (DRAM), synchronous DRAM (SDRAM), double data rate SDRAM (DDRSDRAM), enhanced SDRAM (ESDRAM), synchronous link (Synchlink) DRAM (SLDRAM), memory bus (Rambus) direct RAM (RDRAM), direct memory bus dynamic RAM (DRDRAM), and memory bus dynamic RAM (RDRAM).
[0145] The technical features of the above embodiments may be combined arbitrarily. To make the description concise, not all possible combinations of the technical features in the above embodiments are described. However, as long as there is no contradiction in the combination of these technical features, they should be considered to be within the scope of this specification.
[0146] The above-mentioned embodiments only express several implementation methods of the present application, and the descriptions thereof are relatively specific and detailed, but they cannot be understood as limiting the scope of the invention patent. It should be pointed out that, for a person of ordinary skill in the art, several variations and improvements can be made without departing from the concept of the present application, and these all belong to the protection scope of the present application. Therefore, the protection scope of the patent of the present application shall be subject to the attached claims.
Claims
1. A link interruption error reporting method, characterized in that: include, In response to a link disconnection, obtaining link information of the disconnected link, Determine the device type of the disconnected device according to the link information, the device type includes an intermediate node device and a terminal node device, and the intermediate node device is connected to a downstream device. In response to the device type of the disconnected device being the terminal node device, reporting link interruption error information, In response to the device type of the disconnected device being the intermediate node device, determining the device type of the downstream device, The link interruption error is processed according to a preset rule based on the device type of the downstream device.
2. The method according to claim 1, characterized in that: The link information includes device information and bus topology information, and the determining the device type of the disconnected device according to the link information includes: Determining device information of the disconnected device according to the link information; Determining connection information of the disconnected device according to the bus topology information; The device type of the disconnected device is determined according to the device information and connection information of the disconnected device.
3. The method according to claim 1, characterized in that In response to the device type of the disconnected device being the intermediate node device, determining the device type of the downstream device includes: In response to the device type of the downstream device being an intermediate node device, reporting the link interruption error information; In response to the device type of the downstream device being a terminal node device, the number of correctable errors of the terminal node device is monitored, and the link interruption error information is reported according to a preset threshold.
4. The method according to claim 3, characterized in that: The monitoring of the number of correctable errors of the terminal node device and reporting the link interruption error information according to a preset threshold includes: Set the reporting threshold for the number of correctable errors. By monitoring, the number of correctable errors of the terminal node device within a preset time is obtained. Determine whether the number of correctable errors of the terminal node device exceeds the reporting threshold of the number of correctable errors, If the number of correctable errors exceeds a preset threshold, the link interruption error information is reported.
5. The method according to claim 4, characterized in that Before monitoring the number of correctable errors of the terminal node device and reporting the link interruption error information according to a preset threshold, the method further includes: Get the terminal node device to be verified information, Determine whether the terminal node device is added to the whitelist according to the information to be verified of the terminal node device, In response to the terminal node device being added to the whitelist, monitoring the number of correctable errors of the terminal node device, and reporting the link interruption error information according to a preset threshold; In response to the terminal node device not being added to the whitelist, adding the terminal node device to the whitelist.
6. The method according to claim 5, characterized in that The obtaining of the terminal node device information to be verified includes: Obtain and parse terminal node device information, Remove redundant information of terminal node devices and generate information to be unified for terminal node devices. The terminal node device information to be unified is converted into a standard format to generate the terminal node device information to be verified.
7. The method according to any one of claims 1 to 6, characterized in that The reporting of link interruption error information includes: Acquire the link interruption error information, wherein the link interruption error information includes one or more of the following: error time, error type, device information, and bus topology information, reporting the link interruption error information to a processing system, In response to receiving the interrupt error information, the processing system sends a system management interrupt request to the central processing unit; In response to receiving the system management interrupt request, the central processing unit suspends the current execution task, Acquire task information of the currently executed task, store the task information into memory and enter management mode; In response to the central processor entering the management mode, the processing system parses the link interruption error information; Determine the cause of the link interruption according to the link interruption error information and handle it, In response to the processing being completed, acquiring task information through the memory; The central processing unit exits the management mode and resumes the execution task.
8. A link interruption error processing device, characterized in that: The device comprises: An acquisition module, configured to acquire link information of a disconnected link in response to the link being disconnected; A first determination module, configured to determine a device type of the disconnected device according to the link information; A reporting module, configured to report link interruption error information in response to the device type of the disconnected device being a terminal node device; A second determination module, configured to determine a device type of a downstream device in response to the device type of the disconnected device being an intermediate node device; The processing module is used to process the link interruption error according to a preset rule based on the device type of the downstream device.
9. A computer device comprising a memory, a processor and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the computer program, the steps of the method according to any one of claims 1 to 7 are implemented.
10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the computer program is executed by a processor, the steps of the method according to any one of claims 1 to 7 are implemented.
Citation Information
Patent Citations
Fault reason diagnosis method, device and equipment and readable storage medium
CN116088465A
Fault processing method, device and system
CN116724297A
Interrupt trigger equipment determination method and device
CN117971526A
PCIe fatal error rapid positioning method and system, electronic equipment and medium
CN118550747A
Method for expanding pcie system, pcie switching device, and pcie system
US20230161728A1