Server fault diagnosis method and device, electronic equipment and storage medium

The baseboard management controller (BMC) receives the interrupt signal of the CPU and determines the fault information from the MCA register, which solves the problem of BIOS hang when the server cannot correct the fault, realizes the precise location and reporting of faults, and improves the operation and maintenance of the server. efficiency.

CN118708394AActive Publication Date: 2024-09-27XINHUASAN INFORMATION TECH CO LTD
View PDF 8 Cites 0 Cited by

Patent Information

Application Number
CN202410871681.2
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-06-28
Publication Date
2024-09-27
Estimated Expiration
2044-06-28

AI Technical Summary

Technical Problem

When an uncorrectable fault occurs in an existing server, the BIOS may hang, making it impossible to perform fault diagnosis and accurately locate faulty components, affecting operation and maintenance efficiency.

Method used

The baseboard management controller (BMC) is used to receive the interrupt signal of the CPU, select the target register from the MCA register, determine the CPU or memory fault type and address, and report the fault information to the monitoring terminal to achieve out-of-band diagnosis and fault location.

Benefits of technology

Out-of-band diagnosis and reporting of server faults are realized through BMC, which improves the maintainability of the server, can accurately locate faulty components when the BIOS hangs, and improves the speed and accuracy of fault handling.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118708394A
    Figure CN118708394A
Patent Text Reader

Abstract

The invention provides a server fault diagnosis method and device, electronic equipment and a storage medium, the method is applied to a BMC, the BMC selects a target MCA register after receiving an interrupt signal sent by a CPU, and a target MCA memory indicates that the CPU or a memory fails and records a fault type and addresses of the failed CPU and the failed memory. When a CPU fault is determined based on the data stored in the target MCA register and the type of the fault is an uncorrectable fault type, reporting slot position information of the CPU to a monitoring end; when the memory fault is determined based on the data stored in the target MCA register and the type of the fault is an uncorrectable fault type, the identification information of the target memory with the fault is determined based on the address recorded by the target MCA register, the identification information is reported to the monitoring end, and the component with the fault is accurately positioned. Out-of-band diagnosis and reporting of server faults are achieved through the BMC, and the maintainability of the server is improved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of network communications, and in particular to a server fault diagnosis method, device, electronic device and storage medium. Background Art

[0002] Currently, server fault diagnosis is often performed through the BIOS (Basic Input Output System) in the server. However, when a UCE (Uncorrectable Error) occurs in the server, the BIOS may hang. At this time, the BIOS cannot be used to perform fault diagnosis, and the only option is to wait for the operation and maintenance personnel to manually restart the server. If the server restarts successfully, the BIOS will continue to perform fault diagnosis. If the server restart fails, the server fault information cannot be known. Summary of the invention

[0003] To overcome the problems existing in the related art, this specification provides a server fault diagnosis method, device, electronic device and storage medium.

[0004] The present application embodiment provides a server fault diagnosis method, which is applied to a baseboard management controller BMC in the server, wherein the server further includes N central processing units CPU, where N is greater than or equal to 1; the method includes:

[0005] Receive interrupt signals triggered by the CPU;

[0006] Selecting a target MCA register from all MCA registers connected to the CPU based on the interrupt signal; the target MCA register is used to indicate that the CPU or the memory associated with the CPU has a fault, the corresponding fault type when the CPU or the memory fails, and the address of the CPU or the memory where the fault occurs;

[0007] Determining that the CPU is faulty based on the target MCA register and the type of the fault is an uncorrectable fault type, reporting the slot information where the CPU is located to the monitoring end;

[0008] If a memory fault associated with the CPU is determined based on the target MCA register and the type of the fault is an uncorrectable fault type, identification information of the target memory where the fault occurs is determined based on the address recorded in the target MCA register, and the identification information of the target memory is reported to the monitoring end.

[0009] Optionally, the target MCA register is used to indicate that a component corresponding to the target MCA register in the server fails, a corresponding fault type when the component fails, and an address of the component; other MCA registers other than the target MCA register connected to the CPU indicate that the components corresponding to the other MCA registers in the server do not fail; and when a component corresponding to the MCA register fails, a value of a valid bit of the MCA register is a preset value;

[0010] The selecting a target MCA register from all MCA registers connected to the CPU based on the interrupt signal comprises:

[0011] After receiving the interrupt signal, an MCA register whose valid bit value is a preset value is selected from all MCA registers connected to the CPU as the target register.

[0012] Optionally, the selecting, from all MCA registers connected to the CPU, an MCA register whose valid bit value is a preset value as the target register includes:

[0013] A Mailbox 43h command is sent to the CPU so that the CPU determines the index number of the MCA register whose valid bit value is a preset value in each MCA register connected to the CPU, calls the Mailbox 44h command based on the index number to obtain the data stored in the MCA register whose valid bit value is the preset value, and sends the data stored in the MCA register whose valid bit value is the preset value to the BMC.

[0014] Optionally, the IPID subregister in the target MCA register is used to indicate a component corresponding to the target MCA register, wherein the component includes the CPU and a memory associated with the CPU;

