Abnormal classification method, device, abnormal classification equipment and storage medium

The server log information is analyzed through multiple target classification models and machine learning algorithms, which solves the problem of low efficiency of server exception classification, achieves fast and accurate exception type identification and improves server maintenance efficiency.

CN113515434BActive Publication Date: 2024-09-10TENCENT TECHNOLOGY (SHENZHEN) CO LTD
View PDF 0 Cites 0 Cited by

Patent Information

Application Number
CN202110004842.4
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-01-04
Publication Date
2024-09-10
Estimated Expiration
2041-01-04

AI Technical Summary

Technical Problem

In the existing technology, it is difficult to quickly and accurately determine the abnormality type when classifying server anomalies. This is mainly due to the large amount of log information data and the limited ability of the analyst, resulting in low efficiency of manual analysis.

Method used

Multiple target classification models are used to analyze target log information, and a target classification model is constructed through machine learning algorithms. Combining text vectorization and multi-model fusion strategies, a voting mechanism is used to determine anomaly types.

Benefits of technology

It greatly reduces labor costs and time costs, improves the efficiency of anomaly classification, improves the accuracy and identification capabilities of anomaly classification, and avoids the defects of a single model.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN113515434B
    Figure CN113515434B
Patent Text Reader

Abstract

The present application discloses an abnormality classification method, device, abnormality classification equipment and storage medium, wherein the method comprises: in response to a trigger operation of abnormality classification of a target server, obtaining target log information generated by the target server when an abnormality is generated; obtaining at least two target classification models, wherein one target classification model uses an abnormality classification algorithm to perform abnormality classification on the target server; calling each target classification model to perform abnormality classification on the target server according to the target log information, and obtaining the abnormality classification result of each target classification model on the target server; and determining the target abnormality type of the target server according to the abnormality classification result of each target classification model. By using multiple target classification models to analyze the target log information, it is helpful for the abnormality classification device to accurately obtain the abnormality of the target server, so as to accurately locate the real cause of the abnormality of the target server.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the field of computer technology, and in particular to an anomaly classification method, an anomaly classification device, an anomaly classification equipment and a computer storage medium. Background Art

[0002] As society continues to develop and mature, Internet services require more servers to provide computing or application services. However, servers may experience abnormalities during operation. Therefore, in order to ensure the normal execution of Internet services, it is necessary to locate the cause of the server abnormality so that the server can be operated and maintained based on the abnormal cause.

[0003] In order to locate the cause of the server anomaly, it is necessary to classify the abnormal server according to the log information. In the existing anomaly classification scheme, the log information of the abnormal server can be manually analyzed to determine the abnormal type of the abnormal server. However, due to the large amount of log information corresponding to an abnormal server, or the limited analysis ability of the analyst, manual analysis may be difficult and inefficient, and it is impossible to quickly and accurately determine the abnormal type of the abnormal server. Therefore, how to classify the abnormal server is an important research topic. Summary of the invention

[0004] The embodiments of the present invention provide an exception classification method, an apparatus, an exception classification device and a storage medium. By adopting multiple target classification models to analyze target log information, the exception classification device can accurately obtain the anomaly of the target server, thereby accurately locating the real cause of the abnormality of the target server.

[0005] On the one hand, an embodiment of the present invention provides an abnormality classification method, the abnormality classification method comprising:

[0006] In response to a trigger operation of performing abnormal classification on a target server, obtaining target log information generated by the target server when an abnormality is generated;

[0007] Acquire at least two target classification models, wherein one target classification model uses an anomaly classification algorithm to perform anomaly classification on the target server;

[0008] Calling each target classification model to perform abnormal classification on the target server according to the target log information, and obtaining an abnormal classification result of each target classification model on the target server;

[0009] According to the abnormal classification result of each target classification model, the target abnormal type of the target server is determined.

[0010] On the other hand, an embodiment of the present invention provides an abnormality classification device, the abnormality classification device comprising:

[0011] An acquisition unit, configured to, in response to a trigger operation for classifying an exception on a target server, acquire target log information generated by the target server when an exception occurs;

[0012] The acquisition unit is further used to acquire at least two target classification models, wherein one target classification model uses an abnormality classification algorithm to perform abnormality classification on the target server;

[0013] an abnormality classification unit, used for calling each target classification model to perform abnormality classification on the target server according to the target log information, and obtaining an abnormality classification result of each target classification model on the target server;

[0014] The determination unit is used to determine the target abnormality type of the target server according to the abnormality classification result of each target classification model.

[0015] On the other hand, an embodiment of the present invention provides an abnormality classification device, the abnormality classification device includes an input interface, an output interface, and the abnormality classification device also includes:

[0016] a processor adapted to implement one or more instructions; and,

[0017] A computer storage medium storing one or more instructions, wherein the one or more instructions are suitable for being loaded by the processor and executing the following steps:

[0018] In response to a trigger operation of performing abnormal classification on a target server, obtaining target log information generated by the target server when an abnormality is generated;

[0019] Acquire at least two target classification models, wherein one target classification model uses an anomaly classification algorithm to perform anomaly classification on the target server;

[0020] Calling each target classification model to perform abnormal classification on the target server according to the target log information, and obtaining an abnormal classification result of each target classification model on the target server;

[0021] According to the abnormal classification result of each target classification model, the target abnormal type of the target server is determined.

[0022] In another aspect, an embodiment of the present invention provides a computer storage medium, wherein the computer storage medium stores one or more instructions, wherein the one or more instructions are suitable for being loaded by a processor and executing the following steps:

[0023] In response to a trigger operation of performing abnormal classification on a target server, obtaining target log information generated by the target server when an abnormality is generated;

[0024] Acquire at least two target classification models, wherein one target classification model uses an anomaly classification algorithm to perform anomaly classification on the target server;

[0025] Calling each target classification model to perform abnormal classification on the target server according to the target log information, and obtaining an abnormal classification result of each target classification model on the target server;

[0026] According to the abnormal classification result of each target classification model, the target abnormal type of the target server is determined.

[0027] In an embodiment of the present invention, the abnormal classification device responds to the trigger operation of abnormal classification of the target server, obtains the target log information generated by the target server when the abnormality is generated, and uses the abnormal classification algorithm to train to obtain multiple target classification models; then calls multiple target classification models to perform abnormal classification on the target server according to the target log information. Since the abnormal classification of the target server is completed based on the target classification model constructed by the machine learning algorithm, the analyst does not need to analyze the target log information of the target server one by one, which can reduce manual operation, greatly reduce the labor cost and time cost, effectively save human resources, and improve the efficiency of abnormal classification. In addition, the embodiment of the present invention constructs a target classification model through text vectorization and machine learning algorithm to perform abnormal classification on the target server, which can identify different abnormal types and has a high recognition accuracy. In addition, since the embodiment of the present invention uses at least two target classification models to perform abnormal classification on the target server according to the target log information, a multi-model fusion strategy is adopted, and the abnormal type of the target server is determined from the abnormal classification results of multiple target classification models by a voting mechanism, the defects of a single classification model are avoided, and the accuracy of server abnormal classification can be further guaranteed. BRIEF DESCRIPTION OF THE DRAWINGS

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

[0029] Figure 1 is a structural diagram of an abnormality classification system provided in an embodiment of the present application;

[0030] Figure 2It is a flowchart of an abnormal classification method provided in an embodiment of the present application;

[0031] Figure 3 It is a schematic diagram of a process for constructing a target classification model provided in an embodiment of the present application;

