Network alarm method, device, system and computer readable storage medium

By collecting and extracting network device logs, obtaining alarm content and auxiliary information, and encapsulating them into alarm information, it solves the problem of untimely response caused by differences in network device fault processing methods, realizes intelligent transmission and rapid processing of alarm information, and improves troubleshooting Barrier efficiency.

CN111030857BActive Publication Date: 2024-11-01WEBANK (CHINA)
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN201911242825.3
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2019-12-06
Publication Date
2024-11-01
Estimated Expiration
2039-12-06

AI Technical Summary

Technical Problem

The existing technology has a large difference in handling methods when network equipment failures, resulting in untimely response to batch alarms and missing important information. How to improve the intelligence of alarms to quickly troubleshoot problems is an urgent problem.

Method used

Collect network equipment logs, extract alarm logs based on preset rules, obtain alarm content and auxiliary information, encapsulate them into alarm information and send them to the operation and maintenance terminal, including obtaining alarm fields, business threads and target rules, detecting whether the fault is solved, and marking it has been resolved , and determine the processing strategy.

Benefits of technology

Through rich alarm information, the intelligence of alarms is improved, and the operation and maintenance personnel can quickly troubleshoot, reduce processing time, avoid repeated alarms, and ensure the complete transmission and rapid processing of fault information.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN111030857B_ABST
    Figure CN111030857B_ABST
Patent Text Reader

Abstract

The present invention discloses a network alarm method, including: collecting logs generated by network devices, and extracting alarm logs from the logs based on preset rules; determining the alarm content of the alarm logs, and obtaining auxiliary information corresponding to the alarm content; encapsulating the alarm content and the auxiliary information into alarm information, and sending the alarm information to an operation and maintenance terminal. The present invention also discloses a network alarm device, equipment, and computer-readable storage medium. The present invention collects logs of network devices, extracts fault logs therefrom, and then searches for auxiliary information of the fault logs to generate alarm information with richer content than traditional fault logs, and finally sends the alarm information to the operation and maintenance terminal, so that the operation and maintenance personnel of the operation and maintenance terminal can obtain more comprehensive fault information, improve the intelligence of the alarm, and achieve rapid troubleshooting.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of financial technology (Fintech), and in particular to a network alarm method, device, system and computer-readable storage medium. Background Art

[0002] With the development of computer technology, more and more technologies are being applied in the financial field. The traditional financial industry is gradually transforming to financial technology (Fintech), and network operation and maintenance technology is no exception. However, due to the security and real-time requirements of the financial industry, higher requirements are also placed on network operation and maintenance technology.

[0003] Network alarm is an important aspect of network operation and maintenance. Unlike network log analysis, it attaches great importance to real-time performance. If each query takes too long to process, it will cause a crisis caused by insufficient real-time performance. Real-time performance is not only reflected in the time of "alarm", but also in how to effectively transmit information after "alarm". Whether the transmitted network alarm information is clear and complete plays a very important role in fault handling, especially in the financial industry, which requires faults to be recovered quickly.

[0004] In the prior art, when a network device fails, the logs of the network device are generally collected according to the syslog protocol, and then the alarm processing engine sends the logs to a special alarm platform in the form of http. The alarm platform prompts the relevant operation and maintenance personnel to troubleshoot. That is, the current operation and maintenance of network equipment generally relies on on-site operation and maintenance personnel to handle or transmit alarm information. It is necessary to monitor the alarm platform 24 hours a day to confirm the alarm, and when an alarm occurs, it is necessary to continuously query the required information between various systems, and the processing time is slow. This is because banks and other financial institutions usually purchase equipment of different manufacturers and models for security reasons. When different equipment alarms, the processing methods are quite different. Therefore, even if there is a problem with the infrastructure, professional operation and maintenance personnel often have to consult relevant documents to troubleshoot the problem.

[0005] In this case, if batch alarms occur, it is likely that the response will not be timely, thus missing some important alarm information. Therefore, how to improve the intelligence of alarms so that relevant personnel can quickly troubleshoot is an urgent problem to be solved. Summary of the invention

[0006] The main purpose of the present invention is to provide a network alarm method, device, system and computer-readable storage medium, aiming to improve the intelligence of alarms and achieve rapid troubleshooting.

[0007] To achieve the above object, the present invention provides a network alarm method, which comprises the following steps:

[0008] Collect logs generated by network devices and extract alarm logs from the logs based on preset rules;

[0009] Determine the alarm content of the alarm log, and obtain auxiliary information corresponding to the alarm content;

[0010] The alarm content and the auxiliary information are encapsulated into alarm information, and the alarm information is sent to an operation and maintenance terminal.

[0011] Preferably, the alarm content includes an alarm field, and the step of determining the alarm content of the alarm log and acquiring auxiliary information corresponding to the alarm content includes:

[0012] Acquire an alarm field of the network device, where the alarm field is used to characterize a device attribute of the network device;

[0013] Based on the alarm field, the service thread of the alarm log is determined, and auxiliary information corresponding to the service thread is obtained.

[0014] Preferably, the step of determining the service thread of the alarm log based on the alarm field and obtaining auxiliary information corresponding to the service thread includes:

