Method and device for improving working efficiency of computer fault analysis and storage medium

By obtaining and storing the print logs of the host CPU in real time in computer fault analysis, and using the serial log analysis chip for rapid comparison, the problems of difficulty in reproducing and low analysis efficiency are solved, and the accuracy of fault location and problem solving are accelerated.

CN120123136AInactive Publication Date: 2025-06-10联想长风科技(北京)有限公司

Patent Information

Application Number
CN202510282529.5
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2025-03-11
Publication Date
2025-06-10
Estimated Expiration
Not applicable · inactive patent

Smart Images

  • Figure CN120123136A_ABST
    Figure CN120123136A_ABST
Patent Text Reader

Abstract

The invention discloses a method and device for improving the working efficiency of computer fault analysis and a storage medium, and relates to the related field of computer fault diagnose.The method comprises the steps that a printing log of a host CPU is obtained, the printing log is output to a device storage Rom of the device in a character string mode through a serial port debugging interface to be stored, and the log storage Rom is obtained; calling a serial port log analysis chip of the equipment to compare the first error information in the log storage Rom with error information in a built-in database to obtain a first error fault type; and sending the first error fault type to a liquid crystal display screen for displaying. The technical problems of high fault reproduction difficulty and low analysis efficiency in the existing computer fault analysis are solved, and the technical effects of improving the fault positioning accuracy, accelerating the problem solving process and optimizing the research and development test efficiency are achieved.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of computer fault diagnosis, and particularly to a method, device, and storage medium for improving the work efficiency of computer fault analysis. Background Art

[0002] With the in-depth adaptation of domestic host platforms and domestic operating systems, the software and hardware problems encountered in the R & D and testing processes are becoming increasingly complex and diverse. Efficiently and accurately analyzing and solving these problems is crucial for improving R & D efficiency and product quality. Currently, the main method to solve this problem is that when engineers encounter problems during testing or use, they connect an external serial port device to reproduce the fault and capture the serial port log when the fault occurs, and use this as the basis for analyzing and solving the problem. However, the current method requires reconnecting the serial port device and reproducing the problem after the fault occurs. This process is not only time-consuming and laborious, but also difficult to reproduce for some probabilistically occurring faults, resulting in low efficiency in problem analysis and solution. Especially considering that the domestic platform is still in an unstable development stage, with various compatibility and R & D problems occurring frequently, the existing technical model severely restricts the accurate positioning and judgment of faults by R & D engineers and testers.

[0003] In the current related technologies, there are technical problems such as difficult fault reproduction and low analysis efficiency in computer fault analysis. Summary of the Invention

[0004] This application provides a method, device, and storage medium for improving the work efficiency of computer fault analysis. By preparing and connecting a serial port device in advance during the verification process, obtaining and storing the print log of the host CPU in real time to the device storage Rom through the serial port debugging interface, using the serial port log analysis chip to quickly compare the stored error information with the error information in the built-in database to determine the fault type, and intuitively displaying the result on the liquid crystal display screen, etc., technical effects of improving the accuracy of fault positioning, accelerating the problem-solving process, and optimizing the R & D and testing efficiency are achieved.

[0005] This application provides a method for improving the work efficiency of computer fault analysis, including: obtaining the print log of the host CPU, outputting the print log in the form of a string to the device storage Rom of the device for storage through the serial port debugging interface to obtain a log storage Rom; calling the serial port log analysis chip of the device to compare the first error information in the log storage Rom with the error information in the built-in database to obtain the first error fault type; sending the first error fault type to the liquid crystal display screen for display.

[0006] In a possible implementation, the following processing is performed: extract a first set of key characters of the first error message according to a preset set of key character types; compare the first set of key characters with the set of key characters of the error messages stored in the built-in database to determine whether the comparison is successful. If so, obtain a first error fault type.

[0007] In a possible implementation, the following processing is performed: if the comparison is not successful, return an empty result.

[0008] In a possible implementation, the following processing is performed: obtain a set of known error fault types and a set of corresponding key characters for each error fault type set, and construct a fault code mapping comparison table; construct the built-in database based on the fault code mapping comparison table.

