Error information processing method, device, medium and program product

By detecting and processing fatal errors of the server target device, generating log information and resetting the device, the problem of error data retention in the prior art is solved, and the stable operation of the system and data integrity are achieved.

CN118708396BActive Publication Date: 2024-11-15INSPUR SUZHOU INTELLIGENT TECH CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202411206022.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2024-08-30
Publication Date
2024-11-15
Estimated Expiration
2044-08-30

AI Technical Summary

Technical Problem

The prior art tolerate the retention of wrong data in the system when avoiding errors in individual server devices, resulting in incomplete system data and unsafe operation, affecting long-term and stable operation.

Method used

By detecting whether there are fatal errors in the server target device, generating error log information and clearing error information, closing and resetting the target device, avoiding sending error interrupt signals, and ensuring system stability and data integrity.

Benefits of technology

Without affecting the server's entire machine business, fatal errors are handled, and the impact of individual error devices on the entire machine business is reduced, and system data integrity and security are ensured.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118708396B_ABST
    Figure CN118708396B_ABST
Patent Text Reader

Abstract

The present application discloses an error information processing method, device, medium and program product in the field of computer technology. In the present application, when fatal error information is generated, no interrupt is sent to the processor. When it is confirmed that a fatal error exists in a target device, the relevant fatal error information is recorded in a log, and then the relevant fatal error information is cleared from the error source register; after that, when the read and write operations on the target device are stopped, the target device is closed and reset, thereby achieving: processing fatal errors on individual target devices without affecting the service of the entire server.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of computer technology, and in particular to an error information processing method, device, medium and program product. Background Art

[0002] At present, in order to avoid errors in individual devices in the server and affect the operation of the entire server business, the tolerance level can be modified to the maximum value. However, this method will tolerate erroneous data to continue to remain in the system, so the system's data integrity and operational security cannot be guaranteed, which is not conducive to the long-term stable operation of the system.

[0003] Therefore, how to reduce the impact of individual erroneous devices in a server on the service of the entire server is a problem that those skilled in the art need to solve. Summary of the invention

[0004] In view of this, the purpose of this application is to provide an error information processing method, device, medium and program product to reduce the impact of individual error devices in the server on the server's entire business. The specific solution is as follows:

[0005] In a first aspect, the present application provides a method for processing error information, comprising:

[0006] If the preset detection conditions are met, the target device in the server is detected to see if there is a fatal error;

[0007] If a fatal error occurs in the target device, corresponding error log information is generated according to the fatal error information recorded in the error source register, and the fatal error information is cleared from the error source register; wherein when the fatal error information is generated, an error interrupt signal is not sent to the processor in the server;

[0008] If the read and write operations on the target device are stopped, the target device is turned off and reset.

[0009] Optionally, the preset detection conditions are met, including:

[0010] A read or write operation for the target device is detected; and / or a read or write operation for the target device times out; and / or the current time reaches a detection time point for the target device.

[0011] Optionally, detect whether there are fatal errors on the target device in the server, including:

[0012] Querying the parameter status in the error source register for recording the fatal error information;

[0013] If the parameter state value is the first target value, confirming that a fatal error exists in the target device;

[0014] If the parameter status value is the second target value, it is confirmed that there is no fatal error in the target device.

[0015] Optionally, corresponding error log information is generated according to the fatal error information recorded in the error source register, including:

[0016] Reading the fatal error information from the error source register;

[0017] Arrange the fatal error information read according to a preset log format to obtain the error log information;

[0018] Correspondingly, after obtaining the error log information, the following is also included:

[0019] Sending a log notification message to a basic input / output system, so that the basic input / output system constructs a corresponding log structure table according to the error log information, and sends the log structure table to an operating system; the operating system detects a fatal error existing in the target device according to the log structure table, and returns the detected fatal error information to the basic input / output system, so that the basic input / output system checks the log structure table according to the returned information.

[0020] Optionally, it also includes:

[0021] The error log information is stored locally and pushed to a preset management terminal.

[0022] Optionally, clearing the fatal error information from the error source register includes:

[0023] The fatal error information in the error source register is deleted using a clear command.

[0024] Optionally, stopping the read and write operations on the target device includes:

[0025] The read / write operation for the target device is successfully executed; or the read / write operation for the target device is reported as an error; or the read / write operation for the target device is stopped by using an abort command.

[0026] Optionally, shutting down the target device includes:

[0027] The target device is powered off from the driver end.

[0028] Optionally, shutting down the target device includes:

[0029] Stop the device process of the target device.

[0030] Optionally, resetting the target device includes:

[0031] The target device is reset based on the interface file of the target device operated by the driver.

[0032] Optionally, when the fatal error information is generated, not sending an error interrupt signal to the processor in the server includes:

[0033] When the fatal error message is generated, query the fatal error tolerance;

[0034] If the fatal error tolerance is zero, no error interrupt signal is sent to the processor in the server.