[0015] Based on the alarm field, determine the service thread of the alarm log, and determine whether the alarm log is consistent with the cache log corresponding to the service thread;

[0016] If not, obtain the auxiliary information corresponding to the service thread.

[0017] Preferably, the alarm content includes an alarm subject, and the step of determining whether the alarm log is consistent with the cache log corresponding to the service thread includes:

[0018] Determine a target rule corresponding to the alarm log, and based on the target rule, determine an alarm topic of the alarm log;

[0019] Determine a cache topic of the cache log corresponding to the service thread, and match the alarm topic with the cache topic;

[0020] If the match is successful, it is determined that the alarm log is consistent with the cache log corresponding to the business thread.

[0021] Preferably, after the step of encapsulating the alarm content and the auxiliary information into alarm information and sending the alarm information to the operation and maintenance terminal, the network alarm method further comprises:

[0022] Determine an inspection instruction for the alarm information, and based on the inspection instruction, detect whether the fault corresponding to the alarm information has been resolved;

[0023] If resolved, the alarm information is marked as resolved.

[0024] Preferably, the step of determining the inspection instruction of the alarm information and detecting whether the fault corresponding to the alarm information has been resolved based on the inspection instruction includes:

[0025] Determine an inspection instruction for the alarm information, and send the inspection instruction to the network device;

[0026] receiving an echo instruction returned by the network device based on the inspection instruction, and determining whether the fault has been resolved based on the echo instruction;

[0027] If the status of the echo instruction is a specified status, it is determined that the fault has been resolved.

[0028] Preferably, the step of encapsulating the alarm content and the auxiliary information into alarm information and sending the alarm information to the operation and maintenance terminal includes:

[0029] Encapsulating the alarm content and the auxiliary information into alarm information, and determining a processing strategy corresponding to the alarm information;

[0030] The alarm information and the processing strategy are sent to the operation and maintenance terminal.

[0031] In addition, to achieve the above-mentioned purpose, the present invention also provides a network alarm device, the network alarm device comprising:

[0032] A collection module, used to collect logs generated by network devices and extract alarm logs from the logs based on preset rules;

[0033] An acquisition module, used to determine the alarm content of the alarm log and obtain auxiliary information corresponding to the alarm content;

[0034] The sending module is used to encapsulate the alarm content and the auxiliary information into alarm information, and send the alarm information to the operation and maintenance terminal.

[0035] Preferably, the alarm content includes an alarm field, and the acquisition module is further used for:

[0036] Acquire an alarm field of the network device, where the alarm field is used to characterize a device attribute of the network device;

[0037] Based on the alarm field, the service thread of the alarm log is determined, and auxiliary information corresponding to the service thread is obtained.

[0038] Preferably, the acquisition module is also used for:

[0039] Based on the alarm field, determine the service thread of the alarm log, and determine whether the alarm log is consistent with the cache log corresponding to the service thread;

[0040] If not, obtain the auxiliary information corresponding to the service thread.

[0041] Preferably, the alarm content includes an alarm subject, and the acquisition module is further used for:

[0042] Determine a target rule corresponding to the alarm log, and based on the target rule, determine an alarm topic of the alarm log;

[0043] Determine a cache topic of the cache log corresponding to the service thread, and match the alarm topic with the cache topic;

[0044] If the match is successful, it is determined that the alarm log is consistent with the cache log corresponding to the business thread.

[0045] Preferably, the network alarm device further includes a detection module, and the detection module is used to:

[0046] Determine an inspection instruction for the alarm information, and based on the inspection instruction, detect whether the fault corresponding to the alarm information has been resolved;

[0047] If resolved, the alarm information is marked as resolved.

[0048] Preferably, the detection module is also used for:

[0049] Determine an inspection instruction for the alarm information, and send the inspection instruction to the network device;

[0050] receiving an echo instruction returned by the network device based on the inspection instruction, and determining whether the fault has been resolved based on the echo instruction;

[0051] If the status of the echo instruction is a specified status, it is determined that the fault has been resolved.

[0052] Preferably, the sending module is also used for:

[0053] Encapsulating the alarm content and the auxiliary information into alarm information, and determining a processing strategy corresponding to the alarm information;

[0054] The alarm information and the processing strategy are sent to the operation and maintenance terminal.

[0055] In addition, to achieve the above-mentioned purpose, the present invention also provides a network alarm system, which includes: a memory, a processor, and a network alarm program stored on the memory and executable on the processor, and the network alarm program implements the steps of the network alarm method described above when executed by the processor.

[0056] In addition, to achieve the above-mentioned purpose, the present invention also provides a computer-readable storage medium, on which a network alarm program is stored, and when the network alarm program is executed by a processor, the steps of the network alarm method described above are implemented.