[0015] The STATUS subregister in the target MCA register is used to indicate the error type of the component corresponding to the target MCA register that has a fault, and the error type includes a correctable error type and an uncorrectable error type;

[0016] When the IPID subregister in the target MCA register indicates that the component corresponding to the target MCA register is a CPU, and the STATUS subregister in the target MCA register indicates that the error type is an uncorrectable error type, it is determined that the CPU is faulty and the type of the fault is an uncorrectable fault type;

[0017] When the IPID subregister in the target MCA register indicates that the component corresponding to the target MCA register is a memory, and the STATUS subregister in the target MCA register indicates that the error type is an uncorrectable error type, it is determined that a memory fault associated with the CPU is present and the type of the fault is an uncorrectable fault type.

[0018] Optionally, after reporting the slot information where the CPU is located to the monitoring end, or reporting the identification information of the target memory to the monitoring end, the method further includes:

[0019] The server is controlled to restart based on the obtained restart configuration instruction for instructing the server to restart when a failure of an uncorrectable failure type occurs in the server.

[0020] Optionally, the interrupt signal is a signal generated when the CPU determines that a BIOS in the server fails.

[0021] The embodiment of the present application further provides a server fault diagnosis device, which is applied to a baseboard management controller BMC in the server, and the server further includes N central processing units CPU, where N is greater than or equal to 1; the device includes:

[0022] A signal receiving module, used for receiving an interrupt signal triggered by the CPU;

[0023] a register determination module, configured to select a target MCA register from all MCA registers connected to the CPU based on the interrupt signal; the target MCA register is used to indicate that the CPU or a memory associated with the CPU has a fault, a corresponding fault type when the CPU or the memory has a fault, and an address of the CPU or the memory where the fault occurs;

[0024] A first fault diagnosis module, configured to determine, based on the target MCA register, that the CPU is faulty and the type of the fault is an uncorrectable fault type, and then report the slot information where the CPU is located to a monitoring terminal;

[0025] The second fault diagnosis module is used to determine the memory fault associated with the CPU based on the target MCA register and the type of the fault is an uncorrectable fault type, then determine the identification information of the target memory where the fault occurs based on the address recorded in the target MCA register, and report the identification information of the target memory to the monitoring end.

[0026] Optionally, the target MCA register is used to indicate that a component corresponding to the target MCA register in the server fails, a corresponding fault type when the component fails, and an address of the component; other MCA registers other than the target MCA register connected to the CPU indicate that the components corresponding to the other MCA registers in the server do not fail; and when a component corresponding to the MCA register fails, a value of a valid bit of the MCA register is a preset value;

[0027] The selecting a target MCA register from all MCA registers connected to the CPU based on the interrupt signal comprises:

[0028] After receiving the interrupt signal, selecting an MCA register whose valid bit value is a preset value from all MCA registers connected to the CPU as the target register;

[0029] The step of selecting an MCA register whose valid bit value is a preset value from all MCA registers connected to the CPU as the target register comprises:

[0030] Sending a Mailbox 43h command to the CPU so that the CPU determines an index number of an MCA register whose valid bit value is a preset value in each MCA register connected to the CPU, calling a Mailbox 44h command based on the index number to obtain data stored in the MCA register whose valid bit value is the preset value, and sending the data stored in the MCA register whose valid bit value is the preset value to the BMC;

[0031] and / or, the IPID subregister in the target MCA register is used to indicate a component corresponding to the target MCA register, wherein the component includes the CPU and a memory associated with the CPU;

[0032] The STATUS subregister in the target MCA register is used to indicate the error type of the component corresponding to the target MCA register that has a fault, and the error type includes a correctable error type and an uncorrectable error type;

[0033] When the IPID subregister in the target MCA register indicates that the component corresponding to the target MCA register is a CPU, and the STATUS subregister in the target MCA register indicates that the error type is an uncorrectable error type, it is determined that the CPU is faulty and the type of the fault is an uncorrectable fault type;

[0034] When the IPID subregister in the target MCA register indicates that the component corresponding to the target MCA register is a memory, and the STATUS subregister in the target MCA register indicates that the error type is an uncorrectable error type, it is determined that a memory fault associated with the CPU is present and the type of the fault is an uncorrectable fault type;

[0035] And / or, after reporting the slot information where the CPU is located to the monitoring end, or reporting the identification information of the target memory to the monitoring end, further comprising:

[0036] Controlling the server to restart based on the obtained restart configuration instruction for indicating that the server should restart when a failure of an uncorrectable failure type occurs in the server;

[0037] And / or, the interrupt signal is a signal generated when the CPU determines that a BIOS in the server fails.

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

[0039] Processor; and

[0040] A memory, wherein computer program instructions are stored in the memory, and when the computer program instructions are executed by the processor, the processor is caused to perform the steps in any one of the above methods.

[0041] An embodiment of the present application provides a storage medium, on which computer program instructions are stored. When the computer program instructions are executed by a processor, the processor is caused to execute the steps in any one of the above methods.