[0035] Optionally, before querying fatal error tolerance, include:

[0036] The fatal error tolerance is set to zero.

[0037] Optionally, shutting down the target device includes:

[0038] Query the file directory corresponding to the target device in the file system;

[0039] Determining a control interface of a driver of the target device based on the file directory;

[0040] The driver of the target device is closed through the control interface.

[0041] Optionally, shutting down the target device includes:

[0042] Query the interface file directory of the target device;

[0043] Determine the power interface file of the target device based on the interface file directory;

[0044] The target device is powered off through the power interface file.

[0045] Optionally, resetting the target device includes:

[0046] Query the file directory corresponding to the target device in the file system;

[0047] Searching the file directory for a reset interface file of the target device;

[0048] A reset command is written into the reset interface file to reset the target device.

[0049] Optionally, resetting the target device includes:

[0050] Query the interface file directory of the target device;

[0051] Query the target device's reset interface file in the interface file directory;

[0052] A reset command is written into the reset interface file to reset the target device.

[0053] Optionally, when the fatal error information is generated, not sending an error interrupt signal to the processor in the server includes:

[0054] When the fatal error message is generated, query the fatal error tolerance;

[0055] If the fatal error tolerance is zero, no error interrupt signal is sent to the processor in the server;

[0056] If the fatal error tolerance value is not zero, the fatal error tolerance value is set to zero, and the fatal error tolerance is queried again.

[0057] Optionally, setting the value of the fatal error tolerance to zero includes:

[0058] The fatal error tolerance value is modified to zero in the file system.

[0059] In a second aspect, the present application provides an error information processing device, comprising:

[0060] An error detection module, used to detect whether a target device in the server has a fatal error if a preset detection condition is met;

[0061] An information cleaning module, used for generating corresponding error log information according to the fatal error information recorded in the error source register if the target device has a fatal error, and clearing the fatal error information from the error source register; wherein, when the fatal error information is generated, no error interrupt signal is sent to the processor in the server;

[0062] The device processing module is used to shut down the target device and reset the target device if the read and write operations on the target device stop being executed.

[0063] In a third aspect, the present application provides an electronic device, including:

[0064] Memory for storing computer programs;

[0065] The processor is used to execute the computer program to implement the error information processing method disclosed above.

[0066] In a fourth aspect, the present application provides a non-volatile storage medium for storing a computer program, wherein the computer program implements the aforementioned disclosed error information processing method when executed by a processor.

[0067] In a fifth aspect, the present application provides a computer program product, including a computer program / instruction, which implements the steps of the aforementioned disclosed error information processing method when executed by a processor.

[0068] It can be seen from the above scheme that the present application provides an error information processing method, including: if a preset detection condition is met, detecting whether a target device in a server has a fatal error; if a fatal error exists in the target device, generating corresponding error log information according to the fatal error information recorded in the error source register, and clearing the fatal error information from the error source register; wherein, when the fatal error information is generated, no error interrupt signal is sent to the processor in the server; if the read and write operations on the target device stop being executed, shutting down the target device and resetting the target device.

[0069] It can be seen that the beneficial effects of the present application are: when a fatal error message is generated, no interrupt is sent to the processor; when it is confirmed that a fatal error exists in the target device, the relevant fatal error message is recorded in a log format, and then the relevant fatal error message is cleared from the error source register; thereafter, when the read and write operations on the target device stop executing, the target device is turned off and the target device is reset, thereby achieving: without affecting the service of the entire server, fatal errors on individual target devices are processed, thereby reducing the impact of individual error devices in the server on the service of the entire server.

[0070] Correspondingly, an error information processing device, medium and program product provided by the present application also have the above-mentioned technical effects. BRIEF DESCRIPTION OF THE DRAWINGS

[0071] In order to more clearly illustrate the embodiments of the present application or the technical solutions in the prior art, the drawings required for use in the embodiments or the description of the prior art will be briefly introduced below. Obviously, the drawings described below are only embodiments of the present application. For ordinary technicians in this field, other drawings can be obtained based on the provided drawings without paying any creative work.

[0072] Figure 1 This is a flow chart of the first error information processing method disclosed in this application;

[0073] Figure 2 This is a flow chart of the second error information processing method disclosed in this application;

[0074] Figure 3This is a flow chart of the third error information processing method disclosed in this application;

[0075] Figure 4 A schematic diagram of an electronic device disclosed in this application;

[0076] Figure 5 A server structure diagram provided for this application;

[0077] Figure 6 A terminal structure diagram provided for this application. DETAILED DESCRIPTION

[0078] The following will be combined with the drawings in the embodiments of the present application to clearly and completely describe the technical solutions in the embodiments of the present application. Obviously, the described embodiments are only part of the embodiments of the present application, not all of the embodiments. Based on the embodiments in the present application, all other examples obtained by ordinary technicians in this field without creative work are within the scope of protection of this application.