[0032] Figure 4 It is a schematic diagram of a preprocessing process provided in an embodiment of the present application;

[0033] Figure 5 is a schematic diagram of a decision tree provided in an embodiment of the present application;

[0034] Figure 6 It is a schematic diagram of a category provided by an embodiment of the present application;

[0035] Figure 7 is a test result diagram of the target classification model provided in the embodiment of the present application;

[0036] Figure 8 is a structural schematic diagram of an abnormality classification device provided in an embodiment of the present application;

[0037] Fig. 9 It is a structural schematic diagram of an abnormal classification device provided in an embodiment of the present application. DETAILED DESCRIPTION

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

[0039] Artificial intelligence technology is a comprehensive discipline that covers a wide range of fields, including both hardware-level and software-level technologies. The basic technologies of artificial intelligence generally include technologies such as sensors, dedicated artificial intelligence chips, cloud computing, distributed storage, big data processing technology, operation / interaction systems, and mechatronics. Artificial intelligence software technology mainly includes computer vision technology, speech processing technology, natural language processing technology, and machine learning / deep learning. Among them, machine learning (ML) is a multi-disciplinary subject that involves probability theory, statistics, approximation theory, convex analysis, algorithm complexity theory, and other disciplines. It specializes in studying how computers simulate or implement human learning behavior to acquire new knowledge or skills and reorganize existing knowledge structures to continuously improve their performance.

[0040] With the research and progress of artificial intelligence technology, artificial intelligence technology has been studied and applied in many fields, such as common smart homes, smart wearable devices, virtual assistants, smart speakers, smart marketing, unmanned driving, autonomous driving, drones, robots, smart medical care, smart customer service, etc. In addition, artificial intelligence technology can also be applied in other fields. For example, machine learning in artificial intelligence technology can be used to achieve intelligent operation and maintenance of servers. Among them, the embodiment of the present invention proposes an abnormality classification method based on machine learning, so that the abnormality classification device can construct multiple classification models through machine learning, so that when the server generates an abnormality, the abnormality classification device can call the constructed multiple classification models to perform abnormal classification on the log information when the server generates an abnormality, and then the abnormality type of the server can be determined according to the abnormality classification result of the log information by each classification model. The classification result of the abnormality type of the server based on different classification models can reduce the error rate when determining the abnormality type of the server, thereby achieving the accuracy of locating the server abnormality. At the same time, using machine learning to obtain multiple classification models, and using the learned classification models to classify the server abnormalities, it is helpful to realize the artificial intelligence for ITOperations (AIOps) of the abnormality classification device to improve the maintenance efficiency of the server. Among them, intelligent operation and maintenance refers to combining human knowledge and operation and maintenance experience with big data and machine learning technology to develop a series of intelligent strategies, integrate them into the operation and maintenance system, and use the developed intelligent strategies (or operation and maintenance system) to complete the operation and maintenance tasks.

[0041] In one embodiment, the abnormality classification method can be used to classify abnormalities of a server or terminal device, so as to determine the abnormality of the corresponding server or terminal device. When the abnormality classification method is used to determine the abnormality of the server, the abnormality classification method can be applied to Figure 1 In the abnormal classification system shown, Figure 1 As shown, the abnormal classification system may include at least: an abnormal classification device 11 and a server 12, wherein the abnormal classification device 11 is a device running at least two classification models, and the abnormal classification device 11 may be as follows Figure 1 The terminal device shown in the figure, wherein the terminal device may include but is not limited to: a smart phone, a tablet computer, a laptop computer, a wearable device, a desktop computer, etc.; or, the abnormal classification device 11 may also be a server, which is not limited in the embodiment of the present invention. In addition, the number of servers 12 included in the abnormal classification system may be one or more, and the server 12 may be as follows: Figure 1The server 12a, server 12b, or server 12c shown is one server, or a combination of multiple servers. The server 12 can be an independent physical server, or a server cluster or distributed system composed of multiple physical servers. It can also be a cloud server that provides basic cloud computing services such as cloud services, cloud databases, cloud computing, cloud functions, cloud storage, network services, cloud communications, content delivery networks (CDN), middleware services, domain name services, security services, and big data and artificial intelligence platforms, etc.

[0042] The abnormal classification method has a wide range of application scenarios and can be applied to various service platforms that record log information, such as Tencent Cloud's cloud dialing, cloud virtual machines (Cloud Virtual Machine, CVM), cloud monitoring products, etc. It can also be applied to various types of log information, including system logs (System Log, syslog), various types of software log information and hardware log information, etc.

[0043] In a specific implementation, the abnormal classification device 11 can determine whether the server 12 is abnormal based on the log information of the server 12. Then, when the abnormal classification device 11 performs abnormal classification on the server 12, it can first obtain the target log information generated by the server 12 when the abnormality occurs, wherein the log information is used to record user operations, system operation status, etc., and is an important part of the system. For the back-end program that provides services for many products as a basic platform, it is necessary to consider how to rely on good logs to ensure the reliable operation of the system. For example, the system log (System Log, syslog) is an industrial standard protocol that can be used to record the logs of the device. In the UNIX system (an operating system), routers, switches and other network devices, syslog can record large and small events that occur at any time in the system, so the manager can check the system logs and keep track of the system status at any time. The UNIX system log records system-related events through the syslog process, and can also record application operation events. Then, through appropriate configuration, it is possible to realize communication between machines running the syslog protocol, and by analyzing these network behavior logs, it is possible to track and grasp the status related to the device and the network. The log information can be, for example:

[0044] [INFO]RequestID:b1946ac92492d2347c6235b4d2611184, auth failed due to token expiration;

[0045] [INFO]RequestID:b1946ac92492d2347c6235b4d2611185, content digest does not match, expect 7b3f050bfa060b86ba781151c563c953, actual f60645e7107917250a6408f2f302d048;

[0046] [INFO]RequestID:b1946ac92492d2347c6235b4d2611186, request ip (=202.17.34.1) not in whitelist.

[0047] After the abnormal classification device 11 obtains the target log information generated when the server 11 generates an abnormality, at least two trained target classification models can be obtained, so that each target classification model can be called to use the corresponding abnormal classification algorithm to classify the target server for abnormality. Specifically, the abnormal classification device 11 can use the corresponding abnormal classification algorithm in each target classification model to classify the target log information, so as to obtain the voting result of each target classification model for the abnormal classification of the target server, so as to further determine the target abnormal type of the target server based on the voting result of the abnormal classification of each target classification model. For example, if the abnormal classification device calls three target classification models to classify and vote on the collected target log information, if the three target classification models are model A, model B and model C, if model A and model B of the three target classification models determine that the target server belongs to type 1 abnormality according to the target log information, and model C determines that the target server belongs to type 2 abnormality according to the target log information, then the abnormal classification device determines that the target server belongs to type 1 abnormality according to the results of the three target classification models. By adopting multiple target classification models to analyze the target log information, it is helpful for the abnormal classification device to accurately obtain the abnormality of the target server, so as to further locate the real cause of the abnormality of the target server, and then the corresponding components can be replaced according to the cause of the abnormality of the target server, and the abnormality rate of each component can be counted. The embodiment of the present invention can learn the log data that causes the server abnormality by using machine learning methods, so as to precipitate some models that can automatically analyze the causes of server abnormalities, thereby improving the efficiency of server abnormality analysis. Similarly, these models can also be based on the summary of the rules of abnormal analysis of the server to achieve prediction of server abnormalities, etc.