[0057] The network alarm method proposed in the present invention collects logs generated by network devices and extracts alarm logs from the logs; determines the alarm content of the alarm logs and obtains auxiliary information corresponding to the alarm content; encapsulates the alarm content and the auxiliary information into alarm information, and sends the alarm information to the operation and maintenance terminal. The present invention collects logs of network devices, extracts fault logs from them according to preset rules, searches for auxiliary information of the fault logs, and finally encapsulates the fault logs and auxiliary information extracted according to preset rules into alarm information, so that the generated alarm information has richer content than traditional fault logs. Finally, the alarm information is sent to the operation and maintenance terminal, so that the operation and maintenance personnel of the operation and maintenance terminal can obtain more comprehensive fault information, improve the intelligence of the alarm, and help the operation and maintenance personnel to quickly troubleshoot. BRIEF DESCRIPTION OF THE DRAWINGS

[0058] Figure 1 It is a schematic diagram of the system structure of the hardware operating environment involved in the embodiment of the present invention;

[0059] Figure 2 A schematic diagram of a flow chart of a first embodiment of a network alarm method according to the present invention;

[0060] Figure 3 This is a detailed flowchart of step S20 in the first embodiment of the network alarm method of the present invention.

[0061] The realization of the purpose, functional features and advantages of the present invention will be further explained in conjunction with embodiments and with reference to the accompanying drawings. DETAILED DESCRIPTION

[0062] It should be understood that the specific embodiments described herein are only used to explain the present invention, and are not used to limit the present invention.

[0063] like Figure 1 As shown, Figure 1 It is a schematic diagram of the system structure of the hardware operating environment involved in the embodiment of the present invention.

[0064] The system of the embodiment of the present invention may be a PC or a server device.

[0065] like Figure 1 As shown, the system may include: a processor 1001, such as a CPU, a network interface 1004, a user interface 1003, a memory 1005, and a communication bus 1002. Among them, the communication bus 1002 is used to realize the connection and communication between these components. The user interface 1003 may include a display screen (Display), an input unit such as a keyboard (Keyboard), and the optional user interface 1003 may also include a standard wired interface and a wireless interface. The network interface 1004 may optionally include a standard wired interface and a wireless interface (such as a WI-FI interface). The memory 1005 may be a high-speed RAM memory, or a stable memory (non-volatile memory), such as a disk memory. The memory 1005 may also be a storage device independent of the aforementioned processor 1001.

[0066] Those skilled in the art will understand that Figure 1 The system structure shown in the figure does not constitute a limitation on the network alarm system, and may include more or less components than those shown in the figure, or a combination of certain components, or a different arrangement of components.

[0067] like Figure 1 As shown, the memory 1005 as a computer storage medium may include an operating system, a network communication module, a user interface module, and a network alarm program.

[0068] Among them, the operating system is a program for managing and controlling the network alarm system and software resources, supporting the operation of the network communication module, user interface module, network alarm program and other programs or software; the network communication module is used to manage and control the network interface 1002; the user interface module is used to manage and control the user interface 1003.

[0069] exist Figure 1 In the network alarm system shown, the network alarm system calls the network alarm program stored in the memory 1005 through the processor 1001, and executes the operations in each embodiment of the following network alarm method.

[0070] Based on the above hardware structure, an embodiment of the network alarm method of the present invention is proposed.

[0071] Reference Figure 2 , Figure 2 This is a flow chart of a first embodiment of a network alarm method according to the present invention, wherein the method comprises:

[0072] Step S10, collecting logs generated by network devices, and extracting alarm logs from the logs based on preset rules;

[0073] Step S20, determining the alarm content of the alarm log, and obtaining auxiliary information corresponding to the alarm content;

[0074] Step S30: encapsulate the alarm content and the auxiliary information into alarm information, and send the alarm information to the operation and maintenance terminal.

[0075] The network alarm method of this embodiment is applied to the network alarm system of financial institutions such as financial institutions or banks. For the convenience of description, the network alarm system is described as an alarm system. The alarm system includes a log collector, an alarm processing engine and a network management system, wherein the log collector monitors network devices in real time, collects and forwards logs generated by network devices to the alarm processing engine. In specific implementation, the log collector can be a distributed architecture. This is because financial institutions such as banks have several IDCs (Internet Data Centers). Therefore, each IDC is assigned a log collector, and the log collector sends the collected logs to the alarm processing engine in HTTP mode; and the alarm processing engine can filter out some useless logs to reduce the pressure of the network management system. Specifically, the logs sent by the log collector can be extracted in a targeted manner using alarm keywords or regular expressions. The specific filtering method is described in detail in the following embodiments; after filtering, an alarm log is obtained, and the alarm log will flow through the network management system. The network management system obtains corresponding auxiliary information by determining the alarm content of the alarm log, and encapsulates the alarm content and the auxiliary information into alarm information to enrich the alarm log. Finally, the alarm information is sent to the operation and maintenance terminal, so that the alarm information obtained by the operation and maintenance terminal is more detailed, which can help the operation and maintenance personnel to quickly troubleshoot.

[0076] The following is a detailed description of each step:

[0077] Step S10, collecting logs generated by network devices, and extracting alarm logs from the logs based on preset rules.