[0079] At present, in order to avoid errors in individual devices in the server and affect the operation of the entire server business, the tolerance level can be modified to the maximum value, but this method will tolerate the continued retention of erroneous data in the system, so the data integrity and operation safety of the system cannot be guaranteed, which is not conducive to the long-term stable operation of the system. To this end, the present application provides an error information processing solution that can handle fatal errors on individual target devices without affecting the entire server business, thereby reducing the impact of individual erroneous devices in the server on the entire server business.

[0080] See also Figure 1 As shown, the embodiment of the present application discloses a method for processing error information, including:

[0081] S101: If a preset detection condition is met, detect whether a target device in the server has a fatal error.

[0082] In this embodiment, the preset detection conditions are met, including: a read or write operation to a target device is detected; and / or a timeout occurs in a read or write operation to a target device; and / or the current time reaches a detection time point of the target device. That is to say, when a read or write operation to a target device is detected; and / or a timeout occurs in a read or write operation to a target device; and / or the current time reaches a detection time point of the target device, a detection is performed on the target device in the server to determine whether there is a fatal error, and the target device may be at least one PCIe device in the server. PCIe (Peripheral Component Interconnect express) error handling of PCIe devices is a complex and important process used to ensure system stability and data integrity. PCIe error types are classified into correctable errors and uncorrectable errors. Correctable errors can be automatically identified by hardware and automatically corrected or recovered, while uncorrectable errors are divided into non-fatal and fatal. Non-fatal errors are generally handled directly by device specific software, and the link of the error-reporting device can be recovered, and even the data on the link may be recovered without data loss. Fatal errors are generally handled by system software and generally require operations such as reset, so the data on the link will be lost.

[0083] Among them, detecting whether there is a fatal error in the target device in the server includes: querying the parameter status in the error source register for recording fatal error information; if the parameter status value is a first target value (such as 1), it is confirmed that there is a fatal error in the target device; if the parameter status value is a second target value (such as 0), it is confirmed that there is no fatal error in the target device.

[0084] S102. If a fatal error occurs in the target device, corresponding error log information is generated according to the fatal error information recorded in the error source register, and the fatal error information is cleared from the error source register; wherein, when the fatal error information is generated, no error interrupt signal is sent to the processor in the server.

[0085] It should be noted that the error source register is used to record fatal error information existing on the target device. When fatal error information is generated, this information is written into the error source register, which corresponds to the target device. An error source register can be used to record fatal error information existing on at least one target device. In one example, corresponding error log information is generated according to the fatal error information recorded in the error source register, including: reading fatal error information from the error source register; arranging the fatal error information read according to a preset log format to obtain error log information, thereby recording the fatal error information existing on the target device in the form of a log to prevent the fatal error information from being lost for no reason. In one example, the error log information can also be stored locally, and the error log information can be pushed to a preset management terminal, so that relevant personnel can consult the error log information based on the preset management terminal and perform statistics and analysis on the fatal error information existing on the target device. Correspondingly, after obtaining the error log information, it also includes: sending a log notification message to the basic input and output system, so that the basic input and output system constructs a corresponding log structure table according to the error log information, and sends the log structure table to the operating system; the operating system detects fatal errors existing in the target device according to the log structure table, and returns the detected fatal error information to the basic input and output system, so that the basic input and output system checks the log structure table according to the returned information.

[0086] In one example, clearing the fatal error information from the error source register includes: deleting the fatal error information in the error source register using a clear command.

[0087] In one example, when a fatal error message is generated, an error interrupt signal is not sent to a processor in a server, including: when a fatal error message is generated, querying a fatal error tolerance; if the fatal error tolerance is zero, then an error interrupt signal is not sent to the processor in the server. Before querying the fatal error tolerance, the step includes: setting the fatal error tolerance to zero.

[0088] S103: If the read and write operations on the target device are stopped, the target device is turned off and reset.

[0089] In one example, stopping the read / write operation on the target device includes: the read / write operation on the target device is successfully executed; or the read / write operation on the target device is reported as an error; or the read / write operation on the target device is stopped by using an abort command.

[0090] In one example, shutting down the target device includes: powering off the target device from the driver end; or stopping the device process of the target device from running.

[0091] In one example, resetting the target device includes: resetting the target device based on an interface file of the target device operated by the driver.

[0092] In one example, shutting down a target device includes: querying a file directory corresponding to the target device in a file system; determining a control interface of a driver of the target device based on the file directory; shutting down the driver of the target device through the control interface; or querying an interface file directory of the target device; determining a power interface file of the target device based on the interface file directory; and shutting down the power of the target device through the power interface file.

[0093] In one example, resetting a target device includes: querying a file directory corresponding to the target device in a file system; querying the file directory for a reset interface file of the target device; writing a reset command in the reset interface file to reset the target device; or querying an interface file directory of the target device; querying the interface file directory for a reset interface file of the target device; and writing a reset command in the reset interface file to reset the target device.

