Automatic notification method, system and device for system log collection and medium

Through standardized processing and real-time monitoring of system logs, the problems of inconsistent log formats and low processing efficiency are solved, efficient log management and rapid response are achieved, and the efficiency of system maintenance and security management is improved.

CN118642913APending Publication Date: 2024-09-13HUANENG JIMO WIND POWER CO LTD +1
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202410691676.3
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-05-30
Publication Date
2024-09-13

AI Technical Summary

Technical Problem

Traditional system log management has problems such as inconsistent log formats, insufficient real-time performance, and low data processing efficiency, resulting in low efficiency in troubleshooting, security audits, and performance optimization.

Method used

By standardizing the log format, generating standardized system logs, creating system log link log global traceid, real-time monitoring and storage of abnormal logs, regular notification of abnormal log behaviors, and improving the real-time and efficiency of log management.

Benefits of technology

Significantly improve the real-time, availability and security of log management, shorten the problem processing time, and enhance the support capabilities of system maintenance and security management.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118642913A
    Figure CN118642913A
Patent Text Reader

Abstract

The invention discloses an automatic notification method, system and device for system log collection and a medium. The method comprises the following steps: standardizing a log format; generating a system log according to the standardized log format; judging whether the system log is normal; according to the method, the system, the device and the medium, when the system log is abnormal, the abnormal system log is monitored regularly, when it is monitored that the system log is abnormal regularly, the log notification is issued for the log behavior of the system log, and the method, the system, the device and the medium can achieve log formatting and real-time performance of the system log and high efficiency of data processing.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The invention belongs to the field of information system monitoring and management, and relates to a method, system, equipment and medium for automatic notification of system log collection. Background Art

[0002] With the rapid development of information technology and the continuous deepening of enterprise informatization, various systems and applications have become increasingly complex, and the stability and security of the system are crucial to the daily operation of the enterprise. As an important data source for recording the operating status of the system, the system log plays an indispensable role in troubleshooting, security auditing, performance optimization, etc. However, the traditional log management method has the following problems:

[0003] Inconsistent log formats: Different systems, applications, and even modules generate different log formats, which makes centralized log management and analysis difficult.

[0004] Lack of real-time performance: When an abnormality or security incident occurs, the traditional log system often cannot notify relevant personnel in a timely manner, resulting in delayed problem handling and possibly causing greater losses.

[0005] Low data processing efficiency: Massive log data requires efficient storage and processing methods, but existing solutions are often inefficient when processing large amounts of data and cannot meet the needs of real-time analysis. Summary of the invention

[0006] The purpose of the present invention is to overcome the shortcomings of the above-mentioned prior art and provide a method, system, device and medium for automatic notification of system log collection, which can achieve log formatting, real-time performance and high efficiency of data processing of system logs.

[0007] In order to achieve the above object, the present invention adopts the following technical scheme:

[0008] In one aspect, the present invention provides a method for automatic notification of system log collection, comprising:

[0009] Standardize log formats;

[0010] Generate system logs according to standardized log formats;

[0011] Determine whether the system log is normal;

[0012] When the system log is abnormal, the abnormal system log is monitored regularly. When the system log is abnormal during regular monitoring, a log notification is issued for the log behavior of the system log.

[0013] The present invention provides a further improvement on the automatic notification method for system log collection in that:

[0014] Furthermore, the standardized log format is: author-module-Api interface-method-system exception error information.

[0015] Furthermore, it also includes:

[0016] When the request reaches the service, the service generates a spanId for the request.

[0017] Furthermore, it also includes:

[0018] Create a system log link log global traceid to record the log call process.

[0019] Furthermore, it also includes:

[0020] System log storage for exceptions.

[0021] In a second aspect of the present invention, the present invention provides a system for automatic notification of system log collection, comprising:

[0022] Standardization module, used to standardize the log format;

[0023] A generation module, used to generate system logs according to a standardized log format;

[0024] The judgment module is used to judge whether the system log is normal;

[0025] The notification module is used to regularly monitor the abnormal system log when an abnormality occurs in the system log, and to issue a log notification for the log behavior of the system log when an abnormality is detected in the system log during regular monitoring.

[0026] The present invention provides a further improvement on the automatic notification system for system log collection:

[0027] Furthermore, it also includes:

[0028] Create a module to create a system log link log global traceid and record the log call process.

[0029] Furthermore, it also includes:

[0030] The storage module is used to store abnormal system logs.

[0031] In a third aspect of the present invention, the present invention provides a computer device, including a memory, a processor, and a computer program stored in the memory and executable on the processor, wherein the processor implements the steps of the method for automated notification of system log collection when executing the computer program.

[0032] In a fourth aspect of the present invention, the present invention provides a computer-readable storage medium, wherein the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps of the method for automated notification of system log collection are implemented.