[0009] In a possible implementation, the following processing is performed: the built-in database is used to provide comparison data for the serial port log analysis chip and is updated according to a preset frequency.

[0010] In a possible implementation, the following processing is performed: the host CPU is an FTD2000-8Core.

[0011] In a possible implementation, the following processing is performed: one end of the device is connected to the serial port of the host CPU through a serial port connection method, and the other end is a liquid crystal display screen.

[0012] In a possible implementation, the following processing is performed: the serial port debugging interface is a UART debug.

[0013] This application also provides an electronic device, including: a memory for storing executable instructions; a processor for implementing a method for improving the work efficiency of computer fault analysis when executing the executable instructions stored in the memory.

[0014] This application also provides a computer-readable storage medium, including: a computer program stored thereon, which implements a method for improving the work efficiency of computer fault analysis when executed by a processor.

[0015] A method, device, and storage medium for improving the efficiency of computer fault analysis proposed in this application first obtain the print log of the host CPU, output the print log in the form of a string to the device storage Rom of the device through the serial port debugging interface for storage to obtain the log storage Rom, then call the serial port log analysis chip of the device to compare the first error message in the log storage Rom with the error messages in the built-in database to obtain the first error fault type, and finally send the first error fault type to the liquid crystal display for display. It achieves the technical effects of improving the accuracy of fault location, accelerating the problem-solving process, and optimizing the R & D and testing efficiency. Brief Description of the Drawings

[0016] To more clearly illustrate the technical solutions of the embodiments of the present invention, the drawings of the embodiments of the present invention will be briefly introduced below. Flowcharts are used in this application to illustrate the operations performed by the methods according to the embodiments of this application. It should be understood that the operations before or below do not necessarily need to be performed precisely in sequence. On the contrary, as needed, they can be performed in reverse order or simultaneously. At the same time, other operations can also be added to these processes, or one or several operations can be removed from these processes.

[0017] Figure 1 It is a schematic flowchart of a method for improving the efficiency of computer fault analysis provided by an embodiment of this application.

[0018] Figure 2 It is a schematic diagram of the working principle of a method for improving the efficiency of computer fault analysis provided by an embodiment of this application.

[0019] Figure 3 It is a schematic structural diagram of an electronic device provided by an embodiment of this application.

[0020] Description of the reference numerals: input device 301, processor 302, memory 303, output device 304. Detailed Description of the Embodiments

[0021] The above description is only an overview of the technical solutions of this application. In order to be able to understand the technical means of this application more clearly, it can be implemented according to the content of the specification. And in order to make the above and other purposes, features, and advantages of this application more obvious and understandable, the following specifically lists the detailed embodiments of this application.

[0022] In order to make the purpose, technical solutions, and advantages of this application clearer, the present application will be further described in detail below in conjunction with the drawings. The described embodiments should not be regarded as limitations of the present application. All other embodiments obtained by those of ordinary skill in the art without creative efforts fall within the scope of protection of this application.

[0023] In the following description, "some embodiments" are involved, which describe a subset of all possible embodiments. However, it can be understood that "some embodiments" can be the same subset or different subsets of all possible embodiments, and can be combined with each other without conflict. The terms "first / second" involved are only used to distinguish similar objects and do not represent a specific order for the objects. The terms "comprising" and "having" and any variations thereof are intended to cover non-exclusive inclusion. For example, a process, method, system, product, or server that includes a series of steps or units does not necessarily have to be limited to those steps or units clearly listed, but may include other steps or modules that are not clearly listed or are inherent to these processes, methods, products, or devices. Unless otherwise defined, all technical and scientific terms used herein have the same meaning as commonly understood by those skilled in the technical field to which this application belongs. The terms used herein are only for the purpose of describing the embodiments of this application.

[0024] An embodiment of this application provides a method for improving the work efficiency of computer fault analysis, as Figure 1 and Figure 2 shown. The method includes:

[0025] Step S100, obtain the print log of the host CPU, output the print log in the form of a string to the device storage Rom of the device through the serial port debugging interface for storage, and obtain the log storage Rom.