[0042] The beneficial effect of the present application is to provide a server fault diagnosis method, device, electronic device and storage medium. The method is applied to the BMC in the server. After receiving the interrupt signal sent by the CPU, the BMC selects a target MCA register from all MCA registers connected to the CPU. The target MCA register indicates that the CPU or memory has a fault, and records the fault type and the address of the CPU and memory where the fault occurs. When the CPU fault is determined based on the data stored in the target MCA register and the fault type is an uncorrectable fault type, the slot information where the CPU is located is reported to the monitoring end; when the memory fault is determined based on the data stored in the target MCA register and the fault type is an uncorrectable fault type, the identification information of the target memory of the fault is determined based on the address recorded in the target MCA register, and the identification information is reported to the monitoring end to accurately locate the faulty component. Out-of-band diagnosis and reporting of server faults are achieved through BMC, improving the maintainability of the server. BRIEF DESCRIPTION OF THE DRAWINGS

[0043] The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the specification and, together with the description, serve to explain the principles of the specification.

[0044] Figure 1 A first flow chart of a server fault diagnosis method provided in an embodiment of the present application;

[0045] Figure 2 A second flow chart of a server fault diagnosis method provided in an embodiment of the present application;

[0046] Figure 3 A third flow chart of a server fault diagnosis method provided in an embodiment of the present application;

[0047] Figure 4 A fourth flow chart of a server fault diagnosis method provided in an embodiment of the present application;

[0048] Figure 5 A schematic diagram of the structure of a server fault diagnosis device provided in an embodiment of the present application;

[0049] Figure 6 A schematic diagram of the structure of an electronic device provided in an embodiment of the present application. DETAILED DESCRIPTION

[0050] In order to enable those skilled in the art to better understand the technical solutions provided by the embodiments of the present application and to make the above-mentioned purposes, features and advantages of the embodiments of the present application more obvious and understandable, the technical solutions in the embodiments of the present application are further described in detail below in conjunction with the accompanying drawings.

[0051] Currently, server fault diagnosis relies on the BIOS in the server. However, when an uncorrectable fault occurs in the server, the BIOS may hang, and the server cannot be diagnosed. To this end, the present application provides a method for collecting and diagnosing fault information out-of-band using the BMC in the server. The BMC is a dedicated component for monitoring and managing the server. When other components in the server fail, the function of the BMC is not affected. When the BIOS hangs and fault diagnosis cannot be performed, the BMC in the server can also locate and report information about the failed CPU or memory.

[0052] Please refer to Figure 1 , Figure 1 A first flow chart of a server fault diagnosis method provided in an embodiment of the present application, the method is applied to a baseboard management controller BMC in a server, the server further includes N central processing units CPU, N is greater than or equal to 1; the method includes:

[0053] S101, receiving an interrupt signal triggered by the CPU.

[0054] The server includes multiple CPUs, each of which is connected to the BMC. For each CPU, when a CPU fails or a memory associated with the CPU fails, the CPU sends an interrupt signal to the BMC. For example, when a CPU fails or a memory associated with the CPU fails, the CPU sends an APML ALERT signal to the BMC through the APML (Advanced Platform Management Link) interface, and the APML ALERT signal is equivalent to the above interrupt signal.

[0055] In addition, the CPU can further determine whether the BIOS in the server is faulty. When an uncorrectable fault occurs in the CPU or the memory connected to the CPU, if the CPU detects that the BIOS function is normal, the CPU may not send an interrupt signal to the BMC, and the BIOS continues to complete the collection and diagnosis of fault information; if the CPU detects that the BIOS function is abnormal, the CPU sends an interrupt signal to the BMC, so that when an uncorrectable fault occurs in the server and the BIOS hangs, the fault information of the faulty component can be collected and reported in an out-of-band transmission manner.

[0056] S102, selecting a target MCA register from all MCA registers connected to the CPU based on the interrupt signal; the target MCA register is used to indicate that a CPU or a memory associated with the CPU has a fault, a corresponding fault type when the CPU or memory has a fault, and an address of the CPU or memory where the fault occurs.

[0057] The server in this application supports the MCA (Machine Check Architecture, hardware error detection architecture) mechanism, and the MCA mechanism is used to detect server failures. The MCA mechanism uses MCA registers, and these MCA registers can be used to detect and record hardware failures. The server includes multiple types of MCA registers, and each MCA register is used to record the failure information of its corresponding component. For example, the UMC register is used to store the corresponding memory-related failure information, the LS register is used to store the corresponding cache-related failure information, and the L2 is used to store the corresponding secondary cache error information. The data stored in the MCA register can be used to determine whether the component corresponding to the MCA register has a failure, the type of failure when a failure occurs, and the address of the failed component.

[0058] After receiving the interrupt signal, the BMC selects the target MCA register from all the MCA registers connected to the CPU. The target MCA register refers to the MCA register whose corresponding component (CPU or memory associated with the CPU) fails. The address of the failed component and the type of failure can be determined through the data stored in the target MCA register.

[0059] S103: Determine based on the target MCA register that the CPU is faulty and the fault type is an uncorrectable fault type, and report the slot information where the CPU is located to the monitoring end.