[0033] The present invention has the following beneficial effects:

[0034] The method, system, device and medium for automatic notification of system log collection described in the present invention integrate standardized log format, real-time monitoring of log events, automatic trigger notification and efficient and secure log storage during specific operation, which significantly improves the real-time, availability and security of log management, thereby providing strong support for system maintenance and security management.

[0035] Furthermore, when an abnormality occurs in the system log, the abnormal system log is monitored regularly. When the system log is detected to be abnormal during regular monitoring, a log notification is issued for the log behavior of the system log, that is, the abnormal system log is monitored regularly to improve the targeted nature of the monitoring and reduce the scope of monitoring. BRIEF DESCRIPTION OF THE DRAWINGS

[0036] The accompanying drawings constituting a part of the present invention are used to provide a further understanding of the present invention. The exemplary embodiments of the present invention and their descriptions are used to explain the present invention and do not constitute an improper limitation of the present invention. In the accompanying drawings:

[0037] Figure 1 The present invention is a flow chart of the method. DETAILED DESCRIPTION

[0038] In order to enable those skilled in the art to better understand the scheme of the present invention, the technical scheme in the embodiment of the present invention will be clearly and completely described below in conjunction with the drawings in the embodiment of the present invention. Obviously, the described embodiment is only an embodiment of a part of the present invention, not all embodiments, and is not intended to limit the scope of the present invention. In addition, in the following description, the description of well-known structures and technologies is omitted to avoid unnecessary confusion of the concepts disclosed in the present invention. Based on the embodiments in the present invention, all other embodiments obtained by ordinary technicians in this field without making creative work should fall within the scope of protection of the present invention.

[0039] The accompanying drawings show schematic diagrams of structures according to embodiments disclosed in the present invention. These figures are not drawn to scale, and some details are magnified and some details may be omitted for the purpose of clear expression. The shapes of various regions and layers shown in the figures and the relative sizes and positional relationships therebetween are only exemplary, and may deviate in practice due to manufacturing tolerances or technical limitations, and those skilled in the art may additionally design regions / layers with different shapes, sizes, and relative positions according to actual needs.

[0040] It should be noted that the terms "first", "second", etc. in the specification and claims of the present invention and the above-mentioned drawings are used to distinguish similar objects, and are not necessarily used to describe a specific order or sequence. It should be understood that the data used in this way can be interchanged where appropriate, so that the embodiments of the present invention described herein can be implemented in an order other than those illustrated or described herein. In addition, the terms "including" and "having" and any variations thereof are intended to cover non-exclusive inclusions, for example, a process, method, system, product or device that includes a series of steps or units is not necessarily limited to those steps or units that are clearly listed, but may include other steps or units that are not clearly listed or inherent to these processes, methods, products or devices.

[0041] As is known to all, system logs record information about hardware, software, and system problems in the system, and can also monitor events that occur in the system. Users can use them to check the cause of an error or find traces left by an attacker when attacked. System logs include system logs, application logs, and security logs.

[0042] Embodiment 1

[0043] In order to solve the problems of inconsistent log formats, poor real-time performance and low data processing efficiency in the prior art, this embodiment discloses a method for automatic notification of system log collection, which includes the following steps:

[0044] 1) Standardize the log format, where the standardized log format is author-module-Api interface-method-system exception error information;

[0045] It should be noted that the present invention improves the processing speed of system logs by uniformly formatting the logs, thereby improving the efficiency of system operation.

[0046] 2) Create a global traceid for the system log link log to record the log call process;

[0047] 3) When the request reaches each service, the service will generate a spanId for the request;

[0048] 4) generating a system log according to the standardized log format;

[0049] 5) Determine whether the system log is normal. If the system log is abnormal, store the abnormal system log and record it in the system abnormality information library;

[0050] 6) Regularly monitor abnormal system logs. When the system logs are abnormal, log notifications are distributed according to the log behavior, that is, abnormal system logs are monitored regularly, which is more targeted.

[0051] It should be noted that the present invention improves the efficiency and response speed of system operation by standardizing and automating the processing of system logs. In addition, real-time monitoring of key log events and automatic triggering of notifications greatly shortens the time from problem discovery to processing, and improves the efficiency of exception handling. The unified log format simplifies the analysis of log data across systems and applications, and reduces management complexity. At the same time, the present invention enhances the security and confidentiality of log data and reduces the risk of data leakage through efficient storage strategies. In addition, optimized resource utilization and support for decision-making bring cost-effectiveness to organizations, while improving user experience and service stability, helping to enhance customer satisfaction and the market competitiveness of enterprises. Finally, the present invention is easy to integrate and expand, supporting organizations to adjust log management strategies as their business develops while meeting regulatory compliance requirements.

[0052] Embodiment 2