[0094] In one example, when a fatal error message is generated, an error interrupt signal is not sent to a processor in a server, including: when a fatal error message is generated, querying a fatal error tolerance; if the fatal error tolerance value is zero, not sending an error interrupt signal to the processor in the server; if the fatal error tolerance value is not zero, setting the fatal error tolerance value to zero, and querying the fatal error tolerance again. Wherein, setting the fatal error tolerance value to zero includes: modifying the fatal error tolerance value to zero in the file system.

[0095] It can be seen that in the present application, when a fatal error message is generated, an interrupt is not sent to the processor. When it is confirmed that a fatal error exists in the target device, the relevant fatal error message is recorded in a log format, and then the relevant fatal error message is cleared from the error source register. After that, when the read and write operations on the target device stop executing, the target device is turned off and reset, thereby achieving: without affecting the service of the entire server, fatal errors on individual target devices are processed, thereby reducing the impact of individual error devices in the server on the service of the entire server.

[0096] It should be noted that when an error occurs in a PCIe device in a server, it usually only affects the use of the PCIe device and its link. Therefore, under the premise of ensuring the integrity and security of the entire system data, only resetting or isolating the error PCIe device and cleaning up the related error data will avoid triggering a kernel panic of the entire system and restarting the system. The kernel panic mechanism is a safety feature in the operating system. When a critical system error or unstable state is detected, it is automatically triggered to stop the system operation to prevent the potential damage from spreading. If necessary, the error information is recorded through logs to provide a basis for problem diagnosis and system recovery.

[0097] See also Figure 2 In order to reset or isolate only the erroneous PCIe device when a fatal error occurs, this embodiment provides the following solution: when the root complex device of the PCIe bus receives a fatal error message from the PCIe device, the root complex does not report the error to the CPU through an interrupt according to the fatal error report parameter setting of the relevant register; when the system detects the read and write IO of the PCIe device or the IO timeout of the PCIe device occurs, it queries the fatal error parameter status of the relevant status register, and when it is confirmed that there is a PCIe fatal error, it queries the error source device from the error source register, obtains the detailed error information of the device, records the log and notifies the BIOS, clears the error status of the hardware, stops the current read and write IO task, shuts down the device from the driver end or the PCIe port, clears the relevant error data, and resets the device. Correspondingly, the system can also check the fatal error report parameter status of the relevant register of the PCIe device at a preset threshold time interval and in a polling manner. That is: when the PCIe device has no IO read and write operations, fatal errors are detected by periodic polling. If a fatal error is detected, the above-mentioned operation of shutting down, resetting the device and clearing the error data is performed. In this way, while ensuring that the integrity and security of the system data are not compromised, precise control of specific PCIe devices can be achieved, and only the PCIe device with the problem is reset without affecting the stability of other parts of the system, effectively avoiding abnormal interruption or panic state of the entire system caused by a single device failure, and preventing unnecessary system-level restarts.

[0098] For more details, see Figure 3When the root complex device of the PCIe bus receives a fatal error message from a PCIe device, the root complex sets the Fatal Error Reporting Enable parameter of the Root Error Command Register to 0, that is, it does not report the error to the CPU through an interrupt (MSI / MSI-X). When the system detects a read or write IO for a PCIe device, or when an IO timeout occurs on a PCIe device, it queries the ERR_FATAL Received and Fatal Error Messages Received parameter states of the Root Error Status Register. If both are 1, it indicates that a PCIe fatal error exists. Then, the error source device is queried from the definition of ERR_FATAL SourceIdentification in the Error Source Identification Register.

[0099] For the error source device found, get the detailed error information of the device from the Uncorrectable Error Status Register, clear the error status of the hardware, and then record the specific hardware error in the system log in detail, and write it into the structure table to notify the BIOS to record; corresponding detailed error information, the existing error handling logic in the AER driver will record detailed system log information in the system dmesg and messages log. The structure table is specifically the HEST (Hardware Error Source Table) table in the ACPI (Advanced Configuration and Power Interface) specification, which is used to provide a structured record of hardware error reports. The HEST table allows the system firmware to define the source of hardware errors. Through the HEST table, the system can identify and record different types of hardware errors. In the existing error handling logic, the BIOS passes the error information to the system by filling in the HEST table. In this example, the system obtains the error information from the hardware detection by itself, and the system also needs to pass the error information to the BIOS through the HEST table to record the relevant hardware log. AER (Advanced Error Reporting Capability) is a standardized error reporting mechanism defined in the PCIe standard that allows hardware devices to report detailed error events to software.

[0100] The next step is to stop the read and write IO task process corresponding to the error device. Specifically, using the lsof command in the system combined with the device file path of the error device can accurately identify and list all processes that access the PCIe device file. After confirming that these processes need to be stopped, use the kill command and send the TERM end signal to these processes. Of course, the process can be allowed to complete the current work and then exit. If the device cannot respond to the TERM signal, use the kill command with the KILL signal to forcibly terminate the process.