[0026] Specifically, through the log recording function provided by the host operating system or BIOS, capture log data such as error information and warning information generated during the operation of the CPU. This log data includes key information such as timestamps, error codes, and error descriptions. Use the serial port of the host (such as RS-232, USB to serial port, etc.) as the data transmission channel, and through writing or calling existing serial communication programs, send the captured log data out in the form of a string through the serial port. The device refers to a fault analysis device, which is internally equipped with a non-volatile memory (Rom) for long-term data storage. The serial communication program writes the received log string data to a specified location in this memory to complete data storage. Among them, the host CPU refers to the main processor of the computer, which is responsible for executing program instructions and processing data. The print log refers to various record information generated during the operation of the CPU, which is used to diagnose problems or understand the system status. The serial port debugging interface is an interface for data transmission between devices, which is used for debugging and communication. The device storage Rom refers to the non-volatile memory inside the device for long-term data storage.

[0027] In a possible implementation, step S100 further includes step S110, where the host CPU is FTD2000-8Core. Specifically, a checkpoint is set in the system or application for the operating system or BIOS to automatically detect hardware information at startup, including the CPU model. FTD2000-8Core is a specific CPU model provided by Phytium, with eight processing cores and suitable for high-performance computing scenarios. According to the CPU model, relevant parameters of log output are set, such as log level, output format, storage location, etc. For example, for a specific CPU model like FTD2000-8Core, a higher log level needs to be set to capture more key information, or the output format needs to be adjusted to better adapt to the subsequent analysis process. These configurations can be achieved by modifying the system configuration file, writing specific scripts or programs. Since different CPU models have differences in performance, power consumption management, etc., it is necessary to configure the log output settings according to the specific CPU model. This implementation method ensures that the log information can be correctly captured and stored by ensuring the compatibility of the log output settings with the host CPU, providing a reliable data source for subsequent fault analysis.

[0028] In a possible implementation, step S100 further includes step S120, and the serial port debugging interface is UART debug. Specifically, during the hardware design phase or system configuration process, according to the host CPU (such as FTD2000-8Core) and subsequent debugging and log collection requirements, UART (Universal Asynchronous Receiver-Transmitter) is selected as the serial port debugging interface. Configure the communication parameters of the UART interface, including baud rate (data transmission rate), data bits, stop bits, parity bits, etc., to ensure that the communication between the host CPU and the device can be correct. Connect the UART interface of the host CPU to the corresponding interface of the device using an appropriate serial cable (such as RS-232, RS-485, or USB-to-serial cable, etc.) to form a physical communication link. In the operating system or BIOS of the host CPU, enable the debugging function of the UART interface and set the corresponding debugging output options to ensure that the printed logs can be output through the UART interface. Write or configure a software program or script for capturing and storing the printed logs. This program or script can listen to the data input on the UART interface and store the received log information as a string in the device storage Rom. After the connection and software settings are completed, perform necessary debugging work to ensure that the UART interface can work properly, the printed logs can be correctly output and stored. Through simulated or actual error scenarios, verify the reliability and accuracy of the UART interface and the log collection program. As a widely used serial communication protocol, the UART interface has the advantages of simplicity, reliability, and easy implementation, and is very suitable for debugging and log collection scenarios. This implementation method ensures that the printed logs can be accurately and timely transmitted to the storage medium by correctly configuring the communication parameters and hardware connection of the UART interface, and writing the corresponding software program or script, thus improving the work efficiency of fault analysis.

[0029] Step S200: Invoke the serial port log analysis chip of the device to compare the first error message in the log storage Rom with the error messages in the built-in database, and obtain the first error fault type.

[0030] Specifically, a log analysis chip is integrated inside the device. This chip is a hardware device or chip specifically used for analyzing and processing serial port log data. Through the control program or driver program of the device, the function of this chip is invoked. The serial port log analysis chip reads the first error message (i.e., any specific error message) from the log storage Rom. Multiple known error fault types and corresponding error messages are stored in the chip or the built-in database connected to it. The chip compares the read error message with the information in the database to find the most matching error fault type. The first error fault type refers to the error fault type that is most matched with the first error message obtained through the comparison.