[0053] Accordingly, this embodiment discloses a system for automatically notifying system log collection, and the system for automatically notifying system log collection includes:

[0054] Standardization module, used to standardize the log format;

[0055] A generation module, used to generate system logs according to a standardized log format;

[0056] The judgment module is used to judge whether the system log is normal;

[0057] The notification module is used to regularly monitor the abnormal system log when an abnormality occurs in the system log, and to issue a log notification for the log behavior of the system log when an abnormality is detected in the system log during regular monitoring.

[0058] As an embodiment of the present invention, it also includes:

[0059] Create a module to create a system log link log global traceid and record the log call process.

[0060] The storage module is used to store abnormal system logs.

[0061] The present invention can realize the automated process of efficient collection, standardized processing, real-time monitoring and abnormal notification of system logs, can improve the reliability and efficiency of log management, and can realize instant communication and response from the application layer to the system layer by combining the event-driven mechanism. Through the standardized log processing process, the parsing difficulties caused by the inconsistency of log format and processing logic of different system components or services are reduced, the readability and analyzability of log information are improved, the timeliness and consistency of log data are ensured, and the rapid positioning and response capabilities to abnormal events are strengthened.

[0062] The division of modules in the embodiments of the present application is schematic and is only a logical function division. There may be other division methods in actual implementation. In addition, each functional module in each embodiment of the present application may be integrated into a processor, or may exist physically separately, or two or more modules may be integrated into one module. The above-mentioned integrated modules may be implemented in the form of hardware or in the form of software functional modules.

[0063] Embodiment 3

[0064] A computer device comprises a memory, a processor and a computer program stored in the memory and executable on the processor, wherein when the processor executes the computer program, the steps of the method for automating notification of system log collection are implemented, for example, comprising: standardizing the log format, wherein the standardized log format is author-module-Api interface-method-system abnormal error information; creating a global traceid of a system log link log to record the log call process; when a request reaches each service, the service generates a spanId for the request; generating a system log according to the standardized log format; determining whether the system log is normal, and when the system log is abnormal, storing the abnormal system log and recording it in a system abnormal information library; regularly monitoring the abnormal system log, and when the system log is abnormal, distributing log notifications according to the log behavior.

[0065] Alternatively, the processor implements the functions of each module in the above system when executing the computer program, for example: a standardization module for standardizing the log format; a generation module for generating a system log according to a standardized log format; a judgment module for judging whether the system log is normal; a notification module for regularly monitoring the abnormal system log when an abnormality occurs in the system log, and when the system log is regularly monitored to be abnormal, a log notification is issued for the log behavior of the system log; as an embodiment of the present invention, it also includes: a creation module for creating a system log link log global traceid and recording the log call process; a storage module for storing abnormal system logs. In addition, the computer device can be a computing device such as a desktop computer, a notebook, a handheld computer, and a cloud server. The computer device may include, but is not limited to, a processor and a memory. Those skilled in the art will understand that the above is an example of a computer device and does not constitute a limitation on the computer device. It may include more components than the above, or combine certain components, or different components. For example, the computer device may also include input and output devices, network access devices, buses, etc. The memory may mainly include a program storage area and a data storage area, wherein the program storage area may store an operating system, an application required for at least one function (such as a sound playback function, an image playback function, etc.), etc.; the data storage area may store data created according to the use of the mobile phone (such as audio data, a phone book, etc.), etc. In addition, the memory may include a high-speed random access memory, and may also include a non-volatile memory, such as a hard disk, a memory, a plug-in hard disk, a smart memory card (SmartMediaCard, SMC), a secure digital (SecureDigital, SD) card, a flash card (FlashCard), at least one disk storage device, a flash memory device, or other volatile solid-state storage devices. The memory may be used to store the computer program and / or module, and the processor implements various functions of the computer device by running or executing the computer program and / or module stored in the memory, and calling the data stored in the memory.

[0066] The processor may be a central processing unit (CPU), other general-purpose processors, digital signal processors (DSP), application-specific integrated circuits (ASIC), field-programmable gate arrays (FPGA) or other programmable logic devices, discrete gate or transistor logic devices, discrete hardware components, etc. A general-purpose processor may be a microprocessor or any conventional processor, etc. The processor is the control center of the computer device, and uses various interfaces and lines to connect various parts of the entire computer.

[0067] Embodiment 4