[0101] After that, turn off the device from the driver side or PCIe side and clear the related error data. Specifically, the / sys / bus / pci / drivers / directory under the system is part of the sysfs file system, which provides detailed information and control interfaces about the PCIE device driver. It contains entries for each loaded PCI driver in the system. Each entry corresponds to a specific PCI driver and contains a variety of information and control options about the driver. Among them, the / sys / bus / pci / drivers / {device driver name} / {address corresponding to the device} / enable parameter can control the opening and closing of the corresponding device from the driver side. When the system kernel starts, the system will create an interface file directory ( / sys / bus / pci / slots / ) for each PCI slot port (PCIslot detection driver) detected, where: / sys / bus / pci / slots / {slots number corresponding to the device} / power file is a power interface file, which is used to control the power options of the PCIe device. The system can use this interface file to perform power on and off operations on the PCIe device that reports an error, and can implement the shutdown operation of the error device from the driver side or the PCIe side.

[0102] Finally, reset the device. Specifically, if the device supports it, there is a reset interface file in the device directory in the system / sys file system. You can reset the device by writing commands to this file. You can also reset the device through the / sys / bus / pci / drivers / {device driver name} / {device corresponding address} / reset interface file provided by the PCIe driver.

[0103] When implementing the above solution, a service controlled by systemctl needs to be deployed at the system management level. The core function of this service is to use the polling mechanism to check the status of the Root Error Status Register at a predetermined time interval (for example, once per second) when the system is not performing IO read and write activities. Specifically, the service will monitor the status of the two parameters ERR_FATAL Received and Fatal Error Messages Received. If the values ​​of these two parameters are both 1, it indicates that there is a PCIe fatal error, and it is necessary to call the above-mentioned shutdown and reset device and clear error data operations. This can achieve: while ensuring that the integrity and security of system data are not compromised, it can achieve precise control of specific PCIe devices, and only perform reset operations on PCIe devices with problems without affecting the stability of other parts of the system, effectively avoiding abnormal interruption or panic state of the entire system caused by a single device failure, thereby preventing unnecessary system-level restarts.

[0104] An error information processing device provided in an embodiment of the present application is introduced below. The error information processing device described below can be referenced to other embodiments described in this document.

[0105] The embodiment of the present application discloses an error information processing device, including:

[0106] An error detection module, used to detect whether a target device in the server has a fatal error if a preset detection condition is met;

[0107] An information cleaning module is used to generate corresponding error log information according to the fatal error information recorded in the error source register if a fatal error exists in the target device, and clear the fatal error information from the error source register; wherein, when the fatal error information is generated, an error interrupt signal is not sent to the processor in the server;

[0108] The device processing module is used to close the target device and reset the target device if the read and write operations on the target device stop being executed.

[0109] In one example, the error detection module can detect a read or write operation to the target device; and / or a timeout in a read or write operation to the target device; and / or a current time reaches a detection time point of the target device.

[0110] In one example, the error detection module is specifically used to:

[0111] Query the parameter status in the error source register used to record fatal error information;

[0112] If the parameter status value is the first target value, it is confirmed that a fatal error exists in the target device;

[0113] If the parameter status value is the second target value, it is confirmed that there is no fatal error in the target device.

[0114] In one example, the information cleaning module is specifically used to:

[0115] Read fatal error information from the error source register;

[0116] The read fatal error information is sorted according to a preset log format to obtain error log information.

[0117] In one example, it also includes:

[0118] The storage module is used to store error log information locally and push the error log information to the preset management terminal.

[0119] In one example, the information cleaning module is specifically used to:

[0120] Use the clear command to delete the fatal error information in the error source register.

[0121] In one example, the device processing module is specifically used to:

[0122] The read and write operations on the target device are executed successfully; or the read and write operations on the target device are executed with an error; or the read and write operations on the target device are stopped by using an abort command.

[0123] In one example, the device processing module is specifically used to:

[0124] Power off the target device from the driver side.

[0125] In one example, the device processing module is specifically used to:

[0126] Stop the device process of the target device.

[0127] In one example, the device processing module is specifically used to:

[0128] The target device is reset based on the interface file of the target device operated by the driver side.

[0129] In one example, when a fatal error message is generated, no error interrupt signal is sent to a processor in the server, including:

[0130] When a fatal error message is generated, query the fatal error tolerance;

[0131] If the fatal error tolerance is set to zero, no error interrupt signal is sent to the processor in the server.

[0132] In one example, before querying the fatal error tolerance, include:

[0133] Set the fatal error tolerance to zero.

[0134] Among them, for more specific working processes of each module and unit in this embodiment, reference can be made to the corresponding contents disclosed in the aforementioned embodiments, which will not be repeated here.

[0135] It can be seen that this embodiment provides an error information processing device, which can process fatal errors on individual target devices without affecting the service of the entire server, thereby reducing the impact of individual error devices in the server on the service of the entire server.