[0078] In this embodiment, the alarm system collects logs generated by network devices through a log collector, and sends the logs to an alarm processing engine through the log collector, and the alarm processing engine extracts alarm logs from the logs based on preset rules. It can be understood that not all logs generated by network devices are alarm logs. Therefore, it is necessary to extract alarm logs from a large number of logs, wherein the preset rules may be preset alarm keywords, specifically: compare each log with a preset alarm keyword, that is, define the alarm keyword in advance, and then compare each log with the alarm keyword. If there is a hit, it is determined that the current log that hits the preset alarm keyword is an alarm log, thereby extracting the alarm log from the large number of logs; in addition, in another embodiment, the preset rules may also be preset regular expressions, specifically: match each log with a regular expression, that is, write several regular expressions in advance, and then match each log with the regular expression. If the current regular expression returns a correct result, it is determined that the log matching the current regular expression is an alarm log, thereby extracting the alarm keyword from the large number of logs.

[0079] Step S20, determining the alarm content of the alarm log, and obtaining auxiliary information corresponding to the alarm content.

[0080] In this embodiment, after the alarm system obtains the alarm log through the alarm processing engine, the alarm content of the alarm log is determined through the network management system, wherein the alarm content includes the alarm subject and the alarm field.

[0081] Specifically, refer to Figure 3 , step S20 comprises:

[0082] Step S21, obtaining an alarm field of the network device, wherein the alarm field is used to characterize a device attribute of the network device;

[0083] In this step, the alarm system obtains the alarm field of the network device through the network management system, wherein the alarm field is used to characterize the device attributes of the network device, specifically, the alarm field includes the device management IP, port, protocol, etc.

[0084] Further, in another embodiment, step S21 includes:

[0085] Determine a first alarm template corresponding to the alarm log, and obtain an alarm field of the network device based on the first alarm template.

[0086] In this step, the alarm system can determine the corresponding first alarm template according to the alarm subject of the alarm log, and then obtain the corresponding alarm field according to the first alarm template, wherein the determination of the alarm subject is described in detail in the following embodiment, and the first alarm template includes alarm parameters, that is, each alarm subject has a corresponding first alarm template. It can be understood that when the operation and maintenance personnel face alarm logs with different alarm subjects and analyze the current alarm log, the alarm parameters they rely on are different. For example, if the first alarm template corresponding to the current alarm log includes alarm parameter A, then the alarm field must include A; if the first alarm template corresponding to the current alarm log includes alarm parameter B, then the alarm field must include B, etc. Therefore, the alarm system needs to obtain corresponding alarm fields for different first alarm templates so that the operation and maintenance personnel can understand more comprehensive alarm information.

[0087] Step S22: determining the service thread of the alarm log based on the alarm field, and obtaining auxiliary information corresponding to the service thread.

[0088] In this step, the network management system of the alarm system determines the business thread of the alarm log according to the alarm field. Specifically, based on the alarm field, the corresponding business thread is searched in the business system connected to the alarm system through the network management system. In specific implementation, the business thread associated with the port in the alarm field can be determined, thereby obtaining auxiliary information corresponding to the business thread, wherein the auxiliary information includes business information, which is used to characterize which specific business has failed.

[0089] Step S30: encapsulate the alarm content and the auxiliary information into alarm information, and send the alarm information to the operation and maintenance terminal.

[0090] In this embodiment, the network management system of the alarm system encapsulates the alarm content and auxiliary information into alarm information, specifically into json format. As shown in the example above, the alarm information encapsulated into:

[0091] {

[0092] title: "Port jitter",

[0093] manage_ip: "2.2.2.2",

[0094] port:”xxx”

[0095] status:"down",

[0096] business: "xxx business",

[0097] reason: "Parent interface is down"

[0098] }

[0099] Finally, the alarm information is sent to the operation and maintenance terminal for the operation and maintenance personnel at the operation and maintenance terminal to view.

[0100] Further, in another embodiment, step S30 includes:

[0101] Encapsulating the alarm content and the auxiliary information into alarm information, and determining a processing strategy corresponding to the alarm information;

[0102] In this step, after the network management system of the alarm system encapsulates the alarm content and auxiliary information into alarm information, it determines the processing strategy corresponding to the alarm information through a pre-set processing strategy. During the specific implementation, the corresponding processing strategy is determined based on the alarm subject and business information. The processing strategy can be a standard process document that is pre-defined to process the fault log.

[0103] The alarm information and the processing strategy are sent to the operation and maintenance terminal.

[0104] Finally, the packaged alarm information and processing strategy are sent to the operation and maintenance terminal. It can be understood that the alarm information at this time is not just log information, but also includes auxiliary information such as business information, as well as corresponding processing strategies. The operation and maintenance personnel can judge the importance of the alarm log and the alarm device, port and other information from the alarm information, which can help the operation and maintenance personnel to quickly troubleshoot.

[0105] Further, in another embodiment, step S30 includes:

[0106] Encapsulating the alarm content and the auxiliary information into alarm information, and determining a second alarm template corresponding to the alarm information;

[0107] Based on the second alarm template, the alarm information is sent to the operation and maintenance terminal.