[0060] S104, determining a memory fault associated with the CPU based on the target MCA register and the type of the fault is an uncorrectable fault type, determining identification information of the target memory where the fault occurs based on the address recorded in the target MCA register, and reporting the identification information of the target memory to the monitoring end.

[0061] Server failures can be divided into correctable failure types and uncorrectable failure types. Among them, uncorrectable failure types usually cause server downtime. Therefore, when a server fails with an uncorrectable failure type, it is necessary to locate the faulty component in a timely manner and report relevant information so that the operation and maintenance personnel can quickly replace the faulty component.

[0062] In the present application, when it is determined based on the target MCA register that the CPU in the server is faulty and the fault type is an uncorrectable fault type, the slot information of the CPU is reported to the monitoring end. The present application does not specifically limit how to determine the slot information of the CPU. For example, the CPLD (Complex Programmable Logic Device) in the server detects the CPU that sends an interrupt signal, and feeds back the slot information corresponding to the CPU that sends the interrupt signal to the BMC, so that the BMC reports the slot information of the CPU to the monitoring end.

[0063] In the present application, when it is determined based on the target MCA register that the memory in the server fails and the type of the fault is an uncorrectable fault type, the identification information of the failed memory is determined based on the address recorded in the target MCA register. The present application does not specifically limit the identification information of the memory, as long as the identification information can be used to determine the unique corresponding memory. For example, the machine silk screen of the memory is used as the identification information of the memory. The target MCA register stores the system address of the failed memory, and the system address of the failed memory needs to be converted into a physical address according to the memory insertion method, capacity and CPU type of the server. Taking AMD Genoa CPU as an example, each CPU supports 12 memories. When the server is powered on and initialized, the mapping relationship between the system address and the physical address of the memory will be determined. For example, the system address with a value of 0x12345678 corresponds to the physical address of CPU0IMC1. The physical address of the memory can be further converted into the machine silk screen corresponding to the memory, and the corresponding relationship between the two is defined by the json file when the server is designed. For example, the machine silk screen corresponding to the memory with the physical address of CPU0IMC1 is CPU1CH6DIMM0. Finally, the identification information of the target memory is reported to the monitoring end so that the operation and maintenance personnel can replace the faulty target memory in time.

[0064] In summary, the present application provides a server fault diagnosis method, which is applied to the BMC in the server. After receiving the interrupt signal sent by the CPU, the BMC selects a target MCA register from all MCA registers connected to the CPU. The target MCA register indicates that the CPU or memory has a fault, and records the fault type and the address of the CPU and memory where the fault occurs. When a CPU fault is determined based on the data stored in the target MCA register and the fault type is an uncorrectable fault type, the slot information where the CPU is located is reported to the monitoring end; when a memory fault is determined based on the data stored in the target MCA register and the fault type is an uncorrectable fault type, the identification information of the target memory of the fault is determined based on the address recorded in the target MCA register, and the identification information is reported to the monitoring end to accurately locate the faulty component. Out-of-band diagnosis and reporting of server faults are achieved through BMC, improving the maintainability of the server.

[0065] Based on the above embodiments:

[0066] As an optional embodiment, the target MCA register is used to indicate that a component corresponding to the target MCA register in the server has a fault, the corresponding fault type when the component has a fault, and the address of the component; other MCA registers connected to the CPU except the target MCA register indicate that the components corresponding to the other MCA registers in the server have not a fault; and when a component corresponding to the MCA register has a fault, the value of the valid bit of the MCA register is a preset value.

[0067] Selecting a target MCA register from all MCA registers connected to the CPU based on an interrupt signal includes: after receiving the interrupt signal, selecting an MCA register whose valid bit value is a preset value from all MCA registers connected to the CPU as the target register.

[0068] In this embodiment, when a component corresponding to an MCA register fails, the value of the valid bit of the MCA register is set to a preset value. Therefore, when the BMC selects a target MCA register from all MCA registers after obtaining an interrupt signal, the target MCA register can be selected based on whether the value of the valid bit of each MCA is a preset value. The value of the valid bit of the target MCA register is a preset value, indicating that a component corresponding to the target MCA register has failed. Other information stored in the target MCA register can indicate the type of failure and the address of the failed component. The values ​​of the valid bits of other MCA registers connected to the CPU except the target MCA register are not preset values, and the components corresponding to other MCA registers connected to the CPU except the target MCA register have not failed.

[0069] As an optional embodiment, selecting an MCA register whose valid bit value is a preset value from all MCA registers connected to the CPU as the target register includes:

[0070] A Mailbox 43h command is sent to the CPU so that the CPU determines the index number of the MCA register whose valid bit value is a preset value in each MCA register connected to the CPU, calls the Mailbox 44h command based on the index number to obtain the data stored in the MCA register whose valid bit value is the preset value, and sends the data stored in the MCA register whose valid bit value is the preset value to the BMC.