[0048] See also Figure 2 , is a flow chart of an abnormality classification method proposed in an embodiment of the present invention. Figure 2As shown, the abnormal classification method includes steps S201-S204:

[0049] S201, in response to a triggering operation of performing abnormal classification on a target server, obtaining target log information generated by the target server when an abnormality occurs.

[0050] In one embodiment, the target server is any server that has established a communication connection with an exception classification device, wherein the target server will report the exception to the exception classification device when an exception occurs. Specifically, the target server can send work order information to the exception classification device, so that the exception classification device can determine the target log information generated when the target server generates an exception based on the work order information, and determine the target exception type of the target server based on the target log information; then correspondingly, when the exception classification device obtains the work order information from the target server, it can be determined that a trigger operation for classifying the target server as an exception is detected, wherein the work order information carries a work order number (ticket_id), and the work order information is made to correspond to the target server based on the work order number; the work order information records the time information when the target server generates the exception, and based on the time information, the exception classification device can obtain the target log information generated by the target server when the exception occurs. In another embodiment, the abnormal classification device may also determine that a trigger operation for classifying the target server as an abnormality is detected when an alarm message from the target server is detected, wherein when an abnormality occurs in the target server, the target server will issue an alarm reminder, wherein when the target server issues an alarm reminder, an alarm message will be sent to the person in charge (i.e., the person who maintains the target server). Then, the abnormal classification device may determine that a trigger operation for classifying the target server as an abnormality is detected when it is determined that the target server has sent an alarm message to the person in charge, wherein the alarm message (also referred to as a notification message) may be sent when a basic alarm occurs on the target server (such as excessive usage of the central processing unit (CPU)), or when a performance indicator alarm occurs on the target server (such as a low user access success rate). When the target server sends the alarm message to the person in charge, it may be sent to the person in charge through social software such as WeChat, mini-programs, or enterprise WeChat.

[0051] In one embodiment, the log information generated when the target server generates an exception includes multiple types of log information. The target log information generated when the target server generates an exception according to the embodiment of the present invention is log information that helps the exception classification device to classify the target server for exceptions, that is, the target log information of the target server obtained by the embodiment of the present invention is a specific type of log information that helps to locate the exception (or classify the exception), wherein, for example, the target log information can be:

[0052] ① A log information that records kernel information (i.e., dmesg log information), where dmesg log information is used to record the last screen before the target server crashes, and contains netconsole data (a type of data used to indicate whether the kernel has a fault);

[0053] ② A log information that records hardware information (i.e., mcelog log information), wherein mcelog log information is used to record exceptions caused by hardware errors;

[0054] ③ A system event log (i.e., sel log information), wherein the sel log information is a log generated when the target server sensor collects data and finds an abnormality.

[0055] After the abnormality classification device obtains the target log information generated when the target server is abnormal, the trained target classification model can be used to determine the abnormality category of the target server according to the target log information, that is, step S202 is executed.

[0056] S202, obtaining at least two target classification models, wherein one target classification model uses an anomaly classification algorithm to perform anomaly classification on a target server.

[0057] S203, calling each target classification model to perform abnormal classification on the target server according to the target log information, and obtaining the abnormal classification result of each target classification model on the target server.

[0058] In step S202 and step S203, the abnormal classification algorithm includes but is not limited to one or more of the following: decision tree (DT) algorithm, Rocchio algorithm, extreme gradient boosting (XGBooste) algorithm, Naive Bayes (NB) algorithm, Linear Discriminant Analysis (LDA), Support Vector Machine (SVM) algorithm, Random Forest (RF) algorithm, and Logistic Regression (LR) algorithm. Among them, the DT algorithm is a machine learning algorithm for constructing a tree structure, each non-leaf node of the constructed decision tree is used to represent a test on a feature attribute, each branch of the constructed decision tree represents the output of this feature attribute, and each leaf node of the constructed decision tree is used to represent the result of abnormal classification. The Rocchio algorithm is a text classification algorithm, which mainly determines the abnormal classification result by the cosine similarity between vectors. The GBoost algorithm is an integrated machine learning algorithm, which mainly determines the abnormal classification result through multiple interrelated classification regression trees. Among them, the mutually related classification and regression trees refer to the training results and test results of the generated i+1 classification and regression trees and the i classification and regression trees, where i is a positive integer greater than 0. The NB algorithm is a classification algorithm based on Bayes' theorem, which mainly determines the abnormal classification results by the probability obtained by the maximum likelihood estimation algorithm. The LDA algorithm mainly determines the abnormal classification results by the distance obtained by the distance algorithm. The SVM algorithm is a binary classification model algorithm, which determines the abnormal classification results by the optimal hyperplane constructed by the kernel function. The RF algorithm is also an integrated machine learning algorithm, which mainly determines the abnormal classification results through multiple independent decision trees. The LR algorithm is a traditional binary classification model algorithm, which can also be applied to multi-classification tasks. It mainly splits the multi-classification task into several binary classification tasks, then trains a model for each binary classification task, and finally determines the abnormal classification results by the classification results of multiple models.

[0059] In one embodiment, the exception classification device can convert the target log information into a vector expression by vector conversion. Then, each of the at least two target classification models is called to perform exception classification on the vector expression corresponding to the target log information, and the target category to which the vector expression belongs can be determined from a plurality of categories to be selected. Then, the exception type indicated by the target category is used as the exception classification result of the target server by each target classification model. Since the target log information of the target server is text-vectorized (i.e., the target log information is converted into a vector expression of the target log information), and the target classification model performs exception classification on the vector expression corresponding to the target log information, the target log information and the exception type are no longer a simple one-to-one correspondence, and the method of using the target classification model to perform exception classification on the vector expression corresponding to the target log information is more accurate.

[0060] The process of the abnormal classification device classifying the target server according to the target log information is a process in which the abnormal classification device analyzes the target log information using a corresponding abnormal classification algorithm to determine the abnormal category to which the target server belongs. The abnormal classification results obtained by each target classification model for classifying the target server according to the target log information may be the same or different. After the abnormal classification device obtains the abnormal classification results of each target classification model for the target server, the target abnormal type of the target server may be determined based on the abnormal classification results of each target classification model, that is, step S204 is executed instead.

[0061] In one embodiment, if the abnormal classification device uses the DT algorithm to classify the target server, the abnormal classification device can first convert the target log information into a vector expression corresponding to the target log information. Then, the vector expression is tested starting from the root node of the constructed decision tree, and the output branch is selected according to the output of the vector expression until the leaf node of the decision tree is reached, and the category corresponding to the leaf node is determined as the target category to which the vector expression belongs. Then, the abnormal type indicated by the target category is used as the abnormal classification result of the target server by the target classification model constructed by the DT algorithm.

[0062] In one embodiment, if the abnormal classification device uses the Rocchio algorithm to perform abnormal classification on the target server, the abnormal classification device can first convert the target log information into a vector expression corresponding to the target log information. Then, the cosine similarity of the sample vector corresponding to the vector expression and the log sample in each log sample subset is calculated respectively, and the category corresponding to the sample vector with the highest cosine similarity is determined as the target category to which the vector expression belongs. Then, the abnormal type indicated by the target category is used as the abnormal classification result of the target server by the target classification model constructed by the Rocchio algorithm. Alternatively, if the abnormal classification device uses the XGBoost algorithm to perform abnormal classification on the target server, the abnormal classification device can first convert the target log information into a vector expression corresponding to the target log information. Then, the vector expression is input into the i-th classification and regression tree to obtain the i-th value, and the i-th value is input into the i+1-th classification and regression tree to obtain the i+1-th value. After obtaining the values ​​output by multiple classification and regression trees, the output values ​​of multiple interrelated classification and regression trees can be calculated using the optimal algorithm to obtain the target value. Finally, the target category to which the vector expression belongs is determined according to the numerical range to which the target value belongs. The abnormal type indicated by the target category is used as the abnormal classification result of the target server by the target classification model constructed by the XGBoost algorithm.