[0108] That is, the network management system of the alarm system is pre-set with second alarm templates corresponding to different alarm information, and the corresponding second alarm template can be determined according to the business thread to which the alarm information belongs, wherein the second alarm template is used to characterize the importance ranking of the parameters in the alarm information. It is understandable that the parameters in the alarm information have different importance, some are important to the operation and maintenance personnel, and some are not so important, such as the management IP of the network equipment. When the operation and maintenance personnel solve the fault, the management IP is not so important, so the non-important parameters such as the management IP should be placed at the bottom of the alarm information, or not displayed, to avoid too much alarm information, which causes the operation and maintenance personnel to spend more time to determine the key points.

[0109] Therefore, after the alarm content and auxiliary information are encapsulated into alarm information, the network management system of the alarm system determines the second alarm template corresponding to the alarm information based on the business thread corresponding to the alarm information, and arranges and displays the alarm information in the format of the second alarm template, and sends it to the operation and maintenance terminal so that the operation and maintenance personnel can quickly read the fault details and achieve rapid troubleshooting.

[0110] Further, in another embodiment, step S30 includes:

[0111] Encapsulating the alarm content and the auxiliary information into alarm information to be processed, and determining operation and maintenance personnel information corresponding to the alarm information to be processed;

[0112] Based on the operation and maintenance personnel information, important parameters in the alarm information to be processed are determined, and the important parameters are encapsulated into alarm information, and the alarm information is sent to the operation and maintenance terminal corresponding to the operation and maintenance personnel information.

[0113] That is, in another embodiment, since each operation and maintenance personnel needs to maintain or process different key information, in order to meet the accurate needs of each operation and maintenance personnel so that the operation and maintenance personnel can quickly obtain the alarm parameters they want, the alarm system encapsulates the alarm content and auxiliary information into alarm information to be processed, and determines the operation and maintenance personnel information corresponding to the alarm information to be processed. It can be specifically determined by the business thread to which the alarm information to be processed belongs; or, it can be determined according to the network device to which the alarm information to be processed belongs. That is, in the specific implementation, different business threads or different network devices are maintained by different operation and maintenance personnel. Therefore, the corresponding operation and maintenance personnel information can be determined according to the business thread to which the alarm information to be processed belongs, or the network device.

[0114] Then, according to the personalized requirements of different operation and maintenance personnel set in advance, the corresponding important parameters are determined from the alarm information to be processed. For example, the personalized requirement of operation and maintenance personnel A is that the alarm information must have a protocol, and the IP must not be managed. Then, if the important parameter of the current alarm information to be processed is determined to be the protocol, it is only necessary to encapsulate the protocol into the alarm information, and the management IP can be directly discarded. Finally, the alarm information is sent to the operation and maintenance terminal corresponding to the operation and maintenance personnel information, which improves the accuracy of the alarm information output.

[0115] This embodiment collects logs generated by network devices and extracts alarm logs from the logs; determines the alarm content of the alarm logs and obtains auxiliary information corresponding to the alarm content; encapsulates the alarm content and the auxiliary information into alarm information, and sends the alarm information to the operation and maintenance terminal. The present invention collects logs of network devices, extracts fault logs from them according to preset rules, searches for auxiliary information of the fault logs, and finally encapsulates the fault logs and auxiliary information extracted according to preset rules into alarm information, so that the generated alarm information has richer content than traditional fault logs. Finally, the alarm information is sent to the operation and maintenance terminal, so that the operation and maintenance personnel of the operation and maintenance terminal can obtain more comprehensive fault information, improve the intelligence of the alarm, and help the operation and maintenance personnel to quickly troubleshoot.

[0116] Furthermore, based on the first embodiment of the network alarm method of the present invention, a second embodiment of the network alarm method of the present invention is proposed.

[0117] The difference between the second embodiment of the network alarm method and the first embodiment of the network alarm method is that step S23 includes:

[0118] Step a, based on the alarm field, determining the service thread of the alarm log, and determining whether the alarm log is consistent with the cache log corresponding to the service thread;

[0119] Step b: if not, obtain the auxiliary information corresponding to the business thread.

[0120] In this embodiment, the links in the network will pass through multiple nodes, which makes the nodes of the same link affect each other. For example, jitter in one place may cause jitter in other related places, affecting the visual experience of the operation and maintenance personnel. That is, faults in different nodes of the same business thread will all give alarms, but they are essentially the same alarm problem. To avoid repeated alarms for the same faults in different nodes of the same business thread, this embodiment stores the collected alarm information in a cache. Specifically, redis (an open source log-type, Key-Value database written in ANSI C language, supporting the network, memory-based and persistent, and providing APIs in multiple languages) can be used. When other alarm logs match the currently cached alarm information, the alarm will no longer be repeated, that is, the alarm convergence is achieved.

[0121] The following is a detailed description of each step:

[0122] Step a: determining the service thread of the alarm log based on the alarm field, and determining whether the alarm log is consistent with the cache log corresponding to the service thread.

[0123] In this embodiment, the network management system of the alarm system determines the business thread corresponding to the current alarm log based on the alarm field, and then determines whether the current alarm log is consistent with the cache log corresponding to the current business thread, that is, determines whether the current alarm log is a duplicate alarm of the current business thread. In the specific implementation, the corresponding business thread is determined by the port in the alarm field.