[0031] In a possible implementation, step S200 further includes step S210 of extracting a first set of key characters of the first error message according to a preset set of key character types. Specifically, the serial port log analysis chip accesses the device storage Rom storing the CPU print log, and the parsing module in the chip parses the log content line by line or segment by segment to identify possible error messages. Among them, the preset set of key character types is a set of predefined keywords or character patterns related to computer failures, such as error codes, abnormal status identifiers, etc. These key characters are formulated based on historical failure data, error code lists provided by manufacturers, or industry standards. During the process of parsing the log, the chip uses a pattern matching algorithm (such as regular expressions) to identify character sequences in the log that match the preset set of key character types. These matching character sequences are extracted to form the first set of key characters.

[0032] Step S220 of comparing the first set of key characters with the set of key characters of the error messages stored in the built-in database to determine whether the comparison is successful. If so, the first error failure type is obtained. Specifically, the serial port log analysis chip accesses the built-in database, which stores various known failure types and their corresponding sets of key characters. A comparison algorithm (such as set intersection operation, similarity calculation, etc.) is used to compare the first set of key characters with the set of key characters of each error message in the database. If the first set of key characters highly matches the set of key characters of a certain error message (such as the set intersection reaches a certain proportion, or the similarity exceeds a preset threshold), the comparison is considered successful. Once the comparison is successful, the chip records the corresponding error failure type, that is, the first error failure type. This implementation method realizes the automation and intelligence of fault analysis through the comparison of the preset set of key character types and the built-in database, reducing the time and error rate of manual log interpretation.

[0033] In a possible implementation, step S200 further includes step S230. If the comparison is unsuccessful, the return is empty. Specifically, in step S220, the serial port log analysis chip has completed the comparison between the first set of key characters and the set of key characters of error messages in the built-in database. At this time, the chip needs to determine whether the comparison result is successful. If the comparison is unsuccessful, that is, the first set of key characters does not match any of the sets of key characters of error messages in the built-in database, the chip marks this result as "comparison unsuccessful". Subsequently, the chip will generate a null value or a specific error code, indicating that no matching fault type is found. This null value or error code will be used as the output of step S200. Once it is determined that the comparison is unsuccessful, the chip will not continue to execute the subsequent processing flow related to the fault type. Although the current step does not produce a valid output of the fault type, the chip needs to ensure that other parts of the system (such as step S300) can correctly process this null value or error code input. The chip passes the null value or error code to the module responsible for displaying the fault type (such as the liquid crystal display control module). When the display control module receives the null value or error code, it will not trigger any display operation, ensuring that no information related to the fault type is displayed on the liquid crystal display. If the system cannot accurately identify the fault type, displaying irrelevant information may mislead the user. This implementation avoids confusing or misleading the user by not displaying any content.

[0034] In a possible implementation, step S200 further includes step S240, which obtains the set of known error fault types and the corresponding set of key characters for each error fault type set, and constructs a fault code mapping comparison table. Specifically, collect the known error fault types and their corresponding sets of key characters from internal or external resources of the system (such as fault records, technical documents, etc.). The set of known error fault types is a group of predefined and recorded error fault types in the system, representing various known problems that the device may encounter. The set of key characters means that for each known error fault type, there will be one or more key characters (such as error codes, specific error description words, etc.), and these characters combined form the unique identifier for identifying this error type. Based on the information collected, create a data structure (such as a hash table, dictionary, etc.), where each known error fault type is associated with one or more sets of key characters. This data structure is the fault code mapping comparison table, which allows the system to quickly find the error fault type corresponding to a specific set of key characters.

[0035] Step S250, build the built-in database based on the fault code mapping comparison table. Specifically, store the data in the fault code mapping comparison table into the built-in database according to a certain format and structure, including operations such as creating database tables, defining fields, and inserting data. Eventually, the system has a database containing all known error fault types and their key character sets, which can be used for quickly comparing and identifying new error messages. This implementation method builds a built-in database containing all known error fault types and their key character sets in advance. When the system receives new error messages, it can quickly compare and identify the error types without manual checking one by one, which not only reduces the time of manual analysis but also reduces the risk of misjudgment.

[0036] The following is an example. The fault code mapping comparison table is as follows: fail 123456 for fault 1; fail112345 for fault 2; fail 134646 for fault 3; ……………. If the serial port output log is: xxxxxxxxxxxxxxxxxxx fail123456xxxxxxxx, then the liquid crystal display shows: fault 1.