[0068] A computer-readable storage medium stores a computer program, and when the computer program is executed by a processor, the steps of the method for automatic notification of system log collection are implemented, for example, the log format is standardized, wherein the standardized log format is author-module-Api interface-method-system abnormal error information; a system log link log global traceid is created to record the log call process; when the request reaches each service, the service will generate a spanId for the request; a system log is generated according to the standardized log format; it is determined whether the system log is normal, and when the system log is abnormal, the abnormal system log is stored and recorded in the system abnormal information library; the abnormal system log is monitored regularly, and when the system log is abnormal, the log notification is distributed according to the log behavior. Specifically, the computer-readable storage medium includes, but is not limited to, for example, volatile memory and / or non-volatile memory. The volatile memory may include random access memory (RAM) and / or cache memory (cache), etc. The non-volatile memory may include read-only memory (ROM), hard disk, flash memory, optical disk, disk, etc.

[0069] Those skilled in the art will appreciate that the embodiments of the present application may be provided as methods, systems, or computer program products. Therefore, the present application may adopt the form of a complete hardware embodiment, a complete software embodiment, or an embodiment in combination with software and hardware. Moreover, the present application may adopt the form of a computer program product implemented in one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) that include computer-usable program code.

[0070] Based on this understanding, the present invention implements all or part of the processes in the above-mentioned method for automatic notification of system log collection, and can also be completed by instructing related hardware through a computer program, and the computer program can be stored in a computer-readable storage medium, and when the computer program is executed by a processor, the steps of the above-mentioned method for automatic notification of system log collection can be implemented. Among them, the computer program includes computer program code, and the computer program code can be in source code form, object code form, executable file or preset intermediate form, etc.

[0071] It should be noted that the content contained in the computer-readable storage medium can be appropriately increased or decreased according to the requirements of legislation and patent practice in the jurisdiction. For example, in some jurisdictions, according to legislation and patent practice, computer-readable storage media do not include electrical carrier signals and telecommunication signals.

[0072] The present application is described with reference to the flowcharts and / or block diagrams of the methods, devices (systems), and computer program products according to the embodiments of the present application. It should be understood that each process and / or box in the flowchart and / or block diagram, as well as the combination of the processes and / or boxes in the flowchart and / or block diagram, can be implemented by computer program instructions. These computer program instructions can be provided to a processor of a general-purpose computer, a special-purpose computer, an embedded processor, or other programmable data processing device to generate a machine, so that the instructions executed by the processor of the computer or other programmable data processing device generate instructions for implementing the processes in the flowchart and / or block diagram. Figure 1 A process or multiple processes and / or boxes Figure 1 A device that provides the functions specified in a block or multiple blocks.

[0073] These computer program instructions can also be loaded onto a computer or other programmable data processing device so that a series of operating steps are executed on the computer or other programmable device to produce a computer-implemented process, thereby providing instructions for implementing the process. Figure 1 A process or multiple processes and / or boxes Figure 1 The steps for the functions specified in one or more boxes.

[0074] Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention rather than to limit it. Although the present invention has been described in detail with reference to the above embodiments, ordinary technicians in the relevant field should understand that the specific implementation methods of the present invention can still be modified or replaced by equivalents. Any modification or equivalent replacement that does not depart from the spirit and scope of the present invention should be covered within the scope of protection of the claims of the present invention.

Claims

1. A method for automatic notification of system log collection, characterized in that: include: Standardize log formats; Generate system logs according to standardized log formats; Determine whether the system log is normal; When the system log is abnormal, the abnormal system log is monitored regularly. When the system log is abnormal during regular monitoring, a log notification is issued for the log behavior of the system log.

2. The method for automatic notification of system log collection according to claim 1, characterized in that: The standardized log format is: author-module-Api interface-method-system exception error information.

3. The method for automatic notification of system log collection according to claim 1, characterized in that: Also includes: When the request reaches the service, the service generates a spanId for the request.

4. The method for automatic notification of system log collection according to claim 1, characterized in that: Also includes: Create a system log link log global traceid to record the log call process.

5. The method for automatic notification of system log collection according to claim 1, characterized in that: Also includes: System log storage for exceptions.

6. A system for automatic notification of system log collection, characterized in that: include: Standardization module, used to standardize the log format; A generation module, used to generate system logs according to a standardized log format; The judgment module is used to judge whether the system log is normal; The notification module is used to regularly monitor the abnormal system log when an abnormality occurs in the system log, and to issue a log notification for the log behavior of the system log when an abnormality is detected in the system log during regular monitoring.

7. The system for automatic notification of system log collection according to claim 6, characterized in that: Also includes: Create a module to create a system log link log global traceid and record the log call process.

8. The system for automatic notification of system log collection according to claim 6, characterized in that: Also includes: The storage module is used to store abnormal system logs.

9. A computer device comprising a memory, a processor, and a computer program stored in the memory and executable on the processor, characterized in that: When the processor executes the computer program, the steps of the method for automatic notification of system log collection described in any one of claims 1 to 5 are implemented.

10. A computer-readable storage medium storing a computer program, characterized in that: When the computer program is executed by a processor, the steps of the method for automatic notification of system log collection described in any one of claims 1 to 5 are implemented.