[0063] In one embodiment, if the abnormal classification device uses the NB algorithm to classify the target server, the abnormal classification device can first convert the target log information into a vector expression corresponding to the target log information, and then use the maximum likelihood estimation algorithm to calculate the Bayesian probability of the sample vectors corresponding to the vector expression and the log samples in each log sample subset, and determine the category to be selected corresponding to the sample vector with the largest probability as the target category to which the vector expression belongs. The abnormal type indicated by the target category is used as the abnormal classification result of the target server by the target classification model constructed by the NB algorithm.

[0064] In one embodiment, if the abnormal classification device uses the LDA algorithm to classify the target server, the abnormal classification device can first convert the target log information into a vector expression corresponding to the target log information. Then, the distance calculation method is used to calculate the distance between the vector expression and the sample vector corresponding to the log sample in each log sample subset, and the category to be selected corresponding to the sample vector with the closest distance is determined as the target category to which the vector expression belongs. The abnormal type indicated by the target category is used as the abnormal classification result of the target server by the target classification model constructed by the LDA algorithm. Among them, the method of calculating the distance may include but is not limited to the Mahalanobis distance.

[0065] In one embodiment, if the exception classification device uses the SVM algorithm to classify the target server as an exception, the exception classification device can first convert the target log information into a vector expression corresponding to the target log information, and then determine the relative position of the vector expression and the optimal hyperplane in the high-dimensional space. If the vector expression is located on the first side of the optimal hyperplane, the category to be selected indicated by the sample vector on the first side is determined as the target category to which the vector expression belongs. If the vector expression is located on the other side of the optimal hyperplane, the category to be selected indicated by the sample vector on the other side is determined as the target category to which the vector expression belongs. The exception type indicated by the target category is used as the exception classification result of the target server by the target classification model constructed by the SVM algorithm.

[0066] In one embodiment, if the abnormal classification device uses the RF algorithm to classify the target server, the abnormal classification device can first convert the target log information into a vector expression corresponding to the target log information. Then, multiple decision trees are used to classify the vector expression respectively to obtain multiple reference sample vectors, and a sample vector is determined from the multiple reference sample vectors based on a voting mechanism, and the category to be selected corresponding to the sample vector is determined as the target category to which the vector expression belongs. The abnormal type indicated by the target category is used as the abnormal classification result of the target server by the target classification model constructed by the RF algorithm.

[0067] In one embodiment, if the anomaly classification device uses the LR algorithm to classify the target server as an anomaly, the anomaly classification device may first convert the target log information into a vector expression corresponding to the target log information. Then, the vector expression of the target log information is input into the training model of each binary classification task, and the classification results of multiple models are integrated to obtain the target category to which the vector expression belongs.

[0068] Each target classification model mentioned here has different effects on the abnormal classification of the target server. Some target classification models have high accuracy in the abnormal classification of the target server, while some target classification models have low accuracy in the abnormal classification of the target server. Some target classification models have high recall rates for the abnormal classification of the target server, while some target classification models have low recall rates for the abnormal classification of the target server. Therefore, the embodiment of the present invention uses multiple target classification models to classify the abnormalities of the target server according to the target log information, which can avoid the defects of a single target classification model and further ensure the accuracy and recall rate of abnormal classification.

[0069] S204: Determine the target abnormality type of the target server according to the abnormality classification result of each target classification model.

[0070] Among them, since the exception classification device calls at least two target classification models to perform exception classification on the vector expression corresponding to the target log information, and the exception classification results obtained by calling different target classification models to perform exception classification on the target log information may be the same or different, that is, the exception classification device will obtain multiple exception classification results for the target server from each target classification model. After the exception classification device obtains the corresponding exception classification results from each target classification model, the exception classification results of the target server by most models can be used to determine the target exception type of the target server. In one embodiment, if the exception classification results of each target classification model for the target server are different, the exception classification device can select the exception classification result of any target classification model for the target server, and use the exception type indicated by the selected exception classification result as the target exception result of the target server. For example, if the four target classification models are model A, model B, model C and model D, if model A in the four target classification models determines that the target server belongs to type 1 abnormality according to the target log information, model B determines that the target server belongs to type 2 abnormality according to the target log information, model C determines that the target server belongs to type 3 abnormality according to the target log information, and model D determines that the target server belongs to type 4 abnormality according to the target log information, then the abnormality classification device determines that the target server belongs to type 1 abnormality, type 2 abnormality, type 3 abnormality or type 4 abnormality according to the results of the four target classification models. Among them, the majority can also be a ratio threshold, which can be set by experience or business needs, and the ratio threshold can be 80%, 90%, etc.

[0071] In another embodiment, if there are at least two target classification models with the same abnormal classification results for the target server, then the reference classification results with the same number of the most selected ones can be determined from the abnormal classification results of the target server by each target classification model; the abnormal type indicated by the selected reference classification results with the same number of the most selected ones is used as the target abnormal result of the target server. For example, if the four target classification models are model A, model B, model C and model D, if model A, model B and model C of the four target classification models determine that the target server belongs to type 1 abnormality according to the target log information, and model D determines that the target server belongs to type 2 abnormality according to the target log information, then the abnormal classification device determines that the target server belongs to type 1 abnormality according to the results of the four target classification models.

[0072] Furthermore, if the number of reference classification results with the same number at most is determined from the abnormal classification results of the target server by each target classification model is multiple, then the abnormal type indicated by any one of the reference classification results can be used as the target abnormal result of the target server. For example, if the four target classification models are model A, model B, model C and model D, if model A and model B of the four target classification models determine that the target server belongs to type 1 abnormality based on the target log information, and model C and model D determine that the target server belongs to type 2 abnormality based on the target log information, then the abnormal classification device determines that the target server belongs to type 1 abnormality or type 2 abnormality based on the results of the four target classification models.

[0073] In one embodiment, in order to more quickly determine the target abnormality type of the target server, after determining the target abnormality type of the target server, the abnormal classification device can also use an association rule mining algorithm to determine the association relationship between the target log information and the target abnormality type, and store the association relationship. The association relationship indicates the probability that the target server is the target abnormality type when the target server generates the target log information, so that when the target server generates this target log information again, the abnormal classification device can no longer call the target classification model for abnormal classification, and can directly determine the target abnormality type of the target server according to the probability in the association relationship. Alternatively, the abnormal classification device can also determine the target abnormality type of the target server according to the abnormal classification results of each target classification model for the target server and the probability in the association relationship. The speed and accuracy of the abnormal classification device in determining the target abnormality type of the target server can be improved.

[0074] In one embodiment, after determining the target abnormality type of the target server, the abnormality classification device can also determine whether there is an associated abnormality type related to the target abnormality type. If so, the associated abnormality type is used as the predicted abnormality type of the target server. Among them, the associated abnormality type is an abnormality type generated according to the target abnormality after the target abnormality of the target abnormality type is generated. Since there is a correlation between the associated abnormality type and the target abnormality type, when the abnormality classification device determines that the target server has generated an abnormality of the target abnormality type, the abnormality classification device can guess that the target server may generate an abnormality of the associated abnormality type in the subsequent time of generating the target abnormality type. The data of the target server can be processed in real-time streaming to achieve the prediction of the associated abnormality type of the target abnormality type, so that the associated abnormality type of the target server can be prevented, further improving the user experience.