[0037] In a possible implementation, step S200 further includes step S260. The built-in database is used to provide comparison data for the serial port log analysis chip and is updated according to a preset frequency. Specifically, the serial port log analysis chip accesses the data in the built-in database through a specific interface (such as an API) or a database query statement (such as SQL). The data in the built-in database needs to be updated regularly or according to specific conditions to ensure that it contains the latest error fault types and key character sets. Among them, the preset frequency is a pre-set time interval or condition used to trigger the database update operation. For example, it can be set to update once at midnight every day, or to update immediately when a new error fault type is detected. The update operation includes obtaining new error fault types and key character sets from external data sources (such as update packages released by manufacturers, new discoveries on technical forums, etc.), and then inserting these data into the built-in database or replacing the original old data by writing specific data import scripts or programs. With the development of technology and the update of equipment, new error fault types and key character sets will continuously appear. If the built-in database cannot be updated in time, the serial port log analysis chip may not be able to identify these new error types when comparing error messages, resulting in a decrease in the accuracy and efficiency of fault analysis. Therefore, this implementation method ensures that the serial port log analysis chip can always use the latest data for comparison by updating the built-in database according to the preset frequency, thereby improving the accuracy and efficiency of fault analysis.

[0038] Step S300, send the first error fault type to the liquid crystal display for display.

[0039] Specifically, the device is equipped with a liquid crystal display screen for displaying analysis results and relevant information. Through the control program or driver program of the device, the information of the first error fault type is sent to the display buffer of the liquid crystal display screen. The liquid crystal display screen displays the name or description of the first error fault type on the screen according to the received information. Among them, the liquid crystal display screen is an electronic device for displaying information such as text and images. The display buffer refers to the storage area inside the liquid crystal display screen for temporarily storing data to be displayed. In the embodiment of the present application, a serial port device is prepared and connected in advance during the verification process, and the print log of the host CPU is obtained and stored in the device storage Rom in real time through the serial port debugging interface. The serial port log analysis chip quickly compares the stored error information with the error information in the built-in database to determine the fault type, and intuitively displays the result on the liquid crystal display screen and other technical means, achieving the technical effects of improving the accuracy of fault location, accelerating the problem-solving process, and optimizing the R & D test efficiency.

[0040] In a possible implementation manner, the method further includes step S400. One end of the device is connected to the serial port of the host CPU through a serial port connection method, and the other end is a liquid crystal display screen. Specifically, use an appropriate serial port cable (such as RS-232, RS-485 cable or USB to serial port cable, etc.) to connect one end of the device to the serial port of the host CPU. When connecting, pay attention to the pin definition of the serial port to ensure correct docking. The other end of the device is directly connected to the liquid crystal display screen, that is, the interface circuit and drive circuit of the liquid crystal display screen are integrated inside the device. When the device is started or reset, an initialization operation is performed on the liquid crystal display screen, including setting the display mode, clearing the screen, setting the cursor position, etc., to prepare for the display operation. The host CPU transmits data such as print logs to the device through the serial port. The serial port log analysis chip inside the device parses and processes the received data, extracts the error information and compares it with the built-in database. The comparison result (i.e., the first error fault type) is displayed on the liquid crystal display screen for the user to view. This implementation method can transmit the print log of the host CPU to the device for analysis in real time through the serial port connection. The user can immediately see the fault analysis result, improving the efficiency of fault troubleshooting. By integrating the serial port log analysis chip and the liquid crystal display screen, the complexity and occupied space of the device are reduced, making the entire system more compact and efficient.

[0041] Based on the foregoing embodiments, the embodiments of the present application further provide an electronic device and a computer-readable storage medium. The computer-readable storage medium stores a computer program. When the computer program is executed by the processor of the electronic device, it can implement the method described in any previous embodiment.

[0042] Figure 3It is a schematic structural diagram of an electronic device provided by an embodiment of the present invention, showing a block diagram of an exemplary electronic device suitable for implementing the embodiments of the present invention. Figure 3 The electronic device shown is merely an example and should not impose any limitation on the functions and scope of use of the embodiments of the present invention. The electronic device is presented in the form of a general-purpose computing device, and its components may include, but are not limited to, an input device 301, a processor 302, a memory 303, and an output device 304. Among them, the processor 302 may be one or more; the memory 303 may include a computer-readable medium and at least one program product, and this program product has a set (at least one) of program modules, and these program modules are configured to execute the functions of the various embodiments of the present application.