[0124] Specifically, step a includes:

[0125] Determine a target rule corresponding to the alarm log, and based on the target rule, determine an alarm topic of the alarm log;

[0126] In this step, since there are dozens of types of network alarms for network devices, in order to distinguish alarm logs with different alarm topics, the alarm system determines the target rule corresponding to the current alarm log through the network management system, where the target rule can be a regular expression, that is, in the specific implementation, the regular expressions of each alarm topic are written in advance, each regular expression is a separate thread, and a multi-threaded parsing method is adopted, that is, the regular expression is applied concurrently to determine the target rule corresponding to the current alarm log, that is, the target regular expression. Finally, based on the target rule, the alarm topic of the network device is determined.

[0127] For example, the network device with management IP 2.2.2.2 generates many logs every day. Take the following two alarm logs as an example:

[0128] First item: sub Module 1 current-status is MOD_STATUS_ONLINE / OK;

[0129] Article 2: Interface Ethernet1 / 6 is down (Parent interface is down).

[0130] These two alarm logs belong to different alarm topics. By writing regular expressions in advance:

[0131] Regular expressions related to board status:

[0132] (.*)current-status is MOD_STATUS_ONLINE / (.*?);

[0133] Port jitter related regular expressions:

[0134] Interface(.*?)is down\((.*?)\).

[0135] Apply these regular expressions concurrently, that is, let each thread match the alarm log. In the example, for the first alarm log, only the thread that tries to match the regular expression related to the board status returns the correct result. Therefore, it can be determined that the alarm subject of the first alarm log is the board status. For the second alarm log, only the thread that tries to match the regular expression related to port jitter returns the correct result. Therefore, it can be determined that the alarm subject of the second alarm log is port jitter, etc.

[0136] Determine a cache topic of the cache log corresponding to the service thread, and match the alarm topic with the cache topic;

[0137] In this step, the network management system of the alarm system determines the cache topic of the cache log corresponding to the current business thread, and matches the alarm topic with the alarm topic of the current alarm log. The specific matching rules can be determined by regular expressions. The specific matching process is similar to the above and will not be repeated here. In the specific implementation, the network management system of the alarm system caches the cache log for a preset time. The preset time is an empirical value, generally one minute, that is, the cache log cached by the network management system of the alarm system only exists for one minute and is no longer saved after one minute. It is equivalent to the alarm log of the alarm within the preset time. If the alarm topic is the same, it is classified as one alarm to avoid repeated alarms. The alarm log that recurs after the preset time is a valid alarm.

[0138] If jitter occurs on one node of the current business thread, and jitter also occurs on another node of the current business thread within the preset time, the fault of the current business thread will only be alarmed once. If jitter is detected on another node after the preset time, an alarm will be issued at this time.

[0139] If the match is successful, it is determined that the alarm log is consistent with the cache log corresponding to the business thread.

[0140] In this step, if the match is successful, it is determined that the current alarm log is consistent with the cache log corresponding to the current business thread, that is, it is a repeated alarm. Before this, the alarm topic of the same business thread has already alarmed, and there is no need to repeat the alarm.

[0141] Step b: if not, obtain the auxiliary information corresponding to the business thread.

[0142] In this embodiment, if it is determined that the current alarm log is not a repeated alarm, an alarm needs to be issued externally. Therefore, at this time, auxiliary information corresponding to the business thread needs to be obtained to enrich the alarm information so that the operation and maintenance personnel who subsequently receive the alarm information can fully understand the fault details and achieve rapid troubleshooting.

[0143] In order to avoid duplicate alarms, this embodiment classifies alarms of the same alarm topic of the same business thread into one alarm, reduces duplicate alarm information, avoids duplication of work for operation and maintenance personnel, and realizes rapid troubleshooting.

[0144] Furthermore, based on the first and second embodiments of the network alarm method of the present invention, a third embodiment of the network alarm method of the present invention is proposed.

[0145] The third embodiment of the network alarm method is different from the first and second embodiments of the network alarm method in that, after step S30, the network alarm method further includes:

[0146] Step c, determining the inspection instruction of the alarm information, and based on the inspection instruction, detecting whether the fault corresponding to the alarm information has been resolved;

[0147] Step d: If the problem has been solved, mark the alarm information as solved.

[0148] In this embodiment, after sending the alarm information to the operation and maintenance terminal, it is necessary to track it to monitor whether the current fault has been resolved. If it has been resolved, it is marked as resolved. If it has not been resolved, an urging message is sent to the operation and maintenance terminal for urging.

[0149] The following is a detailed description of each step:

[0150] Step c, determining the inspection instruction of the alarm information, and based on the inspection instruction, detecting whether the fault corresponding to the alarm information has been resolved;

[0151] In this embodiment, the alarm system determines the inspection instructions of the current alarm information, that is, each alarm information corresponds to a different inspection instruction. In specific implementation, the corresponding inspection instruction is determined by the alarm subject of the alarm information, wherein the inspection instruction is a manually edited inspection procedure.