[0075] In an embodiment of the present invention, the abnormal classification device responds to the trigger operation of abnormal classification of the target server, obtains the target log information generated by the target server when the abnormality is generated, and uses the abnormal classification algorithm to train to obtain multiple target classification models; then calls multiple target classification models to perform abnormal classification on the target server according to the target log information. Since the abnormal classification of the target server is completed based on the target classification model constructed by the machine learning algorithm, the analyst does not need to analyze the target log information of the target server one by one, which can reduce manual operation, greatly reduce the labor cost and time cost, effectively save human resources, and improve the efficiency of abnormal classification. In addition, the embodiment of the present invention constructs a target classification model through text vectorization and machine learning algorithm to perform abnormal classification on the target server, which can identify different abnormal types and has a high recognition accuracy. In addition, since the embodiment of the present invention uses at least two target classification models to perform abnormal classification on the target server according to the target log information, a multi-model fusion strategy is adopted, and the abnormal type of the target server is determined from the abnormal classification results of multiple target classification models by a voting mechanism, the defects of a single classification model are avoided, and the accuracy of server abnormal classification can be further guaranteed.

[0076] See above Figure 2 It can be seen from the relevant description of the method embodiment shown that Figure 2 The anomaly classification method shown can implement anomaly classification of abnormal servers by calling the target classification model. Each target classification model is a classification function / classification model constructed based on an existing log information set, that is, a decision surface. Figure 3 As shown, the embodiment of the present invention proposes a flow chart of building a target classification model. Figure 3 As shown in Figure 2, the construction process of the target classification model mainly includes Figure 3 The model training part shown on the left and Figure 3 The model test part is shown in the figure on the right. Figure 3 As shown in FIG. 1 , the process of constructing the target classification model may include steps S301-S304:

[0077] S301, obtaining a log information set when an exception occurs in the server, and preprocessing the log information set to obtain a log sample set, wherein the preprocessing includes one or more of the following: data screening, data cleaning, and text segmentation.

[0078] When an exception occurs on the server, it will report the exception to the exception classification device. The server can send work order information to the exception classification device so that the exception classification device can determine the log information generated when the server generates an exception based on the work order information. The exception classification device can obtain the log information generated when the server generates an exception within a time period to obtain a log information set. The time period can be a variable time period, such as October 1, 2020-November 1, 2020, the five days closest to the current day, or the month closest to the current month, etc. The server can be a single server or a combination of multiple servers, which is not limited in the embodiments of the present invention.

[0079] After obtaining the log information set, the abnormal classification device can divide the log information into a training log information set and a test log information set through a data partitioning operation. The data partitioning operation may include a random stratified sampling method. The training log information set is used to build a target classification model, and the test log information set is used to verify the model effect of the target classification model. For example, 70% of the log information set can be used as a training log information set, and 30% of the log information set can be used as a test log information set.

[0080] In one embodiment, after obtaining the training log information set and the test log information set, the anomaly classification device may preprocess the training log information set to obtain a log sample set for training, and preprocess the test log information set to obtain a log sample set for testing.

[0081] The following is a detailed description of the process of preprocessing the training log information set to obtain the log sample set for training. Figure 4 , is a flow chart of a preprocessing method provided by an embodiment of the present invention, which mainly includes data screening s11, data cleaning s12 and data balancing s13.

[0082] Specifically, the anomaly classification device first screens the training log sample set, then cleans the data, and determines whether the cleaned data is balanced. If it is unbalanced, data balancing is required. After data balancing, a log sample set for training can be obtained, which can be used to build a target classification model and perform anomaly analysis on the target server based on the target classification model.

[0083] s11, data screening

[0084] For the log information in the training log information set, the log information generated when the server is abnormal and obtained by the embodiment of the present invention is log information that helps the abnormal classification device to classify the server abnormally, that is, the log information of the server obtained by the embodiment of the present invention is of a specific type, which is helpful for abnormal location (or abnormal classification). However, the log information obtained by the abnormal classification device when the server is abnormal may include log information that does not belong to the above-mentioned specific type. For example, the server's startup log, etc. The abnormal classification device needs to filter out log information of a specific type from the training log information set. Among them, the specific type of log information can be set according to experience or business needs.

[0085] s12, data cleaning

[0086] For the log information in the training log information set, data cleaning is mainly used to remove useless information contained in the log information. For example, the anomaly classification device can remove special symbols (such as '#', '<', '>', '&', '@', '!', '(', ')', '*', '_', etc.) in the log information. For another example, the anomaly classification device can remove format information (such as digital format, English format, etc.) in the log information. For another example, the anomaly classification device can remove stop words (such as 'is', 'not', 'this', 'the', 'do', 'in', etc.) in the log information. It should be clear that if the format of the log information is inconsistent, the anomaly classification device needs to clean the log information of different formats separately.

[0087] s13, data balancing s13

[0088] Because the exception classification device determines the log information generated when the server generates an exception based on the work order information. When the order information of different categories is inconsistent in magnitude, that is, when the number of various exception types corresponding to the log information is very different, the exception classification results of the target classification model will be biased towards the larger number of exception types. Considering the imbalance in the number of various exception types, the smaller number of exception types can be divided into one category (such as other categories). Figure 5As shown in the figure, the server's abnormal types can include nine types of abnormal types, including switch failure, sudden failure, motherboard failure, network card failure, human factors, disk array card failure, kernel-related failure, processor failure, and memory failure. The number of switch failure and sudden failure is 1, the number of motherboard failure and network card failure is 2, and the number of human factors and disk array card failure is 3. The number of these abnormal types is relatively small, and the six abnormal types of switch failure, sudden failure, motherboard failure, network card failure, human factors, and disk array card failure can be classified into one category. However, the number of kernel-related failures is 15, the number of processor failures is 20, and the number of memory failures is 85. The number of these abnormal types is relatively large, and the kernel-related failures can be classified as the second category, the processor failure as the third category, and the memory failure as the fourth category. The nine-classification problem is transformed into a four-classification problem. When the number of work order information is unbalanced or the number of abnormal types is particularly large, the method of classifying a small number of abnormal types into one category can make the target classification model have strong randomness.

[0089] In some embodiments, the abnormal classification device also needs to perform text segmentation on the log information. The abnormal classification device can perform text segmentation on the log information based on a dictionary segmentation algorithm (such as a forward maximum matching method, a reverse maximum matching method, and a two-way matching segmentation method, etc.), or can also perform text segmentation on the log information based on a statistical machine learning algorithm (such as a hidden Markov model, a conditional random field model, a SVM algorithm, a deep learning algorithm, etc.). The embodiment of the present invention does not limit this.

[0090] It should be understood that in order to ensure that the formats of the log sample set used for training and the log sample set used for testing are unified, the abnormal classification device also needs to preprocess the log information in the test log information set to obtain the log sample set used for testing, and the method by which the abnormal classification device preprocesses the log information in the test log information set is the same as the method by which the abnormal classification device preprocesses the log information in the training log information set. The specific implementation of the abnormal classification device preprocessing the test log information can refer to steps s11-s13. No further details will be given here.