[0043] The memory 303 shown in the embodiments of the present invention may adopt any combination of one or more computer-readable media; the computer-readable storage medium may be, but is not limited to, infrared rays, semiconductor systems, devices or components, or any combination of the above, for storing software programs, computer-executable programs, and modules, such as the program instructions / modules corresponding to a method for improving the work efficiency of computer fault analysis in the embodiments of the present invention. The processor 302 executes various functional applications and data processing of the computer device by running the software programs, instructions, and modules stored in the memory 303, that is, implements the above-mentioned method for improving the work efficiency of computer fault analysis.

[0044] The above specific implementation manners do not constitute a limitation on the protection scope of the present application. Those skilled in the art should understand that various modifications, combinations, and substitutions can be made according to design requirements and other factors. Any modifications, equivalent substitutions, and improvements made within the spirit and principles of the present application shall be included within the protection scope of the present application. In some cases, the actions or steps recorded in the present application may be executed in a different order from that in the embodiments and still achieve the desired results. Additionally, the processes depicted in the drawings do not necessarily require the specific order or continuous order shown to achieve the desired results. In certain embodiments, multitasking and parallel processing are also possible or may be advantageous.

Claims

1. A method for improving the efficiency of computer fault analysis, characterized in that: The method comprises: Obtain the print log of the host CPU, output the print log in the form of a string to the device storage Rom of the device through the serial port debugging interface for storage, and obtain the log storage Rom; Calling the serial port log analysis chip of the device to compare the first error information in the log storage Rom with the error information in the built-in database to obtain the first error fault type; The first error fault type is sent to a liquid crystal display screen for display.

2. A method for improving the efficiency of computer fault analysis as claimed in claim 1, characterized in that: include: Extracting a first key character set of the first error message according to a preset key character type set; The first key character set is compared with the key character set of the error information stored in the built-in database to determine whether the comparison is successful, and if so, a first error fault type is obtained.

3. A method for improving the efficiency of computer fault analysis as claimed in claim 2, characterized in that: If the comparison is unsuccessful, the return value is empty.

4. A method for improving the efficiency of computer fault analysis as claimed in claim 1, characterized in that: include: Obtain a set of known error fault types and a set of key characters corresponding to each set of error fault types, and construct a fault code mapping comparison table; The built-in database is constructed based on the fault code mapping comparison table.

5. A method for improving the efficiency of computer fault analysis as claimed in claim 1, characterized in that: The built-in database is used to provide comparison data for the serial port log analysis chip, and update the data at a preset frequency.

6. A method for improving the efficiency of computer fault analysis as claimed in claim 1, characterized in that: The host CPU is FTD2000-8Core.

7. A method for improving the efficiency of computer fault analysis as claimed in claim 1, characterized in that: One end of the device is connected to the serial port of the host CPU through a serial port connection mode, and the other end is a liquid crystal display screen.

8. A method for improving the efficiency of computer fault analysis as claimed in claim 1, characterized in that: The serial port debugging interface is UART debug.

9. An electronic device, characterized in that: The electronic device comprises: A memory for storing executable instructions; A processor, used to implement a method for improving the work efficiency of computer fault analysis as described in any one of claims 1 to 8 when executing executable instructions stored in the memory.

10. A computer-readable storage medium having a computer program stored thereon, characterized in that: When the program is executed by a processor, a method for improving the work efficiency of computer fault analysis as described in any one of claims 1 to 8 is implemented.

Citation Information

Patent Citations

  • Method for automatically diagnosing boot failure of server

    CN104391765A

  • Mainboard fault analysis method and device and medium

    CN111026576A

  • Method, system and equipment for realizing effective positioning of log and storage medium

    CN114675991A

  • Computer mainboard fault diagnosis method, system and device

    CN114741228A

Cited By

  • Feiteng reinforcement computing platform state monitoring and problem positioning method

    CN116257411A