[0071] The present application uses the data stored in the target MCA register to determine whether the type of fault is a correctable fault type or an uncorrectable fault type, thereby determining whether it is necessary to locate the faulty component and whether it is necessary to report the information of the faulty component to the monitoring end. When the data stored in the target MCA register is used to determine that the type of fault is an uncorrectable fault type, it is necessary to further determine the relevant fault information of the faulty component based on the data stored in the target MCA register. In this embodiment, the BMC obtains the data stored in the target MCA register through the MailBox service. Specifically, after receiving the interrupt signal, the BMC sends a Mailbox 43h command to the CPU. The content collected by the MailBox 43h command includes indexnumber. The index number can scan the target MCA register whose valid bit value is set to a preset value in all MCA registers connected to the CPU. Then the Mailbox 44h command is called using the index number to obtain the data stored in the MCA register whose valid bit value is a preset value. Finally, the CPU sends the data stored in the MCA register whose valid bit value is a preset value to the BMC.

[0072] It should be noted that when the CPU in the server fails, the functions involving the MCA mechanism in the CPU will not be affected, and the transmission channel (such as APML) between the CPU and the BMC can still normally transmit interrupt signals, commands involved in MailBoxservice, and data stored in the target MCA register.

[0073] Please refer to Figure 2 , Figure 2 The second flow chart of a server fault diagnosis method provided by an embodiment of the present application. In the case of a BIOS hang in the server, the APML interface and MailBox service are used to achieve the purpose of collecting CPU fault information and memory fault information out of band. The BMC receives interrupt signals through the APML interface and collects data stored in the target MCA register based on the MailBox service. After collecting the fault information of the faulty component stored in the MCA register, the fault information is parsed and reported. Figure 2 As shown, when the CPU fails and the fault type is an uncorrectable fault type, the slot information of the faulty CPU is reported to the monitoring end; when the memory fails and the fault type is an uncorrectable fault type, the identification information of the faulty memory, that is, the machine silk screen, is reported to the monitoring end, accurately indicating the specific location of the faulty component, which is convenient for operation and maintenance personnel to repair or replace the faulty component.

[0074] Specifically, the MCA register includes sub-registers such as the IPID sub-register, the STATUS sub-register, and the ADDR sub-register. The IPID sub-register in the target MCA register is used to indicate the component corresponding to the target MCA register, and the components include the CPU and the memory associated with the CPU. For example, when it is determined that the MCA register belongs to the UMC register based on the IPID sub-register in the target MCA register, it is considered that the component corresponding to the target MCA register belongs to the memory, and then it is determined that a memory-related fault occurs in the server; when it is determined that the MCA register belongs to another type of MCA register other than the UMC register based on the IPID sub-register in the target MCA register, it is considered that the component corresponding to the target MCA register belongs to the CPU, and then it is determined that a CPU-related fault occurs in the server. The above matching rules can be stored in the mca.json file to facilitate subsequent maintenance and optimization of faulty component location.

[0075] The STATUS subregister in the target MCA register is used to indicate the error type of the component corresponding to the target MCA register, and the error type includes a correctable error type and an uncorrectable error type. When the IPID subregister in the target MCA register indicates that the component corresponding to the target MCA register is the CPU, and the STATUS subregister in the target MCA register indicates that the error type is an uncorrectable error type, it is determined that the CPU is faulty and the type of the fault is an uncorrectable fault type; when the IPID subregister in the target MCA register indicates that the component corresponding to the target MCA register is the memory, and the STATUS subregister in the target MCA register indicates that the error type is an uncorrectable error type, it is determined that the memory associated with the CPU is faulty and the type of the fault is an uncorrectable fault type.

[0076] For example, after the data stored in the target MCA register is collected, the data stored in the target MCA register is saved to the AMD_MCA_result.rst file of the SD card, and the file is parsed. Part of the collected content of the file is shown below:

[0077] MCA_CTL_SMU: 0x7ff;

[0078] MCA_STATUS_SMU:0xbaa020000000011b;

[0079] MCA_ADDR_SMU: 0x0, MCA_MISC0_SMU: 0xd00d0fff00000000;

[0080] MCA_CONFIG_SMU:0x23000001fb;

[0081] MCA_IPID_SMU:0x1000103b30400;

[0082] MCA_SYND_SMU: 0xd0419a0;

[0083] MCA_CTL_MASK_SMU: 0x0;

[0084] MCA_TRANSSYND_SMU: 0x0;

[0085] MCA_TRANSADDR_SMU: 0x0;

[0086] It can be seen that the BMC collects the data stored in the target MCA register, including the IPID subregister, ADDR subregister, STATUS subregister, CTL subregister, etc. The subregisters involved in the analysis are mainly the IPID subregister, ADDR subregister, and STATUS subregister.

[0087] When the target MCA register is a UMC register, the server fault is determined to be a memory fault; when the target MCA register is an LS register, an LF register, an L2 register, an L3 register, etc., the server fault is determined to be a CPU fault. The correspondence between the MCA register type and the type of the faulty component can be pre-specified, so that after locking the target MCA register, it can be determined whether the server has a memory fault or a CPU fault based on the correspondence between the type of the target MCA register and the type of the faulty component.