[0091] S302 , obtaining a log sample set, and performing vector conversion on each log sample in the log sample set to determine a sample vector corresponding to each log sample in the log sample set.

[0092] The log samples in the log sample set are usually text type. When building the target classification model, the text type log samples need to be converted into sample vectors of numerical type corresponding to each log sample. The log sample set includes a log sample set for training or a log sample set for testing.

[0093] Optionally, the sample vector of the log sample can be obtained by manual labeling. Optionally, the log sample can be converted into a sample vector by a weight calculation method. The weight calculation method may include any one or more of the following: Boolean weight (Boolean vector) method, frequency weight method (Term frequence) and term frequency-inverse document frequency method (Term Frequency-Inverse Document Frequency, Tf-idf).

[0094] Among them, the Boolean weight method is the simplest weight calculation method. If a feature word appears in a log sample, its weight is 1; if a feature word does not appear in a log sample, its weight is 0. This method is prone to losing internal information of the log sample and the effect is slightly worse. However, it is suitable for some models that use binary classification, such as decision trees or probabilistic classifiers.

[0095] Among them, the frequency weight method is the most intuitive weight calculation method. The number of times a feature word appears in a log sample is the frequency weight. The idea of ​​this method is that the more times a feature word appears, the greater its importance. Specifically, the frequency weight method can be represented by the following expression:

[0096] Word frequency = the number of times a feature word appears in a log sample

[0097] Among them, the word frequency-inverse file frequency method is the most widely used weight calculation method. The more times a feature word appears in a log sample and the fewer times it appears in a log sample set, the more this feature word can represent the anomaly type. The main idea is that if the number of log samples containing feature word t is smaller and the inverse file frequency is larger, it means that feature word t has a good type distinction ability. The word frequency-inverse file frequency method can be represented by the following expression:

[0098]

[0099] Word frequency = the number of times a feature word appears in a log sample

[0100] Word frequency - inverse file frequency = word frequency * inverse file frequency

[0101] In one embodiment, the word frequency-inverse document frequency method can be used for text vectorization, 12 regularization can be selected, and feature selection is performed in combination with document frequency (df) and maximum word frequency (tf) to select feature words of log samples.

[0102] It should be understood that for some smaller types of exceptions, expert knowledge can be used to analyze the log information corresponding to the existing work order information, manually extract feature words from it, and write corresponding modules to achieve automatic classification.

[0103] S303, classifying the log sample set according to the sample vector corresponding to each log sample to obtain log sample subsets under different categories, wherein the sample vector corresponding to the log sample in the log sample subset under one category corresponds to a category to be selected.

[0104] The target classification model is constructed by using an anomaly classification algorithm, and parameters are continuously tuned during the construction process to construct the optimal target classification model. Specifically, the anomaly classification device can use the initial classification model to classify the sample vector corresponding to each log sample in the log sample set, obtain log sample subsets of different categories, and update the initial parameters of the initial classification model according to the classification results. After multiple updates, the target classification model can be trained. Among them, the sample vector corresponding to the log sample contained in the log sample subset of a category corresponds to a category to be selected.

[0105] The following uses the decision tree as an example to illustrate. Using the decision tree algorithm to train the log sample set, we can get the following Figure 6 The decision tree shown in Figure 2 is Figure 6 As shown, the decision tree includes a total of 11 nodes, including 5 non-leaf nodes and 6 leaf nodes. Figure 6 As shown in , non-leaf nodes can be represented by solid boxes, and leaf nodes can be represented by dotted boxes. A sample vector is [32, 41, 33]. After classification by the decision tree, 6 categories of log sample subsets can be obtained respectively.

[0106] It should be understood that in addition to being constructed by a decision tree algorithm, the target classification model can also be constructed by other machine learning algorithms. In some embodiments, anomaly classification can also be performed by combining a machine learning algorithm with expert rules. Specifically, an expert rule strategy layer can be added to the construction model to optimize the classification model and achieve a better classification effect.

[0107] Repeat step S303 and use at least two anomaly classification algorithms to train the log sample set to obtain at least two classification models.

[0108] S304: Use the log samples for testing to test the at least two target classification models respectively, and analyze the test results of each target classification model.

[0109] See also Figure 7 , Figure 7 The test results of the target classification model corresponding to each anomaly classification algorithm are shown. Figure 7It can be seen that the target classification model constructed by the DT algorithm has an accuracy of 98.94% in the log sample set used for training and an accuracy of 90.24% in the log sample set used for testing. The target classification model has good interpretability and good classification effect. The target classification model constructed by the Rocchio algorithm is relatively stable and has good classification effect, but it may misclassify processor faults as memory faults. The target classification model constructed by the XGBoost algorithm is competitive and has a good classification effect, but kernel-related faults may be misclassified as other faults, or processor faults may be misclassified as memory faults. The target classification model constructed by the NB algorithm is based on probability, with average classification effect, and the scope of application of this target classification model is small. The target classification model constructed by the LDA algorithm has good classification effect, but it is easy to overfit and easily misclassify abnormal types. The target classification model constructed by the SVM algorithm has excellent performance in other classification schemes, but the abnormal classification effect is poor. The target classification model constructed by the RF algorithm is relatively stable and has a good classification effect. However, it is easy to misclassify processor faults as memory faults. The target classification model constructed by the LR algorithm is the simplest and has a good classification effect. However, it is easy to mistake a processor failure for a memory failure.

[0110] The embodiment of the present invention can learn the log data that causes server abnormalities by using a machine learning method, filter out useless information in the log information, and build a machine learning classification model, i.e., a target classification model, through the feature words of the log information. When the accuracy of the abnormal classification of the target classification model is sufficiently accurate, it is possible to achieve automatic closing of the work order information corresponding to the target server without human intervention, automatically analyze the abnormalities of the target server, and accurately locate the abnormal type of the target server.

[0111] Based on the description of the above-mentioned abnormal classification method embodiment, the embodiment of the present invention further discloses an abnormal classification device, which can be a computer program (including program code) running in the above-mentioned abnormal classification device. Figure 2 or Figure 3 See the method shown in Figure 8 , the anomaly classification device may run the following units:

[0112] The acquisition unit 801 is used to acquire target log information generated by the target server when an exception occurs in response to a trigger operation of performing exception classification on the target server;

[0113] The acquisition unit 801 is further used to acquire at least two target classification models, wherein one target classification model uses an abnormality classification algorithm to perform abnormality classification on the target server;

[0114] The abnormality classification unit 802 is used to call each target classification model to perform abnormality classification on the target server according to the target log information, and obtain the abnormality classification result of each target classification model on the target server;

[0115] The determination unit 803 is used to determine the target abnormality type of the target server according to the abnormality classification result of each target classification model.

[0116] In one implementation, the abnormality classification unit 802 calls each target classification model to perform abnormality classification on the target server according to the target log information, and obtains the abnormality classification result of each target classification model on the target server, including:

[0117] Determine the vector expression corresponding to the target log information, and call each target classification model to perform abnormal classification on the vector expression corresponding to the target log information to determine the target category to which the vector expression belongs;

[0118] The abnormality type indicated by the target category is used as the abnormality classification result of each target classification model on the target server.

[0119] In another implementation manner, the vector expression includes multiple categories to be selected, and the determination unit 803 is further configured to determine the multiple categories to be selected, including:

[0120] A log sample set is obtained, and each log sample in the log sample set is vectorized to determine a sample vector corresponding to each log sample in the log sample set; the log samples included in the log sample set are obtained when an exception occurs in a server;