[0152] After determining the inspection instruction corresponding to the current alarm information, the alarm system sends the inspection instruction to the network device to detect whether the fault corresponding to the current alarm information has been resolved.

[0153] Specifically, step c includes:

[0154] Determine an inspection instruction for the alarm information, and send the inspection instruction to the network device;

[0155] In this step, the alarm system will store the alarm information in the database and automatically check whether the alarm is resolved at regular intervals. Specifically, the alarm system records the inspection instructions for each alarm topic and the regular match of the command echo. Therefore, the corresponding inspection instruction can be determined according to the alarm topic of the current alarm information, and the inspection instruction can be sent to the network device so that the network device can run the program corresponding to the inspection instruction for self-check and return the corresponding echo instruction, where the echo instruction is the command echo.

[0156] An echo instruction returned by the network device based on the inspection instruction is received, and whether the fault has been resolved is determined based on the echo instruction; wherein, if the state of the echo instruction is a specified state, it is determined that the fault has been resolved.

[0157] In this step, the alarm system receives the echo instruction returned by the network device based on the inspection instruction, and then the alarm system matches the preset regular expression according to the echo instruction to determine whether the fault corresponding to the current alarm information has been resolved. If the status of the echo instruction is a specified status, it is determined that the fault has been resolved; if the status of the echo instruction is a non-specified status, it is determined that the fault has not been resolved.

[0158] For example, the command corresponding to port jitter is: show int [port]. The alarm system determines the corresponding inspection command: show int xxx according to the alarm subject of the current alarm information, and sends the inspection command to the network device so that the network device can run the program corresponding to the inspection command. Then, the network device receives the echo command returned by the inspection command, matches the preset regular expression to determine the port status, and if it is up, it is restored. The next scheduled inspection will not need to check this alarm information again.

[0159] Step d: If the problem has been solved, mark the alarm information as solved.

[0160] In this embodiment, if it is determined that the fault has been resolved, the current alarm information is marked as resolved; if it is determined that the fault has not been resolved, the corresponding urging information is sent to the operation and maintenance terminal for urging.

[0161] This embodiment tracks the alarm information to determine whether the alarm information has been resolved. If it has been resolved, it is marked as resolved. If it has not been resolved, a corresponding urging message is sent to urge the operation and maintenance personnel, thereby improving the intelligence of the alarm and facilitating the operation and maintenance personnel to quickly troubleshoot.

[0162] The present invention also provides a network alarm device. The network alarm device of the present invention comprises:

[0163] A collection module, used to collect logs generated by network devices and extract alarm logs from the logs based on preset rules;

[0164] An acquisition module, used to determine the alarm content of the alarm log and obtain auxiliary information corresponding to the alarm content;

[0165] The sending module is used to encapsulate the alarm content and the auxiliary information into alarm information, and send the alarm information to the operation and maintenance terminal.

[0166] Furthermore, the alarm content includes an alarm field, and the acquisition module is further used for:

[0167] Acquire an alarm field of the network device, where the alarm field is used to characterize a device attribute of the network device;

[0168] Based on the alarm field, the service thread of the alarm log is determined, and auxiliary information corresponding to the service thread is obtained.

[0169] Furthermore, the acquisition module is also used for:

[0170] Based on the alarm field, determine the service thread of the alarm log, and determine whether the alarm log is consistent with the cache log corresponding to the service thread;

[0171] If not, obtain the auxiliary information corresponding to the service thread.

[0172] Furthermore, the alarm content includes an alarm subject, and the acquisition module is further used for:

[0173] Determine a target rule corresponding to the alarm log, and based on the target rule, determine an alarm topic of the alarm log;

[0174] Determine a cache topic of the cache log corresponding to the service thread, and match the alarm topic with the cache topic;

[0175] If the match is successful, it is determined that the alarm log is consistent with the cache log corresponding to the business thread.

[0176] Furthermore, the network alarm device further includes a detection module, and the detection module is used to:

[0177] Determine an inspection instruction for the alarm information, and based on the inspection instruction, detect whether the fault corresponding to the alarm information has been resolved;

[0178] If resolved, the alarm information is marked as resolved.

[0179] Furthermore, the detection module is also used for:

[0180] Determine an inspection instruction for the alarm information, and send the inspection instruction to the network device;

[0181] receiving an echo instruction returned by the network device based on the inspection instruction, and determining whether the fault has been resolved based on the echo instruction;

[0182] If the status of the echo instruction is a specified status, it is determined that the fault has been resolved.

[0183] Furthermore, the sending module is also used for:

[0184] Encapsulating the alarm content and the auxiliary information into alarm information, and determining a processing strategy corresponding to the alarm information;

[0185] The alarm information and the processing strategy are sent to the operation and maintenance terminal.

[0186] The present invention also provides a computer-readable storage medium.

[0187] The computer-readable storage medium of the present invention stores a network alarm program, and when the network alarm program is executed by a processor, the steps of the network alarm method described above are implemented.

[0188] Among them, the method implemented when the network alarm program running on the processor is executed can refer to the various embodiments of the network alarm method of the present invention, and will not be repeated here.