[0136] An electronic device provided in an embodiment of the present application is introduced below. The electronic device described below can be referenced to other embodiments described in this document.

[0137] See also Figure 4 As shown, the embodiment of the present application discloses an electronic device, including:

[0138] Memory 401, used for storing computer programs;

[0139] The processor 402 is used to execute the computer program to implement the method disclosed in any of the above embodiments.

[0140] In this embodiment, when the processor executes the computer program stored in the memory, the following steps can be specifically implemented: if the preset detection conditions are met, it is detected whether there is a fatal error in the target device in the server; if there is a fatal error in the target device, corresponding error log information is generated according to the fatal error information recorded in the error source register, and the fatal error information is cleared from the error source register; wherein, when the fatal error information is generated, an error interrupt signal is not sent to the processor in the server; if the read and write operations on the target device are stopped, the target device is turned off and reset.

[0141] In this embodiment, when the processor executes the computer program stored in the memory, the following steps can be specifically implemented: a read or write operation for a target device is detected; and / or a read or write operation for a target device times out; and / or the current time reaches a detection time point for the target device.

[0142] In this embodiment, when the processor executes the computer program stored in the memory, the following steps can be specifically implemented: query the parameter status in the error source register for recording fatal error information; if the parameter status value is the first target value, it is confirmed that a fatal error exists in the target device; if the parameter status value is the second target value, it is confirmed that no fatal error exists in the target device.

[0143] In this embodiment, when the processor executes the computer program stored in the memory, the following steps may be specifically implemented: reading fatal error information from the error source register; and arranging the read fatal error information according to a preset log format to obtain error log information.

[0144] In this embodiment, when the processor executes the computer program stored in the memory, the following steps may be specifically implemented: storing the error log information locally, and pushing the error log information to a preset management terminal.

[0145] In this embodiment, when the processor executes the computer program stored in the memory, the following steps may be specifically implemented: using a clear command to delete fatal error information in the error source register.

[0146] In this embodiment, when the processor executes the computer program stored in the memory, the following steps can be specifically implemented: the read and write operations on the target device are executed successfully; or the read and write operations on the target device are executed with an error report; or the read and write operations on the target device are stopped using an abort command.

[0147] In this embodiment, when the processor executes the computer program stored in the memory, the following steps may be specifically implemented: powering off the target device from the driver end.

[0148] In this embodiment, when the processor executes the computer program stored in the memory, the following steps may be specifically implemented: stopping the device process of the target device.

[0149] In this embodiment, when the processor executes the computer program stored in the memory, the following steps may be specifically implemented: operating the interface file of the target device based on the driver end to reset the target device.

[0150] In this embodiment, when the processor executes the computer program stored in the memory, the following steps can be specifically implemented: when a fatal error message is generated, query the fatal error tolerance; if the fatal error tolerance is zero, do not send an error interrupt signal to the processor in the server.

[0151] In this embodiment, when the processor executes the computer program stored in the memory, the following steps may be specifically implemented: setting the fatal error tolerance to zero.

[0152] Furthermore, the present application also provides an electronic device. The electronic device can be Figure 5 The server shown can also be Figure 6 Terminal shown. Figure 5 and Figure 6 All of them are structural diagrams of electronic devices according to an exemplary embodiment, and the contents in the diagrams cannot be regarded as any limitation on the scope of use of the present application.

[0153] Figure 5 A schematic diagram of the structure of a server provided in an embodiment of the present application. The server may specifically include: at least one processor, at least one memory, a power supply, a communication interface, an input / output interface, and a communication bus. The memory is used to store a computer program, which is loaded and executed by the processor to implement the relevant steps in the error information processing disclosed in any of the aforementioned embodiments.

[0154] In this embodiment, the power supply is used to provide working voltage for each hardware device on the server; the communication interface can create a data transmission channel between the server and external devices, and the communication protocol it follows is any communication protocol that can be applied to the technical solution of the present application, and is not specifically limited here; the input and output interface is used to obtain external input data or output data to the outside world, and its specific interface type can be selected according to specific application needs and is not specifically limited here.

[0155] In addition, the memory as a carrier for resource storage can be a read-only memory, random access memory, disk or CD, etc. The resources stored thereon include operating system, computer programs and data, etc. The storage method can be temporary storage or permanent storage.

[0156] The operating system is used to manage and control the hardware devices and computer programs on the server to realize the operation and processing of the data in the memory by the processor, and it can be Windows Server, Netware, Unix, Linux, etc. In addition to the computer program that can be used to complete the error information processing method disclosed in any of the above embodiments, the computer program can further include computer programs that can be used to complete other specific tasks. In addition to data such as application update information, the data can also include data such as application developer information.

[0157] Figure 6 A schematic diagram of the structure of a terminal provided in an embodiment of the present application, the terminal may specifically include but is not limited to a smart phone, a tablet computer, a laptop computer or a desktop computer, etc.

[0158] Generally, the terminal in this embodiment includes: a processor and a memory.