[0121] The log sample set is classified according to the sample vector corresponding to each log sample to obtain log sample subsets under different categories, wherein the sample vector corresponding to the log sample in the log sample subset under one category corresponds to a category to be selected.

[0122] In another embodiment, if each target classification model has different abnormal classification results for the target server, the determination unit 803 determines the target abnormality type of the target server according to the abnormal classification results of each target classification model, including:

[0123] An abnormality classification result of the target server by any target classification model is selected, and an abnormality type indicated by the selected abnormality classification result is used as a target abnormality result of the target server.

[0124] In another embodiment, if there are at least two target classification models that have the same abnormality classification results for the target server; the determination unit 803 determines the target abnormality type of the target server according to the abnormality classification results of each target classification model, including:

[0125] Determine the reference classification results with the largest number of the same abnormalities from the abnormal classification results of the target server by each target classification model;

[0126] The anomaly types indicated by the selected reference classification results with the largest number of the same number are used as the target anomaly results of the target server.

[0127] In another implementation manner, after determining the target exception type of the target server, the determining unit 803 is further configured to:

[0128] Using an association rule mining algorithm, determine the association relationship between the target log information and the target abnormality type, and store the association relationship;

[0129] The association relationship is used to indicate the probability that the target server is of a target abnormal type when the target server generates the target log information.

[0130] In another embodiment, after determining the target exception type of the target server, the determining unit 803 is further used to:

[0131] Determine whether there is an associated exception type related to the target exception type, wherein the associated exception type is an exception type generated according to the target exception after a target exception of the target exception type is generated;

[0132] If so, the associated abnormality type is used as the predicted abnormality type for the target server.

[0133] According to one embodiment of the present invention, Figure 2 or Figure 3 Each step involved in the method shown can be performed by Figure 8 The various units in the abnormal classification device shown are executed. For example, Figure 2 Steps S201 and S202 shown are Figure 8 The acquisition unit 801 shown in FIG. 8 is executed, and step S203 is performed by Figure 8 The abnormal classification unit 802 shown in FIG. 8 is used to perform step S204. Figure 8 Executed by the determination unit 803 shown in . Figure 3 Steps S301, S302, S303 and S304 are composed of Figure 8 The abnormality classification unit 802 shown in FIG.

[0134] According to another embodiment of the present invention, Figure 8 The various units in the abnormal classification device shown can be separately or completely combined into one or several other units to form, or one (some) of the units can be further divided into multiple functionally smaller units to form, which can achieve the same operation without affecting the realization of the technical effects of the embodiments of the present invention. The above-mentioned units are divided based on logical functions. In practical applications, the function of one unit can also be implemented by multiple units, or the functions of multiple units can be implemented by one unit. In other embodiments of the present invention, other units can also be included based on the abnormal classification device. In practical applications, these functions can also be implemented with the assistance of other units, and can be implemented by the collaboration of multiple units.

[0135] According to another embodiment of the present invention, the processing elements and storage elements including a central processing unit (CPU), a random access storage medium (RAM), a read-only storage medium (ROM), etc. can be used. For example, a general computing device such as a computer can be used to execute the following operations. Figure 2 or Figure 3 A computer program (including program code) for each step involved in the corresponding method shown in Figure 8 The abnormality classification device shown in the figure is used to implement the abnormality classification method of the embodiment of the present invention. The computer program can be recorded on a computer-readable recording medium, for example, and loaded into the abnormality classification device through the computer-readable recording medium and run therein.

[0136] In an embodiment of the present invention, in response to a trigger operation for classifying the target server for exceptions, the acquisition unit 801 can obtain the target log information generated by the target server when an exception occurs and use an exception classification algorithm to train multiple target classification models; then the exception classification unit 802 can call multiple target classification models to classify the target server for exceptions according to the target log information, and then the determination unit 803 can determine the exception type of the target server according to the exception classification results of each target classification model. Since the target server is classified for exceptions to achieve the abnormal location of the target server based on the log information is completed based on the target classification model constructed by the machine learning algorithm, there is no need for analysts to analyze the target log information of the target server one by one, which can reduce manual operations, greatly reduce labor costs and time costs, effectively save human resources, and improve the efficiency of exception classification. In addition, the embodiment of the present invention constructs a target classification model through text vectorization and machine learning algorithms to classify the target server for exceptions, which can identify different types of exceptions and has a high accuracy rate of identification. In addition, since the embodiment of the present invention utilizes at least two target classification models to classify the target server as abnormal according to the target log information, adopts a multi-model fusion strategy, and uses a voting mechanism to determine the abnormal type of the target server from the abnormal classification results of multiple target classification models, it avoids the defects of a single classification model and can further ensure the accuracy of server abnormality classification.

[0137] Based on the description of the above-mentioned abnormal classification method embodiment, the present invention also discloses an abnormal classification device. Fig. 9 The abnormal classification device at least includes a processor 901, an input interface 902, an output interface 903 and a computer storage medium 904 which can be connected via a bus or other means.

[0138] The computer storage medium 904 is a memory device in the abnormal classification device, which is used to store programs and data. It is understandable that the computer storage medium 904 here can include both the built-in storage medium of the abnormal classification device and the extended storage medium supported by the abnormal classification device. The computer storage medium 904 provides a storage space, which stores the operating system of the abnormal classification device. In addition, one or more instructions suitable for being loaded and executed by the processor 901 are also stored in the storage space, and these instructions can be one or more computer programs (including program codes). It should be noted that the computer storage medium here can be a high-speed RAM memory; optionally, it can also be at least one computer storage medium away from the aforementioned processor, and the processor can be called a central processing unit (Central Processing Unit, CPU), which is the core and control center of the abnormal classification device, suitable for implementing one or more instructions, specifically loading and executing one or more instructions to realize the corresponding method flow or function.

[0139] In one embodiment, the processor 901 may load and execute one or more instructions stored in the computer storage medium 904 to implement the following operations: Figure 2 or Figure 3 In the specific implementation, one or more instructions in the computer storage medium 904 are loaded by the processor 901 and the following steps are executed:

[0140] In response to a trigger operation of performing abnormal classification on a target server, obtaining target log information generated by the target server when an abnormality is generated;

[0141] Acquire at least two target classification models, wherein one target classification model uses an anomaly classification algorithm to perform anomaly classification on the target server;

[0142] Calling each target classification model to perform abnormal classification on the target server according to the target log information, and obtaining an abnormal classification result of each target classification model on the target server;

[0143] According to the abnormal classification result of each target classification model, the target abnormal type of the target server is determined.

[0144] In another implementation manner, the processor 901 calls each target classification model to perform abnormal classification on the target server according to the target log information, and obtains the abnormal classification result of each target classification model on the target server, including:

[0145] Determine the vector expression corresponding to the target log information, and call each target classification model to perform abnormal classification on the vector expression corresponding to the target log information to determine the target category to which the vector expression belongs;

[0146] The abnormality type indicated by the target category is used as the abnormality classification result of each target classification model on the target server.

[0147] In another embodiment, the vector expression includes multiple categories to be selected; the processor 901 determines that the multiple categories to be selected include:

[0148] A log sample set is obtained, and each log sample in the log sample set is vectorized to determine a sample vector corresponding to each log sample in the log sample set; the log samples included in the log sample set are obtained when an exception occurs in a server;

[0149] The log sample set is classified according to the sample vector corresponding to each log sample to obtain log sample subsets under different categories, wherein the sample vector corresponding to the log sample in the log sample subset under one category corresponds to a category to be selected.