[0088] Please refer to Figure 3 and Figure 4 , Figure 3 A third flow chart of a server fault diagnosis method provided in an embodiment of the present application, Figure 4 The fourth flow chart of a server fault diagnosis method provided by an embodiment of the present application. When the MCA register is a UMC register, the ADDR register in the MCA register stores the system address of the fault memory. When the MCA register is not a UMC register (e.g. Figure 4LF register in the MCA register), the ADDR register in the MCA register stores the system address of the faulty CPU. The STATUS subregister records the error type and specific error information. When bit

[63] =1, the MCA register is valid (indicating that the component corresponding to the MCA register is the faulty component), and bit

[61] represents whether the fault type is a correctable fault type or an uncorrectable fault type. In addition, the detailed fault information of the faulty component can be obtained based on the value of the bit corresponding to ErrorCodeExt in the STATUS subregister and the correspondence between ErrorCodeExt and ErrorTypeDes. The detailed fault information includes but is not limited to DRAM ECC error (dynamic random access memory error correction code error), Write Data Poison error, SdpParity error, etc., which are not specifically limited in this application.

[0089] As an optional embodiment, after reporting the slot information where the CPU is located to the monitoring end, or reporting the identification information of the target memory to the monitoring end, the method further includes:

[0090] The server is controlled to be restarted based on the obtained restart configuration instruction for instructing the server to restart when a failure of an uncorrectable failure type occurs in the server.

[0091] In the face of a server failure that causes system downtime, operation and maintenance personnel usually have two needs: the first is to automatically restart the server so that the server can resume operation as soon as possible and minimize losses; the second is not to automatically restart the server, and after uploading the information of the faulty component to the monitoring end, wait for the operation and maintenance personnel to check, and quickly locate the faulty component and collect more abnormal information by retaining the on-site environment. Therefore, in this embodiment, when an uncorrectable fault type occurs in the CPU or memory in the server, the user is supported to choose whether to restart the server. The user can input a restart configuration instruction to the server in advance, and the restart configuration instruction is used to instruct the server to restart the server when an uncorrectable fault type occurs. When an uncorrectable fault type occurs in the server, the BMC reports the slot information where the CPU is located to the monitoring end, or reports the identification information of the target memory to the monitoring end, and then the BMC controls the server to restart. When an uncorrectable fault type occurs in the server, but the restart configuration instruction is not received, the on-site environment is retained so that the operation and maintenance personnel can collect more fault information.

[0092] Please refer to Figure 5 , Figure 5A schematic diagram of the structure of a server fault diagnosis device provided in an embodiment of the present application. The embodiment of the present application also provides a server fault diagnosis device, which is applied to a baseboard management controller BMC in a server, wherein the server further includes N central processing units CPU, where N is greater than or equal to 1; the device includes:

[0093] A signal receiving module 501 is used to receive an interrupt signal triggered by the CPU;

[0094] The register determination module 502 is used to select a target MCA register from all MCA registers connected to the CPU based on the interrupt signal; the target MCA register is used to indicate that the CPU or the memory associated with the CPU has a fault, the corresponding fault type when the CPU or the memory has a fault, and the address of the CPU or the memory where the fault occurs;

[0095] A first fault diagnosis module 503, configured to determine a CPU fault based on a target MCA register and report the slot information where the CPU is located to a monitoring terminal if the fault type is an uncorrectable fault type;

[0096] The second fault diagnosis module 504 is used to determine the memory fault associated with the CPU based on the target MCA register and the type of the fault is an uncorrectable fault type, then determine the identification information of the target memory where the fault occurs based on the address recorded in the target MCA register, and report the identification information of the target memory to the monitoring end.

[0097] Based on the above embodiments:

[0098] As an optional embodiment, the target MCA register is used to indicate that a component corresponding to the target MCA register in the server fails, the corresponding fault type when the component fails, and the address of the component; other MCA registers other than the target MCA register connected to the CPU indicate that the components corresponding to the other MCA registers in the server do not fail; and when the component corresponding to the MCA register fails, the value of the valid bit of the MCA register is a preset value;

[0099] Select the target MCA register from all MCA registers connected to the CPU based on the interrupt signal, including:

[0100] After receiving the interrupt signal, an MCA register whose valid bit value is a preset value is selected from all MCA registers connected to the CPU as a target register;

[0101] Select an MCA register whose valid bit value is a preset value from all MCA registers connected to the CPU as the target register, including:

[0102] Sending a Mailbox 43h command to the CPU so that the CPU determines the index number of the MCA register whose valid bit value is a preset value in each MCA register connected to the CPU, calling the Mailbox 44h command based on the index number to obtain the data stored in the MCA register whose valid bit value is the preset value, and sending the data stored in the MCA register whose valid bit value is the preset value to the BMC;

[0103] and / or, the IPID subregister in the target MCA register is used to indicate a component corresponding to the target MCA register, the component including a CPU and a memory associated with the CPU;

[0104] The STATUS subregister in the target MCA register is used to indicate the error type of the component corresponding to the target MCA register. The error type includes a correctable error type and an uncorrectable error type.