[0189] It should be noted that, in this article, the terms "include", "comprises" or any other variations thereof are intended to cover non-exclusive inclusion, so that a process, method, article or system including a series of elements includes not only those elements, but also other elements not explicitly listed, or also includes elements inherent to such process, method, article or system. In the absence of further restrictions, an element defined by the sentence "comprises a ..." does not exclude the existence of other identical elements in the process, method, article or system including the element.

[0190] The serial numbers of the above embodiments of the present invention are only for description and do not represent the advantages or disadvantages of the embodiments.

[0191] Through the description of the above implementation methods, those skilled in the art can clearly understand that the above-mentioned embodiment methods can be implemented by means of software plus a necessary general hardware platform, and of course by hardware, but in many cases the former is a better implementation method. Based on such an understanding, the technical solution of the present invention is essentially or the part that contributes to the prior art can be embodied in the form of a software product, which is stored in a storage medium (such as ROM / RAM, magnetic disk, optical disk) as described above, and includes a number of instructions for a terminal device (which can be a mobile phone, computer, server, air conditioner, or network device, etc.) to execute the methods described in each embodiment of the present invention.

[0192] The above are only preferred embodiments of the present invention, and are not intended to limit the patent scope of the present invention. Any equivalent structure or equivalent process transformation made using the contents of the present invention specification and drawings, or directly or indirectly applied in other related technical fields, are also included in the patent protection scope of the present invention.

Claims

1. A network alarm method, characterized in that: The network alarm method comprises the following steps: Collect logs generated by network devices and extract alarm logs from the logs based on preset rules; Determining the service thread of the alarm log according to the alarm field of the network device; Matching the alarm log with a plurality of preset target rules, determining a matching target rule, and determining an alarm subject corresponding to the matching target rule as an alarm subject of the alarm log, wherein the plurality of target rules include: a target rule for board status and a target rule for port jitter; Determine the cache subject of the cache log corresponding to the business thread, and match the alarm subject with the cache subject, and if the match fails, obtain the auxiliary information corresponding to the business thread; Encapsulating the alarm subject, the alarm field and the auxiliary information into alarm information, and sending the alarm information to an operation and maintenance terminal; The business thread includes multiple nodes. Within a set time period, an alarm message is sent only once for the same alarm topic of different nodes in the business thread. After the set time period, an alarm message is sent again for the same alarm topic of another node in the business thread.

2. The network alarm method according to claim 1, characterized in that: The alarm field is used to characterize the device attribute of the network device.

3. The network alarm method according to claim 1, characterized in that: After the step of encapsulating the alarm subject, the alarm field and the auxiliary information into alarm information, and sending the alarm information to the operation and maintenance terminal, the network alarm method further includes: Determine an inspection instruction for the alarm information, and based on the inspection instruction, detect whether the fault corresponding to the alarm information has been resolved; If resolved, the alarm information is marked as resolved.

4. The network alarm method according to claim 3, characterized in that: The step of determining the inspection instruction of the alarm information and detecting whether the fault corresponding to the alarm information has been resolved based on the inspection instruction includes: Determine an inspection instruction for the alarm information, and send the inspection instruction to the network device; receiving an echo instruction returned by the network device based on the inspection instruction, and determining whether the fault has been resolved based on the echo instruction; If the status of the echo instruction is a specified status, it is determined that the fault has been resolved.

5. The network alarm method according to any one of claims 1 to 4, characterized in that: The step of encapsulating the alarm subject, the alarm field and the auxiliary information into alarm information, and sending the alarm information to the operation and maintenance terminal includes: Encapsulating the alarm subject, the alarm field and the auxiliary information into alarm information, and determining a processing strategy corresponding to the alarm information; The alarm information and the processing strategy are sent to the operation and maintenance terminal.

6. A network alarm device, characterized in that: The network alarm device comprises: A collection module, used to collect logs generated by network devices and extract alarm logs from the logs based on preset rules; An acquisition module is used to determine the business thread of the alarm log according to the alarm field of the network device; match the alarm log with multiple preset target rules, determine the matching target rule, and determine the alarm subject corresponding to the matching target rule as the alarm subject of the alarm log, wherein the multiple target rules include: a target rule for board status and a target rule for port jitter; determine the cache subject of the cache log corresponding to the business thread, and match the alarm subject with the cache subject. If the match is unsuccessful, obtain the auxiliary information corresponding to the business thread; A sending module is used to encapsulate the alarm subject, the alarm field and the auxiliary information into alarm information, and send the alarm information to the operation and maintenance terminal; the business thread includes multiple nodes, and within a set time period, an alarm message is only sent once for the same alarm subject of different nodes in the business thread, and after the set time period, an alarm message is sent again for the same alarm subject of another node in the business thread.

7. A network alarm system, characterized in that: The network alarm system comprises: a memory, a processor, and a network alarm program stored in the memory and executable on the processor. When the network alarm program is executed by the processor, the steps of the network alarm method according to any one of claims 1 to 5 are implemented.

8. A computer-readable storage medium, characterized in that: The computer-readable storage medium stores a network alarm program, and when the network alarm program is executed by the processor, the steps of the network alarm method according to any one of claims 1 to 5 are implemented.