[0150] In another implementation manner, if each target classification model has different abnormal classification results for the target server, the processor 901 determines the target abnormality type of the target server according to the abnormal classification results of each target classification model, including:

[0151] An abnormality classification result of the target server by any target classification model is selected, and an abnormality type indicated by the selected abnormality classification result is used as a target abnormality result of the target server.

[0152] In another embodiment, if there are at least two target classification models that have the same abnormal classification results for the target server; the processor 901 determines the target abnormality type of the target server according to the abnormal classification results of each target classification model, including:

[0153] Determine the reference classification results with the largest number of the same abnormalities from the abnormal classification results of the target server by each target classification model;

[0154] The anomaly types indicated by the selected reference classification results with the largest number of the same number are used as the target anomaly results of the target server.

[0155] In yet another implementation manner, the processor 901 is further configured to:

[0156] Using an association rule mining algorithm, determine the association relationship between the target log information and the target abnormality type, and store the association relationship;

[0157] The association relationship is used to indicate the probability that the target server is of a target abnormal type when the target server generates the target log information.

[0158] In yet another implementation manner, the processor 901 is further configured to:

[0159] Determine whether there is an associated exception type related to the target exception type, wherein the associated exception type is an exception type generated according to the target exception after a target exception of the target exception type is generated;

[0160] If so, the associated abnormality type is used as the predicted abnormality type for the target server.

[0161] In an embodiment of the present invention, the abnormal classification device responds to the trigger operation of abnormal classification of the target server, obtains the target log information generated by the target server when the abnormality is generated, and uses the abnormal classification algorithm to train to obtain multiple target classification models; then calls multiple target classification models to perform abnormal classification on the target server according to the target log information. Since the abnormal classification of the target server is completed based on the target classification model constructed by the machine learning algorithm, the analyst does not need to analyze the target log information of the target server one by one, which can reduce manual operation, greatly reduce the labor cost and time cost, effectively save human resources, and improve the efficiency of abnormal classification. In addition, the embodiment of the present invention constructs a target classification model through text vectorization and machine learning algorithm to perform abnormal classification on the target server, which can identify different abnormal types and has a high recognition accuracy. In addition, since the embodiment of the present invention uses at least two target classification models to perform abnormal classification on the target server according to the target log information, a multi-model fusion strategy is adopted, and the abnormal type of the target server is determined from the abnormal classification results of multiple target classification models by a voting mechanism, the defects of a single classification model are avoided, and the accuracy of server abnormal classification can be further guaranteed.

[0162] It should be noted that an embodiment of the present invention further provides a computer program product or a computer program, the computer program product or the computer program including computer instructions, the computer instructions being stored in a computer-readable storage medium. The processor of the anomaly classification device reads the computer instructions from the computer-readable storage medium, and the processor executes the computer instructions, so that the anomaly classification device performs the above-mentioned anomaly classification method embodiment. Figure 2 or Figure 3 The steps performed in

[0163] What is disclosed above is only a preferred embodiment of the present invention, and it certainly cannot be used to limit the scope of rights of the present invention. Ordinary technicians in this field can understand that all or part of the processes of the above embodiment and equivalent changes made according to the claims of the present invention still fall within the scope of the invention.

Claims

1. A method for abnormal classification, characterized in that: include: In response to a trigger operation of performing abnormal classification on a target server, obtaining target log information generated by the target server when an abnormality is generated; Acquire at least two target classification models, wherein one target classification model uses an anomaly classification algorithm to perform anomaly classification on the target server; Calling each target classification model to perform abnormal classification on the target server according to the target log information, and obtaining an abnormal classification result of each target classification model on the target server; Determining a target abnormality type of the target server according to an abnormality classification result of each target classification model; Wherein, after determining the target exception type of the target server, the method further includes: Determine whether there is an associated exception type related to the target exception type, wherein the associated exception type is an exception type generated according to the target exception after a target exception of the target exception type is generated; If so, the associated abnormality type is used as the predicted abnormality type for the target server.

2. The method according to claim 1, characterized in that The calling of each target classification model to perform abnormal classification on the target server according to the target log information to obtain the abnormal classification result of the target server by each target classification model includes: Determine the vector expression corresponding to the target log information, and call each target classification model to perform abnormal classification on the vector expression corresponding to the target log information to determine the target category to which the vector expression belongs; The abnormality type indicated by the target category is used as the abnormality classification result of each target classification model on the target server.

3. The method according to claim 2, characterized in that The vector expression includes a plurality of categories to be selected; and the method for determining the plurality of categories to be selected includes: A log sample set is obtained, and each log sample in the log sample set is vectorized to determine a sample vector corresponding to each log sample in the log sample set; the log sample in the log sample set is obtained when an exception occurs in a server; The log sample set is classified according to the sample vector corresponding to each log sample to obtain log sample subsets under different categories, wherein the sample vector corresponding to the log sample in the log sample subset under one category corresponds to a category to be selected.

4. The method according to claim 1, characterized in that: If the abnormal classification results of each target classification model for the target server are different; determining the target abnormality type of the target server according to the abnormal classification results of each target classification model includes: An abnormality classification result of the target server by any target classification model is selected, and an abnormality type indicated by the selected abnormality classification result is used as a target abnormality result of the target server.

5. The method according to claim 1, characterized in that If there are at least two target classification models that have the same abnormality classification results for the target server; determining the target abnormality type of the target server according to the abnormality classification results of each target classification model includes: Determine the reference classification results with the largest number of the same abnormalities from the abnormal classification results of the target server by each target classification model; The anomaly types indicated by the selected reference classification results with the largest number of the same number are used as the target anomaly results of the target server.

6. The method according to claim 1, characterized in that After determining the target exception type of the target server, the method further includes: Using an association rule mining algorithm, determine the association relationship between the target log information and the target abnormality type, and store the association relationship; The association relationship is used to indicate the probability that the target server is of a target abnormal type when the target server generates the target log information.

7. An abnormal classification device, characterized in that: The device comprises: An acquisition unit, configured to, in response to a trigger operation for classifying an exception on a target server, acquire target log information generated by the target server when an exception occurs; The acquisition unit is further used to acquire at least two target classification models, wherein one target classification model uses an abnormality classification algorithm to perform abnormality classification on the target server; an abnormality classification unit, used for calling each target classification model to perform abnormality classification on the target server according to the target log information, and obtaining an abnormality classification result of each target classification model on the target server; A determination unit, configured to determine a target abnormality type of the target server according to an abnormality classification result of each target classification model; Among them, the determination unit, after determining the target exception type of the target server, is also used to determine whether there is an associated exception type related to the target exception type, wherein the associated exception type is an exception type generated according to the target exception after the target exception of the target exception type is generated; if so, the associated exception type is used as the predicted exception type for the target server.

8. An abnormal classification device, comprising an input interface and an output interface, characterized in that: Also includes: a processor adapted to implement one or more instructions; as well as, A computer storage medium storing one or more instructions, wherein the one or more instructions are suitable for being loaded by the processor and executing the anomaly classification method as described in any one of claims 1 to 6.

9. A computer storage medium, characterized in that The computer storage medium stores one or more instructions, and the one or more instructions are suitable for being loaded by a processor and executing the anomaly classification method as described in any one of claims 1-6.

10. A computer program product comprising a computer program / instructions, characterized in that When the computer program / instructions are executed by a processor, the steps of the anomaly classification method according to any one of claims 1 to 6 are implemented.