[0159] Among them, the processor may include one or more processing cores, such as a 4-core processor, an 8-core processor, etc. The processor may be implemented in at least one hardware form of DSP (Digital Signal Processing), FPGA (Field-Programmable Gate Array), and PLA (Programmable Logic Array). The processor may also include a main processor and a coprocessor. The main processor is a processor for processing data in the awake state, also known as a CPU (Central Processing Unit); the coprocessor is a low-power processor for processing data in the standby state. In some embodiments, the processor may be integrated with a GPU (Graphics Processing Unit), which is responsible for rendering and drawing the content to be displayed on the display screen. In some embodiments, the processor may also include an AI (Artificial Intelligence) processor, which is used to process computing operations related to machine learning.

[0160] The memory may include one or more computer non-volatile storage media, which may be non-transitory. The memory may also include high-speed random access memory, and non-volatile memory, such as one or more disk storage devices, flash memory storage devices. In this embodiment, the memory is at least used to store the following computer program, wherein, after the computer program is loaded and executed by the processor, it can implement the relevant steps in the error information processing method performed by the terminal side disclosed in any of the aforementioned embodiments. In addition, the resources stored in the memory may also include an operating system and data, etc., and the storage method may be temporary storage or permanent storage. Among them, the operating system may include Windows, Unix, Linux, etc. The data may include, but is not limited to, update information of the application.

[0161] In some embodiments, the terminal may also include a display screen, an input and output interface, a communication interface, a sensor, a power supply, and a communication bus.

[0162] Those skilled in the art will understand that Figure 6 The structure shown in the figure does not constitute a limitation on the terminal, and may include more or fewer components than those shown in the figure.

[0163] A non-volatile storage medium provided in an embodiment of the present application is introduced below. The non-volatile storage medium described below can be cross-referenced with other embodiments described herein.

[0164] A non-volatile storage medium for storing a computer program, wherein the computer program, when executed by a processor, implements the error information processing method disclosed in the above-mentioned embodiment. The non-volatile storage medium is a computer-readable non-volatile storage medium, which, as a carrier for storing resources, may be a read-only memory, a random access memory, a disk or an optical disk, etc. The resources stored thereon include an operating system, a computer program and data, etc., and the storage method may be temporary storage or permanent storage.

[0165] In this embodiment, when the processor executes the computer program stored in the non-volatile storage medium, the following steps can be specifically implemented: if the preset detection conditions are met, it is detected whether there is a fatal error in the target device in the server; if there is a fatal error in the target device, corresponding error log information is generated according to the fatal error information recorded in the error source register, and the fatal error information is cleared from the error source register; wherein, when the fatal error information is generated, an error interrupt signal is not sent to the processor in the server; if the read and write operations on the target device are stopped, the target device is turned off and reset.

[0166] In this embodiment, when the processor executes the computer program stored in the non-volatile storage medium, the following steps can be specifically implemented: a read or write operation for the target device is detected; and / or a read or write operation for the target device times out; and / or the current time reaches the detection time point of the target device.

[0167] In this embodiment, when the processor executes the computer program stored in the non-volatile storage medium, the following steps can be specifically implemented: query the parameter status in the error source register for recording fatal error information; if the parameter status value is the first target value, it is confirmed that a fatal error exists in the target device; if the parameter status value is the second target value, it is confirmed that no fatal error exists in the target device.

[0168] In this embodiment, when the processor executes the computer program stored in the non-volatile storage medium, the following steps may be specifically implemented: reading fatal error information from the error source register; and arranging the read fatal error information according to a preset log format to obtain error log information.

[0169] In this embodiment, when the processor executes the computer program stored in the non-volatile storage medium, the following steps may be specifically implemented: storing error log information locally, and pushing the error log information to a preset management terminal.

[0170] In this embodiment, when the processor executes the computer program stored in the non-volatile storage medium, the following steps may be specifically implemented: using a clear command to delete fatal error information in the error source register.

[0171] In this embodiment, when the processor executes the computer program stored in the non-volatile storage medium, the following steps can be specifically implemented: the read and write operations on the target device are executed successfully; or the read and write operations on the target device are reported as errors; or the read and write operations on the target device are stopped using an abort command.

[0172] In this embodiment, when the processor executes the computer program stored in the non-volatile storage medium, the following steps may be specifically implemented: powering off the target device from the drive end.

[0173] In this embodiment, when the processor executes the computer program stored in the non-volatile storage medium, the following steps may be specifically implemented: stopping the device process of the target device.

[0174] In this embodiment, when the processor executes the computer program stored in the non-volatile storage medium, the following steps may be specifically implemented: operating the interface file of the target device based on the driver end to reset the target device.

[0175] In this embodiment, when the processor executes the computer program stored in the non-volatile storage medium, the following steps can be specifically implemented: when a fatal error message is generated, query the fatal error tolerance; if the fatal error tolerance is zero, do not send an error interrupt signal to the processor in the server.