[0105] When the IPID subregister in the target MCA register indicates that the component corresponding to the target MCA register is a CPU, and the STATUS subregister in the target MCA register indicates that the error type is an uncorrectable error type, it is determined that the CPU is faulty and the fault type is an uncorrectable fault type;

[0106] When the IPID subregister in the target MCA register indicates that the component corresponding to the target MCA register is a memory, and the STATUS subregister in the target MCA register indicates that the error type is an uncorrectable error type, it is determined that a memory fault associated with the CPU is a memory fault type and the fault type is an uncorrectable fault type;

[0107] And / or, after reporting the slot information where the CPU is located to the monitoring end, or reporting the identification information of the target memory to the monitoring end, it also includes:

[0108] Controlling the restart of the server based on the obtained restart configuration instruction for instructing the server to restart when a failure of an uncorrectable failure type occurs in the server;

[0109] And / or, the interrupt signal is a signal generated when the CPU determines that a BIOS in the server fails.

[0110] For a detailed introduction to the server fault diagnosis device provided in this application, please refer to the above-mentioned embodiment of the server fault diagnosis method, and this application will not elaborate on it here.

[0111] Please refer to Figure 6 , Figure 6A schematic diagram of the structure of an electronic device provided in an embodiment of the present application. An embodiment of the present application provides an electronic device, the electronic device comprising: a processor 601 and a memory 602, wherein the memory 602 stores computer program instructions, and when the computer program instructions are executed by the processor 601, the processor 601 executes the steps in any of the above methods.

[0112] For a detailed introduction to the electronic device provided in this application, please refer to the above-mentioned server fault diagnosis method embodiment, and this application will not go into details here.

[0113] An embodiment of the present application provides a storage medium on which computer program instructions are stored. When the computer program instructions are executed by a processor, the processor executes the steps in any one of the above methods.

[0114] For a detailed introduction to the storage medium provided in this application, please refer to the above-mentioned server fault diagnosis method embodiment, and this application will not elaborate on it here.

[0115] In this specification, the terms "comprises", "comprising" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device comprising a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, an element defined by the sentence "comprising a ..." does not exclude the presence of other identical elements in the process, method, article or device comprising the element.

[0116] The above description of the disclosed embodiments enables those skilled in the art to implement or use the present application. Various modifications to these embodiments will be apparent to those skilled in the art, and the general principles defined herein may be implemented in other embodiments without departing from the spirit or scope of the present application. Therefore, the present application will not be limited to the embodiments shown herein, but will conform to the widest scope consistent with the principles and novel features disclosed herein.

Claims

1. A server fault diagnosis method, characterized in that: A baseboard management controller BMC is applied to the server, wherein the server further includes N central processing units CPU, where N is greater than or equal to 1; and the method includes: Receive interrupt signals triggered by the CPU; Selecting a target MCA register from all MCA registers connected to the CPU based on the interrupt signal; the target MCA register is used to indicate that the CPU or the memory associated with the CPU has a fault, the corresponding fault type when the CPU or the memory fails, and the address of the CPU or the memory where the fault occurs; Determining that the CPU is faulty based on the target MCA register and the type of the fault is an uncorrectable fault type, reporting the slot information where the CPU is located to the monitoring end; If a memory fault associated with the CPU is determined based on the target MCA register and the type of the fault is an uncorrectable fault type, identification information of the target memory where the fault occurs is determined based on the address recorded in the target MCA register, and the identification information of the target memory is reported to the monitoring end.

2. The server fault diagnosis method according to claim 1, characterized in that: The target MCA register is used to indicate that a component corresponding to the target MCA register in the server fails, the corresponding fault type when the component fails, and the address of the component; other MCA registers other than the target MCA register connected to the CPU indicate that the components corresponding to the other MCA registers in the server do not fail; and when a component corresponding to the MCA register fails, the value of the valid bit of the MCA register is a preset value; The selecting a target MCA register from all MCA registers connected to the CPU based on the interrupt signal comprises: After receiving the interrupt signal, an MCA register whose valid bit value is a preset value is selected from all MCA registers connected to the CPU as the target register.

3. The server fault diagnosis method according to claim 2, characterized in that: The step of selecting an MCA register whose valid bit value is a preset value from all MCA registers connected to the CPU as the target register comprises: A Mailbox 43h command is sent to the CPU so that the CPU determines the index number of the MCA register whose valid bit value is a preset value in each MCA register connected to the CPU, calls the Mailbox44h command based on the index number to obtain the data stored in the MCA register whose valid bit value is the preset value, and sends the data stored in the MCA register whose valid bit value is the preset value to the BMC.

