Server failure information recording method, device, computer equipment and storage medium
By creating target tasks in the server and performing asynchronously to record fault information, the server performance degradation caused by correctable fault information is solved, and the effect of reducing network jitter and response delay is achieved.
Patent Information
- Application Number
- CN202411890480.3
- Authority / Receiving Office
- CN · China
- Patent Type
- Patents(China)
- Current Assignee / Owner
- Filing Date
- 2024-12-20
- Publication Date
- 2025-04-29
- Estimated Expiration
- 2044-12-20
AI Technical Summary
Recording fault information that corrects errors (CE) can lead to degradation of server performance, resulting in increased network jitter and response delays on the server.
After receiving the fault information recording request, the substrate management controller (BMC) creates a target task and performs the task asynchronously to record the fault information while returning the processing results to cause the central processor (CPU) to exit the preset mode as soon as possible.
By reducing the CPU's duration in preset mode, the impact of correctable errors on service performance is reduced, and the problems of network jitter and response delay are solved.
Smart Images

Figure CN119356989B_ABST
Abstract
Description
Technical Field
[0001] The present invention relates to the field of computer technology, and in particular to a method and device for recording server fault information, a computer device and a storage medium. Background Art
[0002] Errors in memory and PCIE devices can be divided into correctable errors (CE) and uncorrectable errors (UCE). Uncorrectable errors generally cause server downtime and require on-site maintenance personnel to replace new parts. Correctable errors can be self-repaired by the server system, and the server system can be used normally after repair. However, if CE occurs frequently, it will have a serious impact on the performance of the server system. This is because after CE is repaired by the server system, the server system needs to record CE fault information, such as: BMC (Baseboard Management Controller) records SEL (System Event Log, System Time Log), black box and other logs to BMC Flash (flash memory). The process of recording CE fault information requires CPU resources. Recording each fault information requires the CPU to enter SMM (System Management Mode) mode to process the fault information sent by BIOS (Basic Input Output System, Basic Input Output System) to BMC. After waiting for BMC to record the fault information and return the processing result, it can exit SMM mode and continue to process normal business data.
[0003] If the BIOS reports a large amount of CE fault information, the CPU needs to frequently enter the SMM mode to process these fault information reports, which will cause server performance to degrade, increase server network jitter and response delay, etc., affecting server services.
[0004] Therefore, the related technology has the problem that recording the fault information of CE will cause the server performance to decline, resulting in increased network jitter and response delay of the server. Summary of the invention
[0005] In view of this, the present invention provides a server fault information recording method, apparatus, computer equipment and storage medium to solve the problem that recording CE fault information may cause server performance degradation, increase server network jitter and response delay.
[0006] In a first aspect, the present invention provides a method for recording server fault information, which is applied to a baseboard management controller and includes:
[0007] In the case of receiving a preset number of fault information recording requests sent by the basic input and output system, creating a target task corresponding to the fault information recording request, wherein the target task is used to record the fault information corresponding to the fault information recording request;
[0008] Send the processing result corresponding to the fault information recording request to the basic input and output system, and execute the target task to complete the recording of the fault information, wherein the processing result is used to instruct the basic input and output system to control the central processor to exit the preset mode and continue to process business data.
[0009] In the server fault information recording method provided in this embodiment, after receiving the fault information recording request, the baseboard management controller first creates a target task, and then returns the processing result to the basic input and output system, so that the central processing unit exits the preset mode as soon as possible. At the same time, the target task is executed asynchronously to complete the recording of fault information. Through overall optimization, the length of time the central processing unit is in the preset mode during the fault information recording process is reduced, and the performance impact of the correctable errors of the components on the business is reduced. The problem that recording CE fault information will cause server performance to decline, resulting in increased network jitter and response delay of the server is solved.
[0010] In some optional implementations, creating a target task corresponding to the fault information record request includes:
[0011] Perform data integrity check on fault information record requests;
[0012] If the fault information record request verification passes, the target task is created.
[0013] In this implementation, by performing a data integrity check on the fault information recording request, it is possible to verify whether the format of the fault information recording request is correct, whether the parameters are valid, and whether the necessary authority information is included.
[0014] In some optional implementations, performing a data integrity check on the fault information recording request includes:
[0015] Obtaining structure data corresponding to the fault information record request, and determining whether the format of the structure data is the same as a preset format, wherein the preset format is used to verify the authority information of the fault information record request;
[0016] If they are the same, get the parameter type and number of parameters of the structure data;
[0017] If the parameter type is the same as the preset type, and the parameter quantity is the same as the preset value, the fault information record request verification passes.
[0018] In this embodiment, a data integrity check is performed on the fault information record request using a preset format, preset type, and preset value to ensure that the fault information record request format is correct, the parameters are valid, it contains necessary authority information, and has data integrity and parameter number integrity.
[0019] In some optional implementations, creating a target task corresponding to the fault information record request includes:
[0020] According to the fault information recording request, an asynchronous task is created inside the baseboard management controller, and the asynchronous task is used as a target task;
[0021] Add the target task to the task queue and obtain the priority of the target task in the task queue;
[0022] According to the priority, the execution order of the target tasks in the task queue is determined.
[0023] In this embodiment, based on the fault information recording request, an asynchronous task is created inside the baseboard management controller, and an asynchronous processing strategy is adopted to isolate the process part of the BMC recording error information, shorten the time the central processing unit is in the preset mode, and reduce the performance impact of the correctable errors of the components on the business.
[0024] In some optional implementations, performing the target task includes:
[0025] According to the task scheduler and execution order, determine the tasks to be executed in the task queue;
[0026] Call the information processing object to process the task to be executed, obtain the processed information, and call the log recording object to generate a fault information log based on the processed information;
[0027] Save the fault information log to the flash memory of the baseboard management controller.
[0028] In this embodiment, an asynchronous processing strategy is adopted to isolate the process part of the BMC recording error information, shorten the time the central processor is in the preset mode, and reduce the performance impact of the correctable errors of the components on the business.
[0029] In some optional implementations, after executing the target task, the method further includes:
[0030] Get the execution result of the target task;
[0031] Obtain log fragments according to the execution results, and write the log fragments into the fault information log;
[0032] When it is determined according to the execution result that the execution of the target task has failed, an error response is generated and returned to the target object.
[0033] In this embodiment, the execution results are converted into log fragments and written into the fault information log. The execution status of each target task can be determined through the fault information log, which is convenient for subsequent troubleshooting and performance optimization.
[0034] In some optional embodiments, the method further comprises:
[0035] Obtain process information for executing target tasks;
[0036] Generate a process log for executing the target task based on the process information and fault information record request.
[0037] In this embodiment, a process log for executing the target task is generated according to the process information of executing the target task and the fault information recording request, and the process log is used to record the entire AHCEE processing process to facilitate subsequent troubleshooting and performance optimization.
[0038] In some optional implementations, after executing the target task, the method further includes:
[0039] Determine the occupied resources corresponding to the target task in the baseboard management controller;
[0040] Release the occupied resources.
[0041] In this implementation, occupied resources are released, resource cleanup and recycling are achieved, resource utilization is improved, and correct release of resources is ensured to avoid resource leakage and performance issues.
[0042] In some optional embodiments, the method further comprises:
[0043] Determine whether a preset error occurs in the baseboard management controller during the execution of the target task;
[0044] If a preset error occurs, an error message is generated and output.
[0045] In this embodiment, it is determined whether a preset error occurs in the baseboard management controller. If a preset error occurs, an error message is generated and output to notify relevant personnel to handle it, thereby avoiding failure to record error information due to a fault in the baseboard management controller.
[0046] In a second aspect, the present invention provides a method for recording server fault information, the method being applied to a basic input and output system, comprising:
[0047] Obtaining fault information of the server, and generating a preset number of fault information record requests according to the fault information;
[0048] Sending a preset number of fault information record requests to a baseboard management controller, wherein the fault information record request is used to instruct the baseboard management controller to create a target task, the baseboard management controller is used to send a processing result corresponding to the fault information record request to the basic input and output system, and execute the target task, and the target task is used to record the fault information corresponding to the fault information record request;
[0049] When the processing result is received, the central processing unit is controlled to exit the preset mode and continue to process the business data.
[0050] The server fault information recording method provided in this embodiment is that the basic input-output system generates a preset number of fault information recording requests according to the fault information, sends the preset number of fault information recording requests to the baseboard management controller, and instructs the baseboard management controller to record the fault information. After receiving the fault information recording request, the baseboard management controller first creates a target task, and then returns the processing result to the basic input-output system, so that the central processing unit exits the preset mode as soon as possible. At the same time, the target task is executed asynchronously to realize the asynchronous processing of the BMC corresponding to the correctable error reporting record log, shorten the time the central processing unit is in the preset mode, and reduce the performance impact of the correctable errors of the components on the business. It solves the problem that recording CE fault information will cause the server performance to decline, resulting in increased network jitter and response delay of the server.
[0051] In some optional implementations, acquiring fault information of a server and generating a preset number of fault information record requests according to the fault information includes:
[0052] Monitor the server to determine if there are correctable errors in the server;
[0053] If a correctable error exists, obtain fault information of the correctable error;
[0054] Determine whether the amount of fault information is greater than or equal to a preset threshold;
[0055] If yes, a preset number of fault information record requests are generated according to the fault information.
[0056] In this embodiment, the BIOS is modified to reduce the CE reporting frequency of the memory in the same slot and the same address by setting a threshold, thereby preventing the central processor from frequently entering the preset mode and reducing the impact of frequent reporting of correctable errors on server performance.
[0057] In a third aspect, the present invention provides a server fault information recording device, which is deployed in a baseboard management controller and includes:
[0058] A task creation module, configured to create a target task corresponding to the fault information recording request upon receiving a preset number of fault information recording requests sent by the basic input and output system, wherein the target task is used to record the fault information corresponding to the fault information recording request;
[0059] The task execution module is used to send the processing result corresponding to the fault information recording request to the basic input and output system, and execute the target task to complete the recording of the fault information, wherein the processing result is used to instruct the basic input and output system to control the central processor to exit the preset mode and continue to process business data.
[0060] In a fourth aspect, the present invention provides a server fault information recording device, which is deployed in a basic input and output system, and includes:
[0061] An information acquisition module, used to acquire fault information of the server and generate a preset number of fault information record requests according to the fault information;
[0062] An information sending module, used for sending a preset number of fault information recording requests to a baseboard management controller, wherein the fault information recording request is used to instruct the baseboard management controller to create a target task, the baseboard management controller is used to send a processing result corresponding to the fault information recording request to a basic input and output system, and execute the target task, and the target task is used to record the fault information corresponding to the fault information recording request;
[0063] The control module is used to control the central processing unit to exit the preset mode and continue processing business data when receiving the processing result.
[0064] In a fifth aspect, the present invention provides a computer device, comprising: a memory and a processor, the memory and the processor are communicatively connected to each other, computer instructions are stored in the memory, and the processor executes the server fault information recording method of the above-mentioned first aspect or any corresponding embodiment thereof by executing the computer instructions, or executes the server fault information recording method of the above-mentioned second aspect or any corresponding embodiment thereof.
[0065] In a sixth aspect, the present invention provides a computer-readable storage medium having computer instructions stored thereon, the computer instructions being used to enable a computer to execute the server fault information recording method of the above-mentioned first aspect or any corresponding embodiment thereof, or to execute the server fault information recording method of the above-mentioned second aspect or any corresponding embodiment thereof.
[0066] In the seventh aspect, the present invention provides a computer program product, including computer instructions, which are used to enable a computer to execute the server fault information recording method of the above-mentioned first aspect or any corresponding embodiment thereof, or to execute the server fault information recording method of the above-mentioned second aspect or any corresponding embodiment thereof. BRIEF DESCRIPTION OF THE DRAWINGS
[0067] In order to more clearly illustrate the specific embodiments of the present invention or the technical solutions in the related technologies, the drawings required for use in the specific embodiments or the related technical descriptions will be briefly introduced below. Obviously, the drawings described below are some embodiments of the present invention. For ordinary technicians in this field, other drawings can be obtained based on these drawings without paying creative work.
[0068] Figure 1 is a schematic diagram of the current CE reporting process according to an embodiment of the present invention;
[0069] Figure 2 is a flow chart of a method for recording server fault information applied to a baseboard management controller according to an embodiment of the present invention;
[0070] Figure 3 is a flow chart of a method for recording server fault information applied to a basic input and output system according to an embodiment of the present invention;
[0071] Figure 4 is a flow chart of an optimization method for reducing network jitter and delay caused by CE storm in a server according to an embodiment of the present invention;
[0072] Figure 5 is a structural block diagram of a server fault information recording device deployed in a baseboard management controller according to an embodiment of the present invention;
[0073] Figure 6 is a structural block diagram of a server fault information recording device deployed in a basic input and output system according to an embodiment of the present invention;
[0074] Figure 7 It is a schematic diagram of the hardware structure of a computer device according to an embodiment of the present invention. DETAILED DESCRIPTION
[0075] In order to make the purpose, technical solution and advantages of the embodiments of the present invention clearer, the technical solution in the embodiments of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiments of the present invention. Obviously, the described embodiments are part of the embodiments of the present invention, not all of the embodiments. Based on the embodiments of the present invention, all other embodiments obtained by those skilled in the art without creative work are within the scope of protection of the present invention.
[0076] Memory is a key component that directly provides data cache to the central processing unit. If the memory fails, it will directly cause the processor to stop responding, resulting in system downtime. The capacity of memory has gradually increased, from hundreds of Mb to a maximum of hundreds of Gb. In order to achieve the increase in memory capacity, the storage density of memory is getting higher and higher, and the voltage of memory is getting lower and lower. On the contrary, the main frequency of memory is getting higher and higher. As a semiconductor device, the density of memory cells increases, the voltage decreases, and the main frequency increases. This sacrifices memory reliability in exchange for memory performance, resulting in an increase in memory failure rate. The same is true for PCIE (peripheral component interconnect express, a high-speed serial computer expansion bus standard) devices. The transmission rate of PCIE devices is constantly increasing, from 5GT / s to 8GT / s and 16GT / s. Due to the increase in the transmission rate between devices and the increasingly complex topology of the link, errors are prone to occur during the data transmission and reception of PCIE devices.
[0077] Therefore, it is necessary to handle the faults of memory and PCIE devices in a timely manner. Errors triggered by memory and PCIE devices can be divided into correctable errors (CE) and uncorrectable errors (UCE). Uncorrectable errors generally cause server downtime, requiring on-site maintenance personnel to replace new parts. Correctable errors can be self-repaired by the system, and the system can be used normally after repair, but if CE is frequently triggered, it will have a serious impact on the performance of the server system. Because after the correctable error is repaired by the hardware, the server system needs to record the hardware error information, such as the BMC recording the SEL (System Event Log, system time log) log, black box and other logs to the BMC Flash process, and the process of recording fault information requires CPU resources. Each CE record requires the CPU to enter the SMM mode to process the fault data sent by the BIOS to the BMC, and wait for the BMC to process the log record and return the processing result before exiting the SMM mode to continue processing normal business data. If the hardware reports a large number of CE errors, the CPU needs to frequently enter the SMM mode to process these fault information reports, which will cause the server performance to deteriorate, which is specifically manifested in network jitter and delay, which are not good for the business. It should be noted that the SMM system management mode is a unified standard architecture feature. When the external SMM interrupt pin (SMI#) is activated or an SMI (System Management Interrupt) is received from the APIC (Advanced Programming Interrupt Controller), the processor will enter SMM. Under SMM, the processor switches to a separate address space while saving the entire context of the currently running program. Then the code specified by SMM may be transparently executed. When returning from SMM, the processor will return to the state before the system management interrupt. BIOS is a program solidified on a ROM chip on the motherboard of the computer. It stores the most important basic input and output programs of the computer, the self-test program after power-on, and the system self-starting program. It can read and write specific information of system settings from CMOS. Its main function is to provide the lowest-level and most direct hardware settings and control for the computer. BMC realizes data collection, event recording, error diagnosis, troubleshooting and other management functions of the server through built-in FW (firmware) and sensors scattered on the baseboard, system board and chassis.
[0078] The current CE reporting process is as follows: Figure 1As shown, during the system operation, BIOS combines hardware to monitor memory or PCIE devices to correct error conditions. If CE is detected, the server system triggers SMI and tells the CPU to enter SMM mode to process the correctable error reporting process. The whole process includes: BIOS processes fault information and sends information to notify BMC through KCS (Keyboard Controller Style, keyboard management tool); BMC receives fault information sent by BIOS through KCS interface; BMC generates SEL record and triggers information processing program; BMC calls log writing Flash program, and related error logs are recorded in BMC Flash (flash memory) medium; after completing writing to Flash, the write processing result is returned, and the write processing success result is returned to the information processing program, and the information processing program returns to the KCS processing program. At this time, BIOS perceives that the BMC log processing and writing process have been completed, and tells the CPU that the SMI interrupt processing has been completed, and the CPU exits SMM mode. In the above CE reporting process, the design process of the correctable error processing is relatively long, including BIOS-side processing and BMC-side processing, especially BMC processing. The BMC fault information processing process is affected by the processing speed of the BMC chip, the task scheduling situation at the time, and the writing Flash time factor. In extreme cases, the overall processing time will exceed 1 second (1000ms). If SMI occurs frequently, the delay and jitter will be very obvious, and the customer experience will be extremely poor.
[0079] Based on the above content, an embodiment of the present invention provides a method for recording server fault information, which reduces the impact of correctable errors of memory and PCIE devices on system performance through two strategies. One is to reduce the CE reporting frequency, and the other is to reduce the processing time of CE reporting. The CE reporting frequency can be reduced by modifying the BIOS. The memory error frequency of the same slot and the same address can be converged by setting a threshold, which is not the focus of discussion in this application. Reduce the CE reporting time, and reduce the CPU entering SMM mode processing time by optimizing the overall CE reporting SMI processing time to achieve CE reporting processing. The BMC KCS asynchronous processing strategy AHCEE (asynchronous handle CE Error, asynchronous processing CE error) is adopted to effectively reduce the overall SMI processing time and reduce the performance impact of correctable errors of components on the business. In order to achieve the effect of reducing the processing time of correctable errors of memory components and PCIE devices, and reducing the impact of frequent reporting of correctable errors on server performance.
[0080] According to an embodiment of the present invention, a server fault information recording embodiment is provided. It should be noted that the steps shown in the flowchart of the accompanying drawings can be executed in a baseboard management controller, and although the logical order is shown in the flowchart, in some cases, the steps shown or described can be executed in an order different from that shown here.
[0081] In this embodiment, a method for recording server fault information is provided, which can be used in a baseboard management controller. Figure 2 is a flow chart of a method for recording server fault information according to an embodiment of the present invention. Figure 2 As shown, the process includes the following steps:
[0082] Step S201 : upon receiving a preset number of fault information recording requests sent by a basic input / output system, creating a target task corresponding to the fault information recording request, wherein the target task is used to record the fault information corresponding to the fault information recording request.
[0083] Specifically, this embodiment adopts the BMC KCS asynchronous processing strategy AHCEE (asynchronous handle CEError) to effectively reduce the overall processing time of SMI and reduce the impact of correctable errors of components on business performance.
[0084] The basic input and output system (BIOS) monitors the memory and PCIE devices through the memory controller to see if there are CE errors. By modifying the BIOS to reduce the CE reporting frequency, the memory error frequency of the same slot and the same address can be converged by setting a threshold. Through the above modification, after the BIOS detects a CE error, it will generate a preset number of fault information record requests after the number of CE errors reaches the threshold. The fault information record request contains CE fault information. The preset number is, for example, 5, 6, 7... The specific number is set according to actual needs.
[0085] BIOS sends a preset number of fault information record requests through KCS to notify BMC to receive. BMC receives a preset number of fault information record requests sent by BIOS through the KCS interface. KCS module is a submodule under BMC LPC controller, used for BIOS and BMC communication interface.
[0086] After the BMC receives a preset number of fault information record requests, it starts the AHCEE processing flow to verify whether the fault information record request contains necessary data and parameters, such as data indicating the operation to be performed. If it contains these data and parameters, the AHCEE processing flow creates an asynchronous task inside the BMC and uses the asynchronous task as the target task corresponding to the fault information record request, where the target task is used to record the fault information corresponding to the fault information record request. The target task is added to the task queue and waits to be processed.
[0087] Step S202, sending the processing result corresponding to the fault information recording request to the basic input and output system, and executing the target task to complete recording the fault information, wherein the processing result is used to instruct the basic input and output system to control the central processor to exit the preset mode and continue to process business data.
[0088] Specifically, after the BMC creates the target task, the BMC returns the SMI processing result to the BIOS, that is, sends the processing result corresponding to the fault information recording request to the BIOS. After receiving the processing result, the BIOS will control the CPU to exit the preset mode, such as the SMM mode. After exiting the preset mode, the CPU continues to process business data. While returning the processing result to the BIOS, the BMC calls the asynchronous fault log information processing flow to execute the target task and realize the recording of fault log information.
[0089] It should be noted that in the fault reporting process in this embodiment, the BIOS-side code processing time is about 10ms on average, while the BMC-side processing time is affected by the processing speed of the BMC chip, the task scheduling situation at the time, and the Flash writing time factor. In extreme cases, the overall processing time will exceed 1000ms. This solution adopts an asynchronous processing strategy to isolate the longer BMC processing time. In actual tests, the overall correctable error reporting average time is reduced to about 10ms, that is, after optimization, the CPU enters SMM processing time is reduced to about 10ms, and the CE fault processing performance is improved by about 100 times. Customers deliberately trigger CE storms in actual environments, and various performance tests will not cause delays and jitters to customer services and applications.
[0090] In addition, the present invention has been fully launched in the CDC (Cloud Dedicated Cluster) computer room cloud server and has played a good role, greatly reducing the impact of component correctable errors on server performance.
[0091] In the server fault information recording method provided in this embodiment, after receiving the fault information recording request, the baseboard management controller first creates a target task, and then returns the processing result to the basic input and output system, so that the central processing unit exits the preset mode as soon as possible. At the same time, the target task is executed asynchronously to complete the recording of fault information. Through overall optimization, the length of time the central processing unit is in the preset mode during the fault information recording process is reduced, and the performance impact of the correctable errors of the components on the business is reduced. The problem that recording CE fault information will cause server performance to decline, resulting in increased network jitter and response delay of the server is solved.
[0092] In some optional implementations, creating a target task corresponding to the fault information record request includes:
[0093] Perform data integrity check on fault information record requests;
[0094] If the fault information record request verification passes, the target task is created.
[0095] Specifically, the fault information recording request is subjected to data integrity verification. For example, when the BIOS generates the fault information recording request, the reference verification value corresponding to the fault information recording request is calculated and saved by using the data integrity verification algorithm. When the BMC verifies the fault information recording request, the current verification value of the fault information recording request is calculated by using the same data integrity verification algorithm, and the reference verification value is compared with the current verification value to determine whether the fault information recording request is complete. Examples of data integrity verification algorithms include a checksum algorithm, a cyclic redundancy check (CRC) algorithm, and a hash function. Among them, the checksum is a simple numerical value generated by performing a certain operation (such as summation, XOR, etc.) on the data. The receiver can recalculate the checksum by using the same algorithm and compare it with the checksum provided by the sender to verify whether the data is complete. CRC is a more powerful verification method that generates a check code based on polynomial division. The hash function maps data of any length to a hash value (also called a digest) of a fixed length. The receiver can recalculate the hash value by using the same hash function and compare it with the hash value provided by the sender to verify whether the data is complete.
[0096] In this implementation, by performing a data integrity check on the fault information recording request, it is possible to verify whether the format of the fault information recording request is correct, whether the parameters are valid, and whether the necessary authority information is included.
[0097] In some optional implementations, performing a data integrity check on the fault information recording request includes:
[0098] Obtaining structure data corresponding to the fault information record request, and determining whether the format of the structure data is the same as a preset format, wherein the preset format is used to verify the authority information of the fault information record request;
[0099] If they are the same, get the parameter type and number of parameters of the structure data;
[0100] If the parameter type is the same as the preset type, and the parameter quantity is the same as the preset value, the fault information record request verification passes.
[0101] Specifically, the BIOS sends the structure data corresponding to the fault information record request to the BMC through the KCS channel. The BMC needs to verify the data integrity and parameter number integrity of the structure data.
[0102] The preset format is used to verify the permission information of the fault information record request. The preset format includes: the previously defined structure content and format. Read the structure data to determine whether the format of the structure data is the same as the preset format. If they are the same, it is determined that the format of the fault information record request is correct, the parameters are valid, and the necessary permission information is included. Otherwise, the fault information record request does not meet the requirements of correct format, valid parameters, and necessary permission information.
[0103] Further verify the data integrity and parameter number integrity of the fault information record request. Obtain the parameter type and parameter number of the structure data. If the parameter type is the same as the preset type, and the parameter number is the same as the preset value, it is determined that the fault information record request has data integrity and parameter number integrity, and the fault information record request passes the verification.
[0104] In this embodiment, a data integrity check is performed on the fault information record request using a preset format, preset type, and preset value to ensure that the fault information record request format is correct, the parameters are valid, it contains necessary authority information, and has data integrity and parameter number integrity.
[0105] In some optional implementations, creating a target task corresponding to the fault information record request includes:
[0106] According to the fault information recording request, an asynchronous task is created inside the baseboard management controller, and the asynchronous task is used as a target task;
[0107] Add the target task to the task queue and obtain the priority of the target task in the task queue;
[0108] According to the priority, the execution order of the target tasks in the task queue is determined.
[0109] Specifically, according to the fault information recording request, an asynchronous task is created inside the BMC, and the asynchronous task is used as the target task. The target task is added to the task queue to wait for being processed.
[0110] Obtain the priority of the target task in the task queue. For example, the priority of the target task in the task queue is determined based on factors such as resource availability. The resource availability is obtained by calculating the current CPU core processing task load during the integrity check of the fault information record request.
[0111] According to the priority of the target task, the execution order of the target tasks in the task queue is determined.
[0112] In this embodiment, based on the fault information recording request, an asynchronous task is created inside the baseboard management controller, and an asynchronous processing strategy is adopted to isolate the process part of the BMC recording error information, shorten the time the central processing unit is in the preset mode, and reduce the performance impact of the correctable errors of the components on the business.
[0113] In some optional implementations, performing the target task includes:
[0114] According to the task scheduler and execution order, determine the tasks to be executed in the task queue;
[0115] Call the information processing object to process the task to be executed, obtain the processed information, and call the log recording object to generate a fault information log based on the processed information;
[0116] Save the fault information log to the flash memory of the baseboard management controller.
[0117] Specifically, AHCEE performs asynchronous operations, calls corresponding business logic codes or external services, and performs actual asynchronous operations. The BMC task scheduler takes out the target tasks from the task queue in sequence according to the execution order of the target tasks in the task queue, and uses the target tasks as tasks to be executed.
[0118] An example of an information processing object is the AHCEE information processing module; an example of a log recording object is the AHCEE log recording processing module.
[0119] Call the information processing object to process the task to be executed, obtain the processed information, and call the log recording object to generate a fault information log based on the processed information;
[0120] Save the fault information log to the flash memory of the baseboard management controller.
[0121] In this embodiment, an asynchronous processing strategy is adopted to isolate the process part of the BMC recording error information, shorten the time the central processor is in the preset mode, and reduce the performance impact of the correctable errors of the components on the business.
[0122] In some optional implementations, after executing the target task, the method further includes:
[0123] Get the execution result of the target task;
[0124] Obtain log fragments according to the execution results, and write the log fragments into the fault information log;
[0125] When it is determined according to the execution result that the execution of the target task has failed, an error response is generated and returned to the target object.
[0126] Specifically, the result of the asynchronous operation is collected, that is, the execution result of the target task.
[0127] Perform necessary processing or conversion on the execution results to obtain log fragments. For example, in order to record the execution results in the BMC flash, it is necessary to perform some log format conversion processing on the execution results to obtain log fragments. The log fragments are convenient for reporting to the SEL or black box. Write the log fragments to the fault information log saved in the BMC flash.
[0128] When the execution of the target task fails according to the execution result, the error information is recorded and the corresponding error response is prepared, and the error response is returned to the target object, such as the AHCEE caller. In addition, the processing result is returned to the AHCEE caller through callback, parsing or event triggering, because the call involves PCIE and memory CE, etc., the main program needs to check the call result and parameters.
[0129] In this embodiment, the execution results are converted into log fragments and written into the fault information log. The execution status of each target task can be determined through the fault information log, which is convenient for subsequent troubleshooting and performance optimization.
[0130] In some optional embodiments, the method further comprises:
[0131] Obtain process information for executing target tasks;
[0132] Generate a process log for executing the target task based on the process information and fault information record request.
[0133] Specifically, the process information of executing the target task is obtained, and the process information includes: processing steps, results, errors and other information of the entire AHCEE processing process.
[0134] According to the process information and fault information recording request, a process log for executing the target task is generated. The process log is a log that records the entire AHCEE processing process, including: fault information recording request, processing steps, results and errors, etc.
[0135] In this embodiment, a process log for executing the target task is generated according to the process information of executing the target task and the fault information recording request, and the process log is used to record the entire AHCEE processing process to facilitate subsequent troubleshooting and performance optimization.
[0136] In some optional implementations, after executing the target task, the method further includes:
[0137] Determine the occupied resources corresponding to the target task in the baseboard management controller;
[0138] Release the occupied resources.
[0139] Specifically, determine the occupied resources corresponding to the target task in the baseboard management controller, for example: any occupied resources, such as database connections, file handles, etc. Some models need to record more information, and the BMC will have an external interface to connect to the database. Release the above occupied resources.
[0140] In this implementation, occupied resources are released, resource cleanup and recycling are achieved, resource utilization is improved, and correct release of resources is ensured to avoid resource leakage and performance issues.
[0141] In some optional embodiments, the method further comprises:
[0142] Determine whether a preset error occurs in the baseboard management controller during the execution of the target task;
[0143] If a preset error occurs, an error message is generated and output.
[0144] Specifically, the preset errors include: failure to write to Flash, timeout, interface call identification, etc. It is determined whether a preset error occurs in the BMC during the execution of the target task, i.e., the AHCEE process. If detected, the corresponding alarm mechanism is triggered, and error information is generated and output to notify relevant personnel to handle it. Output error information, for example: record the error information in the BMC log or print it through the serial port.
[0145] In this embodiment, it is determined whether a preset error occurs in the baseboard management controller. If a preset error occurs, an error message is generated and output to notify relevant personnel to handle it, thereby avoiding failure to record error information due to a fault in the baseboard management controller.
[0146] According to an embodiment of the present invention, an embodiment of a server fault information recording method is provided. It should be noted that the steps shown in the flowchart of the accompanying drawings can be executed in a basic input and output system, and although a logical order is shown in the flowchart, in some cases, the steps shown or described can be executed in an order different from that shown here.
[0147] In this embodiment, a method for recording server fault information is provided, which can be used in a basic input and output system. Figure 3 is a flow chart of a method for recording server fault information according to an embodiment of the present invention. Figure 3 As shown, the process includes the following steps:
[0148] Step S301, acquiring fault information of a server, and generating a preset number of fault information record requests according to the fault information.
[0149] Specifically, the basic input and output system (BIOS) monitors the memory and PCIE devices through the memory controller to see if there are CE errors. By modifying the BIOS to reduce the CE reporting frequency, the memory error frequency of the same slot and the same address can be converged by setting a threshold. Through the above modification, after the BIOS detects a CE error, it will generate a preset number of fault information record requests after the number of CE errors reaches the threshold. The fault information record request contains CE fault information. The preset number is, for example, 5, 6, 7... The specific number is set according to actual needs.
[0150] Step S302, sending a preset number of fault information record requests to the baseboard management controller, wherein the fault information record request is used to instruct the baseboard management controller to create a target task, the baseboard management controller is used to send the processing result corresponding to the fault information record request to the basic input and output system, and execute the target task, and the target task is used to record the fault information corresponding to the fault information record request.
[0151] Specifically, a preset number of fault information record requests are sent to the baseboard management controller. After the BMC receives the preset number of fault information record requests, the AHCEE processing flow is started to verify whether the fault information record request contains necessary data and parameters, such as data indicating the operation to be performed. If these data and parameters are included, the AHCEE processing flow creates an asynchronous task inside the BMC and uses the asynchronous task as the target task corresponding to the fault information record request, wherein the target task is used to record the fault information corresponding to the fault information record request.
[0152] After the BMC creates the target task, the BMC returns the SMI processing result to the BIOS, that is, sends the processing result corresponding to the fault information recording request to the BIOS. While returning the processing result to the BIOS, the BMC calls the asynchronous fault log information processing flow to execute the target task and realize the recording of fault log information.
[0153] Step S303, upon receiving the processing result, controlling the central processing unit to exit the preset mode and continue processing the business data.
[0154] Specifically, after receiving the processing result, the BIOS controls the CPU to exit a preset mode, such as the SMM mode. After exiting the preset mode, the CPU continues to process service data.
[0155] The server fault information recording method provided in this embodiment is that the basic input-output system generates a preset number of fault information recording requests according to the fault information, sends the preset number of fault information recording requests to the baseboard management controller, and instructs the baseboard management controller to record the fault information. After receiving the fault information recording request, the baseboard management controller first creates a target task, and then returns the processing result to the basic input-output system, so that the central processing unit exits the preset mode as soon as possible. At the same time, the target task is executed asynchronously to realize the asynchronous processing of the BMC corresponding to the correctable error reporting record log, shorten the time the central processing unit is in the preset mode, and reduce the performance impact of the correctable errors of the components on the business. It solves the problem that recording CE fault information will cause the server performance to decline, resulting in increased network jitter and response delay of the server.
[0156] In some optional implementations, acquiring fault information of a server and generating a preset number of fault information record requests according to the fault information includes:
[0157] Monitor the server to determine if there are correctable errors in the server;
[0158] If a correctable error exists, obtain fault information of the correctable error;
[0159] Determine whether the amount of fault information is greater than or equal to a preset threshold;
[0160] If yes, a preset number of fault information record requests are generated according to the fault information.
[0161] Specifically, the server is monitored to determine whether there are correctable errors in the server, for example, the BIOS sets the memory controller to monitor the CE error of each RANK of the memory, and monitors the CE error of each Root Port of the PCIE device.
[0162] If there is a correctable error, obtain the fault information of the correctable error. Determine whether the number of fault information is greater than or equal to a preset threshold, which is set in advance, for example: 5, 6, 7... The specific number is set according to actual needs. If yes, generate a preset number of fault information record requests according to the fault information.
[0163] In this embodiment, the BIOS is modified to reduce the CE reporting frequency of the memory in the same slot and the same address by setting a threshold, thereby preventing the central processor from frequently entering the preset mode and reducing the impact of frequent reporting of correctable errors on server performance.
[0164] In some optional implementations, a method for uploading fault information of a CE and a UCE respectively may include steps A1 to A4.
[0165] In step A1, BIOS determines whether UCE occurs in the memory and PCIE device by reading a preset register; if not, execute step A2; if so, execute step A3.
[0166] Specifically, BIOS needs to read the preset register to determine whether UCE occurs. Patrol Scrub refers to patrol scrub, and UCE refers to an abnormality in the memory patrol scrub function. Once UCE occurs, it means that the memory cannot be automatically cleared after the process is closed, causing the memory to continue to be occupied as the number of processes increases, seriously affecting server performance. This step requires a register to be preset by default to indicate the status of UCE. For example, you can use the bit31:16 of the MSR_MC13_STATUS register. If the BIOS detects that the value of this bit is 0x0010, it means that the memory has a CE downgraded to UCE, otherwise it is a normal CE.
[0167] In addition, UCE usually occurs every few days, so it can be set to read the preset register every hour. It can also be set to trigger the read, that is, read the preset register every time a CE error occurs in the memory. Since it is impossible to determine whether it is UCE or ordinary CE when a CE error occurs, the BIOS can be triggered to read the preset register.
[0168] Step A2, determine whether the common CE count meets the missing error threshold; if so, execute step A3.
[0169] Specifically, if the BIOS does not find that UCE has occurred by reading the preset register, it further determines whether the ordinary CE count meets the error threshold. Usually, each time an ordinary CE occurs, the error threshold is increased by one. Since ordinary CE is a correctable memory error, the impact caused by it is small, so it can be repaired uniformly after a certain amount of ordinary CE has accumulated. Of course, it is understandable that even ordinary CE cannot be accumulated too much to avoid affecting the normal operation of the server. Therefore, when the BIOS does not detect UCE, it is also necessary to determine whether the ordinary CE count has reached the error threshold.
[0170] Step A3: triggering an SMI interrupt.
[0171] Specifically, if UCE occurs, or the ordinary CE count meets the error threshold, an SMI interrupt should be triggered to cause the CPU to enter SMM mode. After the SMI interrupt is triggered, ordinary CE repairs or UCE downgrades can be performed. Triggering an SMI interrupt when UCE occurs prevents the BIOS from counting as ordinary CE when UCE occurs, allowing the BIOS to detect UCE in a timely manner, allowing server operation and maintenance personnel to obtain memory fault information in a timely manner, which is conducive to monitoring the server memory status.
[0172] Step A4, after the SMI interrupt is triggered, an error information instruction is sent to the BMC; the error information instruction includes the reason for the SMI interrupt.
[0173] Specifically, sending an error information instruction to the BMC indicates that the UCE or common CE count has met the error threshold and relevant repair work is required. The BMC can record the error information instruction and generate a corresponding system log to facilitate technicians in this field to control the memory status and maintain the memory of the server.
[0174] In addition, the BMC determines the cause of the SMI interrupt based on the error information instruction, that is, whether it is UCE or ordinary CE. The corresponding processing methods for UCE and ordinary CE are different. If the error information instruction is an error information instruction corresponding to UCE, BIOS downgrades UCE to ordinary CE; if the error information instruction is an error information instruction corresponding to ordinary CE, BIOS terminates the process corresponding to ordinary CE. Severe UCE also requires shutdown and restart, or relies on on-site repair by technical personnel in this field.
[0175] In this embodiment, the BMC can record the fault information of CE and UCE, so that the server operation and maintenance personnel can obtain memory fault information in time, which is conducive to monitoring the server memory status. In addition, in this embodiment, the BMC can also repair CE and UCE respectively so that the server system can be used normally.
[0176] In some optional implementations, a server fault information recording method is provided, which can solve the same technical problem as steps S201 to S202, or solve the same technical problem as steps S301 to S303. Figure 4 is a flow chart of a method for recording server fault information according to an embodiment of the present invention. Figure 4 As shown, the process includes the following steps:
[0177] The server is powered on, BIOS is started, and BMC is started. The BIOS operation process includes: BIOS sets the memory controller to monitor the CE error of each RANK of the memory and the CE error of each Root Port of PCIE; judges whether it exceeds the threshold. If not, re-executes the BIOS setting memory controller to monitor the CE error of each RANK of the memory and the CE error of each Root Port of PCIE. If yes, the CE overflow value is set, and the BIOS enters the SMI fault error processing function. The BIOS sends the fault information to the BMC through the IPMI command, and the CE overflow value is cleared. After receiving the SMI processing result returned by the BMC, the SMI fault reporting processing function ends.
[0178] The BMC operation process includes: BMC monitors BIOS to send IPMI information, determines whether there is new IPMI processing information, if not, re-executes BMC monitoring BIOS to send IPMI information, if yes, starts BMC kCs processing program, BMC AHCEE processing starts, BMC returns SMI processing results, AHCEE task creation, AHCEE enters task scheduling, AHCEE information processing module, AHCEE log records to Flash processing module, AHCEE result feedback, AHCEE log records, AHCEE resource recovery.
[0179] Specifically, the reference code of the BMC operation process in the above process is as follows:
[0180] / / Assume there is an AHCEE function that updates the BMC model asynchronously
[0181] function AHCEE(newModelData) {
[0182] return new Promise((resolve, reject) =>{
[0183] / / Any asynchronous operation can be performed here, such as calling the AHCEE fault handling model
[0184] / / For the sake of example, we simply simulate an asynchronous operation
[0185] setTimeout(() => {
[0186] if (newModelData.isValid) {
[0187] console.log('BMC model updated successfully!');
[0188] resolve('Model has been updated');
[0189] } else {
[0190] console.error('BMC model data is invalid!');
[0191] reject(new Error('Invalid BMC model data'));
[0192] }
[0193] }, 1000); / / Simulating asynchronous operation takes 1 second
[0194] };
[0195] }
[0196] / / Asynchronously execute AHCEE function
[0197] async function executeBmcAHCEEUpdate() {
[0198] try {
[0199] const newModelData = {
[0200] isValid: true, / / Assume this is valid BMC AHCEE model data
[0201] };
[0202] const result = await AHCEE(newModelData);
[0203] console.log(result); / / Output:
[0204] / / You can continue to perform other operations here, such as notifying BIOS, recording logs, etc.
[0205] } catch (error) {
[0206] console.error('Error updating BMC model:', error);
[0207] / / Errors can be handled here, such as sending AHCEE error reports, retrying, etc.
[0208] }
[0209] }
[0210] / / Call asynchronous function to perform BMC model update
[0211] executeBmcAHCEEUpdate();
[0212] In this embodiment, by modifying the BIOS startup parameters, the same position and the same address can be configured to report after reaching the threshold. By modifying the BIOS parameters, the interval time for each BIOS to send KCS content is reduced. By modifying the BMC fault log information processing logic, the BMC corresponding correctable error reporting record log is asynchronously processed. The processing time of correctable errors of memory components and PCIE devices is reduced, and the impact of frequent reporting of correctable errors on server performance is reduced.
[0213] In this embodiment, a server fault information recording device is also provided, which is used to implement the above-mentioned embodiments and preferred implementation modes, and the descriptions that have been made will not be repeated. As used below, the term "module" can implement a combination of software and / or hardware of a predetermined function. Although the devices described in the following embodiments are preferably implemented in software, the implementation of hardware, or a combination of software and hardware, is also possible and conceivable.
[0214] This embodiment provides a server fault information recording device, which is deployed in a baseboard management controller, such as Figure 5 As shown, including:
[0215] The task creation module 501 is used to create a target task corresponding to the fault information recording request when receiving a preset number of fault information recording requests sent by the basic input and output system, wherein the target task is used to record the fault information corresponding to the fault information recording request;
[0216] The task execution module 502 is used to send the processing result corresponding to the fault information recording request to the basic input and output system, and execute the target task to complete the recording of the fault information, wherein the processing result is used to instruct the basic input and output system to control the central processor to exit the preset mode and continue to process business data.
[0217] In some optional implementations, the task creation module 501 includes:
[0218] A verification unit, used for performing data integrity verification on a fault information recording request;
[0219] The first creating unit is used to create a target task if the fault information record request passes verification.
[0220] In some optional implementations, the verification unit includes:
[0221] A first acquisition submodule is used to acquire structure data corresponding to the fault information record request, and determine whether the format of the structure data is the same as a preset format, wherein the preset format is used to verify the authority information of the fault information record request;
[0222] The second acquisition submodule is used to acquire the parameter type and parameter quantity of the structure data if they are the same;
[0223] The judgment submodule is used to verify that the fault information record request has passed if the parameter type is the same as the preset type and the parameter quantity is the same as the preset value.
[0224] In some optional implementations, the task creation module 501 includes:
[0225] A second creation unit is used to create an asynchronous task inside the baseboard management controller according to the fault information recording request, and use the asynchronous task as a target task;
[0226] A first acquisition unit, used for adding a target task to a task queue and acquiring a priority of the target task in the task queue;
[0227] The first determining unit is used to determine the execution order of the target tasks in the task queue according to the priority.
[0228] In some optional implementations, the task execution module 502 includes:
[0229] A second determining unit, configured to determine the tasks to be executed in the task queue according to the task scheduler and the execution order;
[0230] A calling unit, used to call the information processing object to process the task to be executed, obtain the processed information, and call the log recording object to generate a fault information log according to the processed information;
[0231] The storage unit is used to store the fault information log in the flash memory of the baseboard management controller.
[0232] In some optional embodiments, the device further comprises:
[0233] The first acquisition module is used to obtain the execution result of the target task;
[0234] A writing module is used to obtain log fragments according to the execution results and write the log fragments into the fault information log;
[0235] The first generating module is used to generate an error response when it is determined according to the execution result that the execution of the target task fails, and return the error response to the target object.
[0236] In some optional embodiments, the device further comprises:
[0237] The second acquisition module is used to obtain the process information of executing the target task;
[0238] The second generating module is used to generate a process log for executing the target task according to the process information and the fault information recording request.
[0239] In some optional embodiments, the device further comprises:
[0240] A determination module, used to determine the occupied resources corresponding to the target task in the baseboard management controller;
[0241] The release module is used to release occupied resources.
[0242] In some optional embodiments, the device further comprises:
[0243] A judgment module, used to judge whether a preset error occurs in the baseboard management controller during the execution of the target task;
[0244] The third generating module is used to generate and output error information if a preset error occurs.
[0245] The further functional description of each of the above modules and units is the same as that of the above corresponding embodiments and will not be repeated here.
[0246] This embodiment provides a server fault information recording device, which is deployed in a basic input and output system, such as Figure 6 As shown, including:
[0247] The information acquisition module 601 is used to acquire the fault information of the server and generate a preset number of fault information record requests according to the fault information;
[0248] The information sending module 602 is used to send a preset number of fault information recording requests to the baseboard management controller, wherein the fault information recording request is used to instruct the baseboard management controller to create a target task, and the baseboard management controller is used to send the processing result corresponding to the fault information recording request to the basic input and output system, and execute the target task, and the target task is used to record the fault information corresponding to the fault information recording request;
[0249] The control module 603 is used to control the central processing unit to exit the preset mode and continue processing business data when receiving the processing result.
[0250] In some optional implementations, the information acquisition module 601 includes:
[0251] A first judgment unit, used for monitoring the server and judging whether there is a correctable error in the server;
[0252] A second acquisition unit, configured to acquire fault information of the correctable error if a correctable error exists;
[0253] A second judgment unit, used to judge whether the amount of fault information is greater than or equal to a preset threshold;
[0254] A generating unit is configured to generate a preset number of fault information record requests according to the fault information if yes.
[0255] The further functional description of each of the above modules and units is the same as that of the above corresponding embodiments and will not be repeated here.
[0256] The server fault information recording device in this embodiment is presented in the form of a functional unit, where the unit refers to an ASIC (Application Specific Integrated Circuit) circuit, a processor and memory that executes one or more software or fixed programs, and / or other devices that can provide the above functions.
[0257] The embodiment of the present invention also provides a computer device having the above Figure 5 or Figure 6 The server failure information recording device shown.
[0258] See also Figure 7 , Figure 7 is a schematic diagram of the structure of a computer device provided by an optional embodiment of the present invention, such as Figure 7 As shown, the computer device includes: one or more processors 10, a memory 20, and interfaces for connecting various components, including high-speed interfaces and low-speed interfaces. Various components are connected to each other using different buses for communication, and can be installed on a common mainboard or installed in other ways as needed. The processor can process the instructions executed in the computer device, including instructions stored in or on the memory to display the graphical information of the GUI on an external input / output device (such as, a display device coupled to the interface). In some optional embodiments, if necessary, multiple processors and / or multiple buses can be used together with multiple memories and multiple memories. Similarly, multiple computer devices can be connected, and each device provides some necessary operations (for example, as a server array, a group of blade servers, or a multi-processor system). Figure 7 A processor 10 is taken as an example.
[0259] The processor 10 may be a central processing unit, a network processor or a combination thereof. The processor 10 may further include an integrated circuit, a programmable logic device or a combination thereof. The programmable logic device may be a complex programmable logic device, a field programmable gate array, a general purpose array logic or any combination thereof.
[0260] The memory 20 stores instructions executable by at least one processor 10, so that at least one processor 10 executes the method shown in the above embodiment.
[0261] The memory 20 may include a program storage area and a data storage area, wherein the program storage area may store an operating system, an application required for at least one function; the data storage area may store data created according to the use of the computer device, etc. In addition, the memory 20 may include a high-speed random access memory, and may also include a non-transient memory, such as at least one disk storage device, a flash memory device, or other non-transient solid-state storage device. In some optional embodiments, the memory 20 may optionally include a memory remotely arranged relative to the processor 10, and these remote memories may be connected to the computer device via a network. Examples of the above-mentioned network include, but are not limited to, the Internet, an intranet, a local area network, a mobile communication network, and combinations thereof.
[0262] The memory 20 may include a volatile memory, such as a random access memory; the memory may also include a non-volatile memory, such as a flash memory, a hard disk or a solid state drive; the memory 20 may also include a combination of the above types of memory.
[0263] The computer device further comprises a communication interface 30 for the computer device to communicate with other devices or a communication network.
[0264] The embodiment of the present invention also provides a computer-readable storage medium. The method according to the embodiment of the present invention can be implemented in hardware, firmware, or can be implemented as a computer code that can be recorded in a storage medium, or can be implemented as a computer code that is originally stored in a remote storage medium or a non-temporary machine-readable storage medium and will be stored in a local storage medium through a network download, so that the method described herein can be stored in such software processing on a storage medium using a general-purpose computer, a dedicated processor, or programmable or dedicated hardware. Among them, the storage medium can be a magnetic disk, an optical disk, a read-only storage memory, a random access memory, a flash memory, a hard disk or a solid-state hard disk, etc.; further, the storage medium can also include a combination of the above types of memories. It can be understood that a computer, a processor, a microprocessor controller, or programmable hardware includes a storage component that can store or receive software or computer code. When the software or computer code is accessed and executed by a computer, a processor, or hardware, the method shown in the above embodiment is implemented.
[0265] A part of the present invention may be applied as a computer program product, such as a computer program instruction, which, when executed by a computer, can call or provide the method and / or technical solution according to the present invention through the operation of the computer. Those skilled in the art should understand that the existence of the computer program instruction in a computer-readable medium includes, but is not limited to, a source file, an executable file, an installation package file, etc., and accordingly, the way in which the computer program instruction is executed by the computer includes, but is not limited to: the computer directly executes the instruction, or the computer compiles the instruction and then executes the corresponding compiled program, or the computer reads and executes the instruction, or the computer reads and installs the instruction and then executes the corresponding installed program. Here, the computer-readable medium may be any available computer-readable storage medium or communication medium accessible to the computer.
[0266] Although the embodiments of the present invention have been described in conjunction with the accompanying drawings, those skilled in the art may make various modifications and variations without departing from the spirit and scope of the present invention, and such modifications and variations are all within the scope defined in this application.
Claims
1. A method for recording server fault information, characterized in that: The method is applied to a baseboard management controller, and the method comprises: In the case of receiving a preset number of fault information recording requests sent by the basic input and output system, creating a target task corresponding to the fault information recording request, wherein the target task is used to record the fault information corresponding to the fault information recording request; The creating of the target task corresponding to the fault information recording request includes: verifying whether the fault information recording request contains necessary data and parameters; if the fault information recording request contains necessary data and parameters, creating an asynchronous task inside the baseboard management controller, and using the asynchronous task as the target task corresponding to the fault information recording request; Send the processing result corresponding to the fault information recording request to the basic input and output system, and execute the target task to complete the recording of the fault information, wherein the processing result is used to instruct the basic input and output system to control the central processing unit to exit the preset mode and continue to process business data, and the preset mode is the system management mode.
2. The method according to claim 1, characterized in that: The creating a target task corresponding to the fault information record request includes: Performing data integrity check on the fault information recording request; If the fault information record request passes verification, the target task is created.
3. The method according to claim 2, characterized in that The performing data integrity check on the fault information recording request includes: Acquire structure data corresponding to the fault information record request, and determine whether a format of the structure data is the same as a preset format, wherein the preset format is used to verify the authority information of the fault information record request; If they are the same, then obtain the parameter type and parameter quantity of the structure data; If the parameter type is the same as the preset type, and the parameter quantity is the same as the preset value, then the fault information record request is verified to be successful.
4. The method according to claim 1, characterized in that: The creating a target task corresponding to the fault information record request includes: Creating an asynchronous task in the baseboard management controller according to the fault information recording request, and using the asynchronous task as the target task; Adding the target task to a task queue, and obtaining the priority of the target task in the task queue; According to the priority, the execution order of the target tasks in the task queue is determined.
5. The method according to claim 4, characterized in that The executing of the target task comprises: Determining tasks to be executed in the task queue according to the task scheduler and the execution order; Calling the information processing object to process the task to be executed, obtaining processed information, and calling the log recording object to generate a fault information log according to the processed information; The fault information log is saved in the flash memory of the baseboard management controller.
6. The method according to claim 5, characterized in that After executing the target task, the method further includes: Obtaining the execution result of executing the target task; Obtaining a log fragment according to the execution result, and writing the log fragment into the fault information log; In the case where it is determined according to the execution result that the execution of the target task fails, an error response is generated and the error response is returned to the target object.
7. The method according to claim 1, characterized in that The method further comprises: Acquire process information of executing the target task; A process log for executing the target task is generated according to the process information and the fault information recording request.
8. The method according to claim 1, characterized in that After executing the target task, the method further includes: Determining occupied resources corresponding to the target task in the baseboard management controller; The occupied resources are released.
9. The method according to claim 1, characterized in that: The method further comprises: Determining whether a preset error occurs in the baseboard management controller during the execution of the target task; If the preset error occurs, an error message is generated and output.
10. A method for recording server fault information, characterized in that: The method is applied to a basic input and output system, and the method comprises: Acquire fault information of the server, and generate a preset number of fault information record requests according to the fault information; Sending a preset number of the fault information recording requests to a baseboard management controller, wherein the fault information recording request is used to instruct the baseboard management controller to create a target task, the baseboard management controller is used to send a processing result corresponding to the fault information recording request to the basic input and output system, and execute the target task, the target task is used to record the fault information corresponding to the fault information recording request; the baseboard management controller creates the target task, including: verifying whether the fault information recording request contains necessary data and parameters; if the fault information recording request contains necessary data and parameters, creating an asynchronous task inside the baseboard management controller, and using the asynchronous task as the target task corresponding to the fault information recording request; When the processing result is received, the central processing unit is controlled to exit the preset mode and continue to process the business data, wherein the preset mode is the system management mode.
11. The method according to claim 10, characterized in that The acquiring of the fault information of the server and generating a preset number of fault information record requests according to the fault information includes: monitoring the server to determine whether there are correctable errors in the server; If the correctable error exists, obtaining the fault information of the correctable error; Determining whether the amount of the fault information is greater than or equal to a preset threshold; If yes, a preset number of fault information record requests are generated according to the fault information.
12. A server fault information recording device, characterized in that: The device is deployed in a baseboard management controller, and the device includes: A task creation module, configured to, upon receiving a preset number of fault information recording requests sent by a basic input / output system, create a target task corresponding to the fault information recording request, wherein the target task is used to record the fault information corresponding to the fault information recording request; the creating the target task corresponding to the fault information recording request comprises: verifying whether the fault information recording request contains necessary data and parameters; if the fault information recording request contains necessary data and parameters, creating an asynchronous task inside the baseboard management controller, and using the asynchronous task as the target task corresponding to the fault information recording request; A task execution module is used to send the processing result corresponding to the fault information recording request to the basic input and output system, and execute the target task to complete the recording of the fault information, wherein the processing result is used to instruct the basic input and output system to control the central processing unit to exit the preset mode and continue to process business data, and the preset mode is the system management mode.
13. A server fault information recording device, characterized in that: The device is deployed in a basic input and output system, and the device includes: An information acquisition module, used to acquire fault information of the server and generate a preset number of fault information record requests according to the fault information; An information sending module is used to send a preset number of fault information record requests to a baseboard management controller, wherein the fault information record request is used to instruct the baseboard management controller to create a target task, the baseboard management controller is used to send a processing result corresponding to the fault information record request to the basic input and output system, and execute the target task, the target task is used to record the fault information corresponding to the fault information record request; the baseboard management controller creates the target task, including: verifying whether the fault information record request contains necessary data and parameters; if the fault information record request contains necessary data and parameters, creating an asynchronous task inside the baseboard management controller, and using the asynchronous task as the target task corresponding to the fault information record request; The control module is used to control the central processing unit to exit the preset mode and continue processing business data when receiving the processing result, wherein the preset mode is the system management mode.
14. A computer device, characterized in that: include: A memory and a processor, wherein the memory and the processor are communicatively connected to each other, the memory stores computer instructions, and the processor executes the server fault information recording method according to any one of claims 1 to 11 by executing the computer instructions.
15. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores computer instructions, and the computer instructions are used to enable a computer to execute the server fault information recording method according to any one of claims 1 to 11.
Citation Information
Patent Citations
Memory CE fault processing method, system and related device
CN111008091A
Method and device for reporting error information and medium
CN113064745A