[0176] In this embodiment, when the processor executes the computer program stored in the non-volatile storage medium, the following steps may be specifically implemented: setting the fatal error tolerance to zero.

[0177] A computer program product provided in an embodiment of the present application is introduced below. The computer program product described below can be cross-referenced with other embodiments described in this document.

[0178] A computer program product comprises a computer program / instruction, which implements the steps of the above-disclosed error information processing method when executed by a processor.

[0179] The various embodiments in this specification are described in a progressive manner, and each embodiment focuses on the differences from other embodiments. The same or similar parts between the various embodiments can be referenced to each other.

[0180] The steps of the method or algorithm described in conjunction with the embodiments disclosed herein may be implemented directly using hardware, a software module executed by a processor, or a combination of the two. The software module may be placed in a random access memory (RAM), a memory, a read-only memory (ROM), an electrically programmable ROM, an electrically erasable programmable ROM, a register, a hard disk, a removable disk, a CD-ROM, or any other form of non-volatile storage medium known in the art.

[0181] Specific examples are used herein to illustrate the principles and implementation methods of the present application. The description of the above embodiments is only used to help understand the method of the present application and its core idea. At the same time, for those skilled in the art, according to the idea of ​​the present application, there will be changes in the specific implementation methods and application scope. In summary, the content of this specification should not be understood as a limitation on the present application.

Claims

1. A method for processing error information, characterized in that: include: If the preset detection conditions are met, the target device in the server is detected to see if there is a fatal error; If a fatal error occurs in the target device, corresponding error log information is generated according to the fatal error information recorded in the error source register, and the fatal error information is cleared from the error source register; wherein when the fatal error information is generated, an error interrupt signal is not sent to the processor in the server; If the read and write operations on the target device are stopped, shutting down the target device and resetting the target device; Among them, the corresponding error log information is generated according to the fatal error information recorded in the error source register, including: Reading the fatal error information from the error source register; Arrange the fatal error information read according to a preset log format to obtain the error log information; Correspondingly, after obtaining the error log information, the following is also included: Sending a log notification message to a basic input / output system, so that the basic input / output system constructs a corresponding log structure table according to the error log information, and sends the log structure table to an operating system; the operating system detects a fatal error existing in the target device according to the log structure table, and returns the detected fatal error information to the basic input / output system, so that the basic input / output system checks the log structure table according to the returned information.

2. The method according to claim 1, characterized in that: Meet the preset detection conditions, including: A read or write operation for the target device is detected; and / or a read or write operation for the target device times out; and / or the current time reaches a detection time point for the target device.

3. The method according to claim 1, characterized in that Detects whether there are fatal errors on the target device in the server, including: Querying the parameter status in the error source register for recording the fatal error information; If the parameter state value is the first target value, confirming that a fatal error exists in the target device; If the parameter status value is the second target value, it is confirmed that there is no fatal error in the target device.

4. The method according to claim 1, characterized in that: Also includes: The error log information is stored locally and pushed to a preset management terminal.

5. The method according to claim 1, characterized in that The read and write operations on the target device are stopped, including: The read and write operations for the target device are executed successfully; or the read and write operations for the target device are executed with an error; or the read and write operations for the target device are stopped by using an abort command.

6. The method according to claim 1, characterized in that Shutting down the target device, including: Query the file directory corresponding to the target device in the file system; Determining a control interface of a driver of the target device based on the file directory; The driver of the target device is closed through the control interface.

7. The method according to claim 1, characterized in that Shutting down the target device, including: Query the interface file directory of the target device; Determine the power interface file of the target device based on the interface file directory; The target device is powered off through the power interface file.

8. The method according to claim 1, characterized in that Resetting the target device includes: Query the file directory corresponding to the target device in the file system; Searching the file directory for a reset interface file of the target device; A reset command is written into the reset interface file to reset the target device.

9. The method according to claim 1, characterized in that: Resetting the target device includes: Query the interface file directory of the target device; Query the target device's reset interface file in the interface file directory; A reset command is written into the reset interface file to reset the target device.

10. The method according to any one of claims 1 to 9, characterized in that: When the fatal error information is generated, not sending an error interrupt signal to the processor in the server includes: When the fatal error message is generated, query the fatal error tolerance; If the fatal error tolerance is zero, no error interrupt signal is sent to the processor in the server; If the fatal error tolerance value is not zero, the fatal error tolerance value is set to zero, and the fatal error tolerance is queried again.

11. The method according to any one of claims 1 to 9, characterized in that: Setting the fatal error tolerance to zero includes: The fatal error tolerance value is modified to zero in the file system.

12. An electronic device, characterized in that: include: Memory for storing computer programs; A processor, configured to execute the computer program to implement the method according to any one of claims 1 to 11.

13. A non-volatile storage medium, characterized in that: Used to store a computer program, wherein when the computer program is executed by a processor, the method according to any one of claims 1 to 11 is implemented.

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