4. The server fault diagnosis method according to claim 1, characterized in that: The IPID subregister in the target MCA register is used to indicate a component corresponding to the target MCA register, wherein the component includes the CPU and a memory associated with the CPU; The STATUS subregister in the target MCA register is used to indicate the error type of the component corresponding to the target MCA register that has a fault, and the error type includes a correctable error type and an uncorrectable error type; When the IPID subregister in the target MCA register indicates that the component corresponding to the target MCA register is a CPU, and the STATUS subregister in the target MCA register indicates that the error type is an uncorrectable error type, it is determined that the CPU is faulty and the type of the fault is an uncorrectable fault type; When the IPID subregister in the target MCA register indicates that the component corresponding to the target MCA register is a memory, and the STATUS subregister in the target MCA register indicates that the error type is an uncorrectable error type, it is determined that a memory fault associated with the CPU is present and the type of the fault is an uncorrectable fault type.

5. The server fault diagnosis method according to claim 1, characterized in that: After reporting the slot information where the CPU is located to the monitoring end, or reporting the identification information of the target memory to the monitoring end, the method further includes: The server is controlled to restart based on the obtained restart configuration instruction for instructing the server to restart when a failure of an uncorrectable failure type occurs in the server.

6. The server fault diagnosis method according to claim 1, characterized in that: The interrupt signal is a signal generated when the CPU determines that a BIOS in the server fails.

7. A server fault diagnosis device, characterized in that: A baseboard management controller BMC applied to the server, wherein the server further comprises N central processing units CPU, where N is greater than or equal to 1; the device comprises: A signal receiving module, used for receiving an interrupt signal triggered by the CPU; a register determination module, configured to select a target MCA register from all MCA registers connected to the CPU based on the interrupt signal; the target MCA register is used to indicate that the CPU or a memory associated with the CPU has a fault, a corresponding fault type when the CPU or the memory has a fault, and an address of the CPU or the memory where the fault occurs; A first fault diagnosis module, configured to determine, based on the target MCA register, that the CPU is faulty and the type of the fault is an uncorrectable fault type, and then report the slot information where the CPU is located to a monitoring terminal; The second fault diagnosis module is used to determine the memory fault associated with the CPU based on the target MCA register and the type of the fault is an uncorrectable fault type, then determine the identification information of the target memory where the fault occurs based on the address recorded in the target MCA register, and report the identification information of the target memory to the monitoring end.

8. The server fault diagnosis device according to claim 7, characterized in that: The target MCA register is used to indicate that a component corresponding to the target MCA register in the server fails, the corresponding fault type when the component fails, and the address of the component; other MCA registers other than the target MCA register connected to the CPU indicate that the components corresponding to the other MCA registers in the server do not fail; and when a component corresponding to the MCA register fails, the value of the valid bit of the MCA register is a preset value; The selecting a target MCA register from all MCA registers connected to the CPU based on the interrupt signal comprises: After receiving the interrupt signal, selecting an MCA register whose valid bit value is a preset value from all MCA registers connected to the CPU as the target register; The step of selecting an MCA register whose valid bit value is a preset value from all MCA registers connected to the CPU as the target register comprises: Sending a Mailbox 43h command to the CPU so that the CPU determines an index number of an MCA register whose valid bit value is a preset value in each MCA register connected to the CPU, calling a Mailbox44h command based on the index number to obtain data stored in the MCA register whose valid bit value is the preset value, and sending the data stored in the MCA register whose valid bit value is the preset value to the BMC; and / or, the IPID subregister in the target MCA register is used to indicate a component corresponding to the target MCA register, wherein the component includes the CPU and a memory associated with the CPU; The STATUS subregister in the target MCA register is used to indicate the error type of the component corresponding to the target MCA register that has a fault, and the error type includes a correctable error type and an uncorrectable error type; When the IPID subregister in the target MCA register indicates that the component corresponding to the target MCA register is a CPU, and the STATUS subregister in the target MCA register indicates that the error type is an uncorrectable error type, it is determined that the CPU is faulty and the type of the fault is an uncorrectable fault type; When the IPID subregister in the target MCA register indicates that the component corresponding to the target MCA register is a memory, and the STATUS subregister in the target MCA register indicates that the error type is an uncorrectable error type, it is determined that a memory fault associated with the CPU is present and the type of the fault is an uncorrectable fault type; And / or, after reporting the slot information where the CPU is located to the monitoring end, or reporting the identification information of the target memory to the monitoring end, further comprising: Controlling the server to restart based on the obtained restart configuration instruction for indicating that the server should restart when a failure of an uncorrectable failure type occurs in the server; And / or, the interrupt signal is a signal generated when the CPU determines that a BIOS in the server fails.

9. An electronic device, characterized in that: The electronic device comprises: Processor; and A memory, wherein computer program instructions are stored in the memory, and when the computer program instructions are executed by the processor, the processor is caused to perform the steps in any one of the methods of claims 1 to 6.

10. A storage medium, characterized in that: The storage medium stores computer program instructions, which, when executed by a processor, enable the processor to execute the steps of any one of the methods of claims 1 to 6.

Citation Information

Patent Citations

  • Fault data processing method and device, server and computer readable storage medium

    CN109783262A

  • Memory fault positioning method and device

    CN112650612A

  • IPMI communication method, and sending system and receiving system for IPMI communication

    CN113190482A

  • Fault processing method and device, electronic equipment and storage medium

    CN113918375A

  • Fault recording and positioning method and device and server

    CN114706739A