WO2022095637A1 - 一种故障日志分类方法、系统、设备以及介质 - Google Patents

一种故障日志分类方法、系统、设备以及介质 Download PDF

Info

Publication number
WO2022095637A1
WO2022095637A1 PCT/CN2021/121437 CN2021121437W WO2022095637A1 WO 2022095637 A1 WO2022095637 A1 WO 2022095637A1 CN 2021121437 W CN2021121437 W CN 2021121437W WO 2022095637 A1 WO2022095637 A1 WO 2022095637A1
Authority
WO
WIPO (PCT)
Prior art keywords
classified
vocabulary
fault
phrase
phrases
Prior art date
Application number
PCT/CN2021/121437
Other languages
English (en)
French (fr)
Inventor
孙雅伦
张芳
Original Assignee
苏州浪潮智能科技有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 苏州浪潮智能科技有限公司 filed Critical 苏州浪潮智能科技有限公司
Priority to US18/033,779 priority Critical patent/US20230401121A1/en
Publication of WO2022095637A1 publication Critical patent/WO2022095637A1/zh

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/07Responding to the occurrence of a fault, e.g. fault tolerance
    • G06F11/0703Error or fault processing not based on redundancy, i.e. by taking additional measures to deal with the error or fault not making use of redundancy in operation, in hardware, or in data representation
    • G06F11/0766Error or fault reporting or storing
    • G06F11/0787Storage of error reports, e.g. persistent data storage, storage using memory protection
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F16/00Information retrieval; Database structures therefor; File system structures therefor
    • G06F16/30Information retrieval; Database structures therefor; File system structures therefor of unstructured textual data
    • G06F16/35Clustering; Classification
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/22Detection or location of defective computer hardware by testing during standby operation or during idle time, e.g. start-up testing
    • G06F11/2257Detection or location of defective computer hardware by testing during standby operation or during idle time, e.g. start-up testing using expert systems
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F40/00Handling natural language data
    • G06F40/20Natural language analysis
    • G06F40/205Parsing
    • G06F40/216Parsing using statistical methods
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F40/00Handling natural language data
    • G06F40/20Natural language analysis
    • G06F40/279Recognition of textual entities
    • G06F40/284Lexical analysis, e.g. tokenisation or collocates

Definitions

  • the present application relates to the field of log processing, and in particular, to a fault log classification method, system, device, and storage medium.
  • an embodiment of the present application proposes a fault log classification method, including the following steps:
  • it also includes:
  • a corpus is formed based on the plurality of phrases of each historical fault log.
  • it also includes:
  • phrases whose word frequency is greater than the threshold are updated to the waste word database, and the weight of the phrases whose word frequency is not greater than the threshold is calculated according to the word frequency and the reverse word frequency.
  • receiving a fault log to be classified further comprising:
  • the corresponding phrases in the fault log to be classified are deleted according to the waste vocabulary.
  • determining a plurality of segmentation positions corresponding to the fault log to be classified according to the phrases containing the most vocabulary in the preset corpus further comprising:
  • it also includes:
  • the first M-1 words of the fault log to be classified are After the vocabulary is cut, return to judge whether the phrase formed by the current first vocabulary and the Mth vocabulary of the fault log to be classified after being cut can match the phrase in the corpus;
  • an embodiment of the present application further provides a fault log classification system, including:
  • a receiving module the receiving module is configured to receive the fault log to be classified, and according to the phrase containing the most vocabulary in the preset corpus, determine several division positions corresponding to the fault log to be classified;
  • the segmentation module is configured to segment the fault log to be classified according to the corresponding plurality of segmentation positions to obtain a plurality of phrases;
  • the screening module is configured to determine the weight of each phrase according to the corpus and screen out several phrases according to the weight;
  • a computing module the computing module is configured to calculate the number of phrases to be classified according to the weights and the number of phrases to be classified according to the weights of the classified failure logs. similarity between the classified fault logs, and then classify the fault logs to be classified according to the similarity.
  • an embodiment of the present application further provides a computer device, including:
  • a memory wherein the memory stores a computer program that can be executed on the processor, and is characterized in that, when the processor executes the program, the processor executes the steps of any one of the above-mentioned fault log classification methods.
  • an embodiment of the present application further provides a computer-readable storage medium, where the computer-readable storage medium stores a computer program, and when the computer program is executed by a processor Perform the steps of any of the fault log classification methods described above.
  • the present application has one of the following beneficial technical effects: by processing the English logs into the form of phrases and phrases, the solution proposed in the present application greatly reduces the vocabulary size of subsequent processing, reduces the dimension of characteristic phrases, and thus reduces the calculation amount of fault log classification .
  • FIG. 1 is a schematic flowchart of a fault log classification method provided by an embodiment of the present application.
  • FIG. 2 is a schematic structural diagram of a fault log classification system provided by an embodiment of the present application.
  • FIG. 3 is a schematic structural diagram of a computer device provided by an embodiment of the present application.
  • FIG. 4 is a schematic structural diagram of a computer-readable storage medium provided by an embodiment of the present application.
  • an embodiment of the present application proposes a fault log classification method, as shown in FIG. 1 , which may include the steps:
  • the solution proposed in the present application greatly reduces the vocabulary size of subsequent processing, reduces the dimension of characteristic phrases, and thus reduces the calculation amount of fault log classification by processing English logs into the form of phrases and phrases.
  • it also includes:
  • a corpus is formed based on the plurality of phrases of each historical fault log.
  • the corpus can be obtained by summarizing the meaningful phrases or phrases in the log by the user, and the corpus can be assumed to be "sufficiently large", which includes a set of phrases and phrases in all error log texts.
  • it also includes:
  • phrases whose word frequency is greater than the threshold are updated to the waste word database, and the weight of the phrases whose word frequency is not greater than the threshold is calculated according to the word frequency and the reverse word frequency.
  • the TFIDF algorithm can be used to calculate the word frequency and the reverse word frequency, and the calculation formula can be as follows:
  • Word frequency calculation formula The number of occurrences of a word is compared with the total number of words in the document.
  • N represents the total number of texts in the corpus
  • N(x) represents the total number of texts in the corpus that contain word x.
  • the waste word database is updated according to the word frequency.
  • the weights of the remaining word frequencies not greater than the threshold can be obtained by multiplying the word frequency and the reverse word frequency. Then use the weights and phrases to get the bag-of-words model, which is a two-dimensional table, the rows represent all the phrases and phrases contained in the corpus, the columns represent the unit log of the corpus, and a single element in the bag-of-words model is a certain phrase and phrase for the log. the weight of.
  • both the trash word database and the corpus can be updated. For example, after the trash word database and corpus are obtained by using multiple historical fault logs, after receiving a new failure log, multiple new failure logs can be used. The fault log of the rubbish thesaurus and corpus are updated.
  • receiving a fault log to be classified further comprising:
  • the corresponding phrases in the fault log to be classified are deleted according to the waste vocabulary.
  • the log data package after receiving the log data package, it can be classified according to the server and device modules (BIOS module, BMC module), pre-read the log data, and process the log text content: delete meaningless characters such as symbols and special characters, and restore vocabulary.
  • the basic form of vocabulary is obtained by state change, abbreviations are expanded, stop words are removed, root words are extracted, such as the words leave, leafed, leafs and leafing, and the log format of each module is unified.
  • the phrases in the waste vocabulary some phrases that appear repeatedly but provide insufficient information are deleted, so that they are deleted before feature extraction, which can reduce the amount of data processing.
  • the user can set log reporting parameters in the system, the data collection module master of the management end issues commands to the slaves of each server, and the slaves report error logs to the management end.
  • Slave is software running in the managed server host, and actively reports log data containing error information. Slave has a filtering function to filter out normal operation logs and reduce the amount of subsequent processing data.
  • the user can set the slave reporting function through the interactive page: whether to report immediately, the reporting time period, the modules included in the reporting log, and the level of the reporting log.
  • the second part is the master running on the server management side, which issues commands to the slave, receives the log data reported by the slave, and packages the data back to the system.
  • determining a plurality of segmentation positions corresponding to the fault log to be classified according to the phrases containing the most vocabulary in the preset corpus further comprising:
  • it also includes:
  • the first M-1 words of the fault log to be classified are After the vocabulary is cut, return to judge whether the phrase formed by the current first vocabulary and the Mth vocabulary of the fault log to be classified after being cut can match the phrase in the corpus;
  • the number of words in the corpus that contains the most words is M.
  • M the number of words in the corpus that contains the most words.
  • a. First, cut the M words after the "current position" as matching items.
  • b. If the match is successful, the "current position” will be jumped to the split position, and the remaining text will be matched in sequence.
  • c. If the match fails, segment M-1 words after "current position” as matching items.
  • step b If the match is successful, perform step b, if the match fails, perform step c until all texts are matched.
  • e Output text composed of several phrases.
  • the first segmentation position is between c and d, and then judge whether a b c can match the phrases in the corpus, and if so, then Take d as the current first vocabulary, the second split position is between f and g, and then judge whether de f can match the phrases in the corpus, if not, judge whether de e can match the words in the corpus Phrase matching, if it can match, the remaining text after splitting again is f g. If it cannot match, it is judged whether d can match the phrase in the corpus. If it can match, the remaining text after splitting again is e f g.
  • each phrase in the corpus contains at least one vocabulary, and if the phrase in the corpus cannot match all the words or phrases in the newly received fault log, the corpus needs to be updated according to the received new fault log. to update.
  • each classified fault log corresponds to a bag-of-words model, including the weights corresponding to all the phrases, and then several items with the largest weights are selected to form the keyword group of the log data.
  • all the keyword groups corresponding to the classified fault log and the keyword group corresponding to the fault log to be classified are deduplicated, and then all the remaining keyword groups t 1 , t 2 , ...t i is regarded as an n-dimensional coordinate system, and then each log is represented as a vector in an n-dimensional space, and the vector data structure is expressed as: ⁇ D i :[w 1 ,w 2 ,... wi ] ⁇ .
  • the similarity between the vectors is then calculated to classify the fault logs to be classified.
  • the keyword groups of the fault logs to be classified are a, b, c, d, and e
  • the keyword groups of the classified logs are a, b, c, a, c, f, c, e, g, respectively.
  • All keyword groups obtained after removing duplicates are a, b, c, d, e, f, g, so that the vector corresponding to the fault log to be classified is (1,1,1,1,1,0,0) , the vectors corresponding to the classified logs are (1,1,1,0,0,0,0), (1,0,1,0,0,1,0), (0,0,1,0, 1,0,1), that is, the dimension of the vector is the same as all the keyword groups obtained after removing duplicates. If the log includes the corresponding keyword group, the corresponding element value in the vector is 1, otherwise it is 0. It should be noted that the eigenvalues corresponding to elements in the same position of all vectors are the same.
  • the solution proposed in this application greatly reduces the number of elements in the corpus by processing English logs into the form of phrases and phrases, thereby simplifying the bag-of-words model and reducing the dimension of log feature vectors, thereby simplifying the bag-of-words model and reducing the dimension of log feature vectors.
  • an embodiment of the present application further provides a fault log classification system 400, as shown in FIG. 2, including:
  • a receiving module 401 the receiving module 401 is configured to receive a fault log to be classified, and determine a number of segmentation positions corresponding to the fault log to be classified according to the phrases containing the most vocabulary in the preset corpus;
  • a segmentation module 402 the segmentation module 402 is configured to segment the fault log to be classified according to the corresponding plurality of segmentation positions to obtain a plurality of phrases;
  • Screening module 403, the screening module 403 is configured to determine the weight of each phrase according to the corpus and filter out several phrases according to the weight;
  • Calculation module 404 the calculation module 404 is configured to calculate the to-be-classified fault log and the to-be-classified fault log with several phrases screened out according to the weight by using several classified fault logs. The similarity between each classified fault log, and then the fault log to be classified is classified according to the similarity.
  • an embodiment of the present application further provides a computer device 501, including:
  • the memory 510 stores a computer program 511 that can be executed on the processor, and the processor 520 executes the steps of any of the above fault log classification methods when executing the program.
  • an embodiment of the present application further provides a computer-readable storage medium 601, where the computer-readable storage medium 601 stores computer program instructions 610, and the computer The program instructions 610, when executed by the processor, perform the steps of any of the above fault log classification methods.
  • computer-readable storage media e.g. memory
  • volatile memory e.g., memory
  • non-volatile memory e.g., RAM

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Quality & Reliability (AREA)
  • Artificial Intelligence (AREA)
  • Health & Medical Sciences (AREA)
  • Audiology, Speech & Language Pathology (AREA)
  • Computational Linguistics (AREA)
  • General Health & Medical Sciences (AREA)
  • Computer Hardware Design (AREA)
  • Data Mining & Analysis (AREA)
  • Databases & Information Systems (AREA)
  • Probability & Statistics with Applications (AREA)
  • Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
  • Debugging And Monitoring (AREA)

Abstract

一种故障日志分类方法,包括以下步骤:接收待分类的故障日志,并根据预设的语料库中的包含最多词汇的短语确定待分类的故障日志对应的若干个分割位置(S1);根据对应的若干个分割位置对待分类的故障日志进行分割以得到多个词组(S2);根据语料库确定每一个词组的权重并根据权重筛选出若干个词组(S3);利用若干个已分类的故障日志根据权重筛选出的若干个词组和待分类的故障日志根据权重筛选出的若干个词组计算待分类的故障日志与每一个已分类的故障日志之间的相似度,进而根据相似度对待分类的故障日志分类(S4)。还公开了一种系统、计算机设备以及可读存储介质。上述方案通过将英文日志处理成词组、短语的形式,大大降低后续处理的词汇量。

Description

一种故障日志分类方法、系统、设备以及介质
本申请要求在2020年11月6日提交中国专利局、申请号为202011231058.9、发明名称为“一种故障日志分类方法、系统、设备以及介质”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
技术领域
本申请涉及日志处理领域,具体涉及一种故障日志分类方法、系统、设备以及存储介质。
背景技术
在服务器监控技术中,通过服务器日常运行日志分析预测定位故障是非常常见并且有效的方案,日志文件提供了海量的信息,由此应运而生众多算法,例如通过分析日志文本,提取文本特征,建立文本特征模型,从而对文本进行分类是目前比较常用的技术方案。但是由于服务器日志数据是英文,英文文本中每个词汇都有空格,使用文本特征提取的方案提取每一个关键词汇,会导致数据量过大,特征向量维度过高,计算量大。
发明内容
有鉴于此,为了克服上述问题的至少一个方面,本申请实施例提出一种故障日志分类方法,包括以下步骤:
接收待分类的故障日志,并根据预设的语料库中的包含最多词汇的短语确定所述待分类的故障日志对应的若干个分割位置;
根据对应的所述若干个分割位置对所述待分类的故障日志进行分割以得到多个词组;
根据所述语料库确定每一个词组的权重并根据权重筛选出若干个词组;
利用若干个已分类的故障日志根据权重筛选出的若干个词组和待分类的故障日志根据权重筛选出的若干个词组计算所述待分类的故障日志与每一个已分类的故障日志之间的相似度,进而根据所述相似度对所述待分类的故障日志分类。
在一些实施例中,还包括:
获取多个历史故障日志并从每一个所述历史故障日志中筛选出多个词组;
基于所述每一个历史故障日志的多个词组构成语料库。
在一些实施例中,还包括:
计算所述语料库中的每一个词组的词频和逆向词频;
将词频大于阈值的词组更新到废词库,并根据词频和逆向词频计算词频不大于阈值的词组的权重。
在一些实施例中,接收待分类的故障日志,进一步包括:
根据所述废词库将所述待分类的故障日志中相应的词组删除。
在一些实施例中,根据预设的语料库中的包含最多词汇的短语确定所述待分类的故障日志对应的若干个分割位置,进一步包括:
根据所述包含最多词汇的短语的词汇数量确定分割步长M;
判断所述待分类的故障日志的当前的第一个词汇与第M个词汇组成的词组是否能够与所述语料库中的词组匹配;
响应于所述待分类的故障日志的当前的第一个词汇与第M个词汇组成的词组能够与所述语料库中的词组匹配,将所述待分类的故障日志的前M个词汇切割后,返回判断切割后的所述待分类的故障日志的当前的第一个词汇与第M个词汇组成的词组是否能够与所述语料库中的词组匹配。
在一些实施例中,还包括:
响应于所述待分类的故障日志的当前的第一个词汇与第M个词汇组成 的词组不能够与所述语料库中的词组匹配,判断所述待分类的故障日志的当前的第一个词汇与第M-1个词汇组成的词组是否能够与所述语料库中的词组匹配;
响应于所述待分类的故障日志的当前的第一个词汇与第M-1个词汇组成的词组能够与所述语料库中的词组匹配,将所述待分类的故障日志的前M-1个词汇切割后,返回判断切割后的所述待分类的故障日志的当前的第一个词汇与第M个词汇组成的词组是否能够与所述语料库中的词组匹配;
响应于所述待分类的故障日志的当前的第一个词汇与第M-1个词汇组成的词组不能够与所述语料库中的词组匹配,判断所述待分类的故障日志的当前的第一个词汇与第M-N个词汇组成的词组是否能够与所述语料库中的词组匹配,其中,N为迭代次数;
响应于所述待分类的故障日志的当前的第一个词汇与第M-N个词汇组成的词组能够与所述语料库中的词组匹配,将所述待分类的故障日志的前M-N个词汇切割后,返回判断切割后的所述待分类的故障日志的当前的第一个词汇与第M个词汇组成的词组是否能够与所述语料库中的词组匹配。
在一些实施例中,利用若干个已分类的故障日志根据权重筛选出的若干个词组和待分类的故障日志根据权重筛选出的若干个词组计算所述待分类的故障日志与每一个已分类的故障日志之间的相似度,进一步包括:
根据若干个已分类的故障日志根据权重筛选出的若干个词组和待分类的故障日志根据权重筛选出的若干个词组得到所述每一个已分类的故障日志的特征向量和所述待分类的故障日志的特征向量;
计算所述每一个已分类的故障日志对应的特征向量与所述待分类的故障日志对应的特征向量之间的相似度。
基于同一发明构思,根据本申请的另一个方面,本申请的实施例还提供了一种故障日志分类系统,包括:
接收模块,所述接收模块配置为接收待分类的故障日志,并根据预设的语料库中的包含最多词汇的短语确定所述待分类的故障日志对应的若干个 分割位置;
分割模块,所述分割模块配置为根据对应的所述若干个分割位置对所述待分类的故障日志进行分割以得到多个词组;
筛选模块,所述筛选模块配置为根据所述语料库确定每一个词组的权重并根据权重筛选出若干个词组;
计算模块,所述计算模块配置为利用若干个已分类的故障日志根据权重筛选出的若干个词组和待分类的故障日志根据权重筛选出的若干个词组计算所述待分类的故障日志与每一个已分类的故障日志之间的相似度,进而根据所述相似度对所述待分类的故障日志分类。
基于同一发明构思,根据本申请的另一个方面,本申请的实施例还提供了一种计算机设备,包括:
至少一个处理器;以及
存储器,所述存储器存储有可在所述处理器上运行的计算机程序,其特征在于,所述处理器执行所述程序时执行如上所述的任一种故障日志分类方法的步骤。
基于同一发明构思,根据本申请的另一个方面,本申请的实施例还提供了一种计算机可读存储介质,所述计算机可读存储介质存储有计算机程序,所述计算机程序被处理器执行时执行如上所述的任一种故障日志分类方法的步骤。
本申请具有以下有益技术效果之一:本申请提出方案通过将英文日志处理成词组、短语的形式,大大降低后续处理的词汇量,降低了特征词组的维度,从而降低了故障日志分类的计算量。
附图说明
为了更清楚地说明本申请实施例或现有技术中的技术方案,下面将对实施例或现有技术描述中所需要使用的附图作简单地介绍,显而易见地,下面描述中的附图仅仅是本申请的一些实施例,对于本领域普通技术人员来 讲,在不付出创造性劳动的前提下,还可以根据这些附图获得其他的实施例。
图1为本申请的实施例提供的故障日志分类方法的流程示意图;
图2为本申请的实施例提供的故障日志分类系统的结构示意图;
图3为本申请的实施例提供的计算机设备的结构示意图;
图4为本申请的实施例提供的计算机可读存储介质的结构示意图。
具体实施方式
为使本申请的目的、技术方案和优点更加清楚明白,以下结合具体实施例,并参照附图,对本申请实施例进一步详细说明。
需要说明的是,本申请实施例中所有使用“第一”和“第二”的表述均是为了区分两个相同名称非相同的实体或者非相同的参量,可见“第一”“第二”仅为了表述的方便,不应理解为对本申请实施例的限定,后续实施例对此不再一一说明。
根据本申请的一个方面,本申请的实施例提出一种故障日志分类方法,如图1所示,其可以包括步骤:
S1,接收待分类的故障日志,并根据预设的语料库中的包含最多词汇的短语确定所述待分类的故障日志对应的若干个分割位置;
S2,根据对应的所述若干个分割位置对所述待分类的故障日志进行分割以得到多个词组;
S3,根据所述语料库确定每一个词组的权重并根据权重筛选出若干个词组;
S4,利用若干个已分类的故障日志根据权重筛选出的若干个词组和待分类的故障日志根据权重筛选出的若干个词组计算所述待分类的故障日志与每一个已分类的故障日志之间的相似度,进而根据所述相似度对所述待分类的故障日志分类。
本申请提出方案通过将英文日志处理成词组、短语的形式,大大降低后 续处理的词汇量,降低了特征词组的维度,从而降低了故障日志分类的计算量。
在一些实施例中,还包括:
获取多个历史故障日志并从每一个所述历史故障日志中筛选出多个词组;
基于所述每一个历史故障日志的多个词组构成语料库。
具体的,语料库可以通过用户对日志中有意义的词组或短语进行汇总得到,该语料库可以假设“充分大”,其包含了所有错误日志文本中的词组、短语集合。
在一些实施例中,还包括:
计算所述语料库中的每一个词组的词频和逆向词频;
将词频大于阈值的词组更新到废词库,并根据词频和逆向词频计算词频不大于阈值的词组的权重。
具体的,可以利用TFIDF算法计算词频和逆向词频,其计算公式可以如下:
词频计算公式:某词汇出现次数与文档总词数相比。
Figure PCTCN2021121437-appb-000001
逆向词频计算公式如下:
Figure PCTCN2021121437-appb-000002
其中,N代表语料库文本的总数,而N(x)代表语料库中包含词x的文本总数。
通过计算语料库中所有词组的逆向词频,词频过高的意味该词组对于文本分类提供的信息量不大,根据词频高低更新废词库,即将词频高于阈值的词组更新到废词库中。剩余的词频不大于阈值的词组的权重可以通过词频和逆向词频相乘得到。然后利用权重和词组得到词袋模型,该模型是一张 二维表,行代表语料库包含的所有词组、短语,列代表语料库的单位日志,词袋模型中的单个元素是某个词组、短语对该日志的权重。
在一些实施例中,无论是废词库还是语料库都是可以更新的,例如当利用多个历史故障日志得到废词库和语料库后,当接收到的新的故障日志后,可以利用多个新的故障日志对废词库和语料库进行更新。
在一些实施例中,接收待分类的故障日志,进一步包括:
根据所述废词库将所述待分类的故障日志中相应的词组删除。
具体的,当接收到日志数据包后,可以按照服务器和设备模块分类(BIOS模块、BMC模块),预读日志数据,处理日志文本内容:删除符号、特殊字符等无意义字符,还原词汇的时态变化得到词汇的基本形式,拓展缩略语,去除停用词,提取词根,例如单词leave,leafed,leafs和leafing,统一各模块日志格式。并根据废词库中的词组将某些多次重复出现,但是提供的信息量不足的词组删除,这样在特征提取之前将其删除,能够减少数据处理量。
在一些实施例中,用户可以在系统设置日志上报参数,管理端的数据收集模块master向各个服务器的slave下发命令,slave上报错误日志到管理端。slave是运行在被管理的服务器主机中的软件,主动上报含有错误信息的日志数据,slave有过滤的功能,筛除正常运行日志,减少后续处理数据量。用户通过交互页面对slave上报功能进行设置:是否立即上报,上报时间周期,上报日志包含的模块,上报日志的等级,例如设置slave每日零点上报BIOS模块、BMC模块的错误级别及以上的日志。第二部分是运行在服务器管理端的master,它下发命令给slave,接收slave上报的日志数据,并将数据打包返回系统。
在一些实施例中,根据预设的语料库中的包含最多词汇的短语确定所述待分类的故障日志对应的若干个分割位置,进一步包括:
根据所述包含最多词汇的短语的词汇数量确定分割步长M;
判断所述待分类的故障日志的当前的第一个词汇与第M个词汇组成的 词组是否能够与所述语料库中的词组匹配;
响应于所述待分类的故障日志的当前的第一个词汇与第M个词汇组成的词组能够与所述语料库中的词组匹配,将所述待分类的故障日志的前M个词汇切割后,返回判断切割后的所述待分类的故障日志的当前的第一个词汇与第M个词汇组成的词组是否能够与所述语料库中的词组匹配。
在一些实施例中,还包括:
响应于所述待分类的故障日志的当前的第一个词汇与第M个词汇组成的词组不能够与所述语料库中的词组匹配,判断所述待分类的故障日志的当前的第一个词汇与第M-1个词汇组成的词组是否能够与所述语料库中的词组匹配;
响应于所述待分类的故障日志的当前的第一个词汇与第M-1个词汇组成的词组能够与所述语料库中的词组匹配,将所述待分类的故障日志的前M-1个词汇切割后,返回判断切割后的所述待分类的故障日志的当前的第一个词汇与第M个词汇组成的词组是否能够与所述语料库中的词组匹配;
响应于所述待分类的故障日志的当前的第一个词汇与第M-1个词汇组成的词组不能够与所述语料库中的词组匹配,判断所述待分类的故障日志的当前的第一个词汇与第M-N个词汇组成的词组是否能够与所述语料库中的词组匹配,其中,N为迭代次数;
响应于所述待分类的故障日志的当前的第一个词汇与第M-N个词汇组成的词组能够与所述语料库中的词组匹配,将所述待分类的故障日志的前M-N个词汇切割后,返回判断所述切割后的待分类的故障日志的当前的第一个词汇与第M个词汇组成的词组是否能够与所述语料库中的词组匹配。
具体的,语料库中的包含最多词汇的词组的词汇数为M,对于日志文本数据,可以用贪心的思想进行切割:a.首先切分“当前位置”之后的M个词汇作为匹配项。b.若匹配成功,则将“当前位置”跳转到切分位置,顺序匹配剩余文本。c.若匹配失败,切分“当前位置”之后的M-1个词汇作为匹配项。d.匹配成功,执行b步骤,匹配失败,执行c步骤,直至匹配完成所 有文本。e.输出若干词组组成的文本。
例如,待分类的故障日志为a b c d e f g,M为3,则第一次分割位置在c和d之间,然后判断a b c是否能与语料库中的词组匹配,如果匹配则将d作为当前的第一次词汇,第二次分割位置位f和g之间,然后判断d e f是否能与语料库中的词组匹配,若不匹配,则判断d e是否能与语料库中的词组匹配,若能匹配,则再次分割后剩余的文本为f g,若不能匹配则判断d否能与语料库中的词组匹配,若能匹配,则再次分割后剩余的文本为e f g。
需要说明的是,语料库中的每一个词组至少包含一个词汇,并且若语料库中的词组无法与新接收到的故障日志中的所有词汇或词组匹配,则需要根据该接收到新的故障日志对语料库进行更新。
在一些实施例中,利用若干个已分类的故障日志根据权重筛选出的若干个词组和待分类的故障日志根据权重筛选出的若干个词组计算所述待分类的故障日志与每一个已分类的故障日志之间的相似度,进一步包括:
根据若干个已分类的故障日志根据权重筛选出的若干个词组和待分类的故障日志根据权重筛选出的若干个词组得到所述每一个已分类的故障日志的特征向量和所述待分类的故障日志的特征向量;
计算所述每一个已分类的故障日志对应的特征向量与所述待分类的故障日志对应的特征向量之间的相似度。
具体的,每一个已分类的故障日志均对应一个词袋模型,包括了所有的词组对应的权重,然后选择权重最大的若干项组成日志数据的关键词组。当从待分类的故障日志筛选出关键词组后,已分类的故障日志对应的所有关键词组和待分类的故障日志对应的关键词组去除重复项后,将剩余的所有关键词组t 1,t 2,……t i看成n维坐标系,然后将每一个日志表示为一个n维空间的一个向量,该向量数据结构表示为:{D i:[w 1,w 2,……w i]}。然后再计算向量之间的相似度,以对待分类的故障日志进行分类。
例如,待分类的故障日志的关键词组为a、b、c、d、e,已分类的日志的关键词组分别为a、b、c,a、c、f,c、e、g,这样,去除重复项后得到的 所有关键词组为a、b、c、d、e、f、g,这样,待分类的故障日志对应的向量为(1,1,1,1,1,0,0),已分类的日志对应的向量为(1,1,1,0,0,0,0),(1,0,1,0,0,1,0),(0,0,1,0,1,0,1),也即向量的维度与去除重复项后得到的所有关键词组相同,若日志包括对应的关键词组,则向量中对应的元素值为1,否则为0。需要说明的是,所有的向量相同位置上的元素所对应的特征值相同。
本申请提出方案通过将英文日志处理成词组、短语的形式,大大降低了语料库内元素数量,从而简化词袋模型,减少日志特征向量的维度,从而简化词袋模型,减少日志特征向量的维度。
基于同一发明构思,根据本申请的另一个方面,本申请的实施例还提供了一种故障日志分类系统400,如图2所示,包括:
接收模块401,所述接收模块401配置为接收待分类的故障日志,并根据预设的语料库中的包含最多词汇的短语确定所述待分类的故障日志对应的若干个分割位置;
分割模块402,所述分割模块402配置为根据对应的所述若干个分割位置对所述待分类的故障日志进行分割以得到多个词组;
筛选模块403,所述筛选模块403配置为根据所述语料库确定每一个词组的权重并根据权重筛选出若干个词组;
计算模块404,所述计算模块404配置为利用若干个已分类的故障日志根据权重筛选出的若干个词组和待分类的故障日志根据权重筛选出的若干个词组计算所述待分类的故障日志与每一个已分类的故障日志之间的相似度,进而根据所述相似度对所述待分类的故障日志分类。
基于同一发明构思,根据本申请的另一个方面,如图3所示,本申请的实施例还提供了一种计算机设备501,包括:
至少一个处理器520;以及
存储器510,存储器510存储有可在处理器上运行的计算机程序511,处理器520执行程序时执行如上的任一种故障日志分类方法的步骤。
基于同一发明构思,根据本申请的另一个方面,如图4所示,本申请的实施例还提供了一种计算机可读存储介质601,计算机可读存储介质601存储有计算机程序指令610,计算机程序指令610被处理器执行时执行如上的任一种故障日志分类方法的步骤。
最后需要说明的是,本领域普通技术人员可以理解实现上述实施例方法中的全部或部分流程,可以通过计算机程序来指令相关硬件来完成,的程序可存储于一计算机可读取存储介质中,该程序在执行时,可包括如上述各方法的实施例的流程。
此外,应该明白的是,本文的计算机可读存储介质(例如,存储器)可以是易失性存储器或非易失性存储器,或者可以包括易失性存储器和非易失性存储器两者。
本领域技术人员还将明白的是,结合这里的公开所描述的各种示例性逻辑块、模块、电路和算法步骤可以被实现为电子硬件、计算机软件或两者的组合。为了清楚地说明硬件和软件的这种可互换性,已经就各种示意性组件、方块、模块、电路和步骤的功能对其进行了一般性的描述。这种功能是被实现为软件还是被实现为硬件取决于具体应用以及施加给整个系统的设计约束。本领域技术人员可以针对每种具体应用以各种方式来实现的功能,但是这种实现决定不应被解释为导致脱离本申请实施例公开的范围。
以上是本申请公开的示例性实施例,但是应当注意,在不背离权利要求限定的本申请实施例公开的范围的前提下,可以进行多种改变和修改。根据这里描述的公开实施例的方法权利要求的功能、步骤和/或动作不需以任何特定顺序执行。此外,尽管本申请实施例公开的元素可以以个体形式描述或要求,但除非明确限制为单数,也可以理解为多个。
应当理解的是,在本文中使用的,除非上下文清楚地支持例外情况,单数形式“一个”旨在也包括复数形式。还应当理解的是,在本文中使用的“和/或”是指包括一个或者一个以上相关联地列出的项目的任意和所有可能组合。
上述本申请实施例公开实施例序号仅仅为了描述,不代表实施例的优劣。
本领域普通技术人员可以理解实现上述实施例的全部或部分步骤可以通过硬件来完成,也可以通过程序来指令相关的硬件完成,的程序可以存储于一种计算机可读存储介质中,上述提到的存储介质可以是只读存储器,磁盘或光盘等。
所属领域的普通技术人员应当理解:以上任何实施例的讨论仅为示例性的,并非旨在暗示本申请实施例公开的范围(包括权利要求)被限于这些例子;在本申请实施例的思路下,以上实施例或者不同实施例中的技术特征之间也可以进行组合,并存在如上的本申请实施例的不同方面的许多其它变化,为了简明它们没有在细节中提供。因此,凡在本申请实施例的精神和原则之内,所做的任何省略、修改、等同替换、改进等,均应包含在本申请实施例的保护范围之内。

Claims (10)

  1. 一种故障日志分类方法,其特征在于,包括以下步骤:
    接收待分类的故障日志,并根据预设的语料库中的包含最多词汇的短语确定所述待分类的故障日志对应的若干个分割位置;
    根据对应的所述若干个分割位置对所述待分类的故障日志进行分割以得到多个词组;
    根据所述语料库确定每一个词组的权重并根据权重筛选出若干个词组;
    利用若干个已分类的故障日志根据权重筛选出的若干个词组和待分类的故障日志根据权重筛选出的若干个词组计算所述待分类的故障日志与每一个已分类的故障日志之间的相似度,进而根据所述相似度对所述待分类的故障日志分类。
  2. 如权利要求1所述的方法,其特征在于,还包括:
    获取多个历史故障日志并从每一个所述历史故障日志中筛选出多个词组;
    基于所述每一个历史故障日志的多个词组构成语料库。
  3. 如权利要求2所述的方法,其特征在于,还包括:
    计算所述语料库中的每一个词组的词频和逆向词频;
    将词频大于阈值的词组更新到废词库,并根据词频和逆向词频计算词频不大于阈值的词组的权重。
  4. 如权利要求3所述的方法,其特征在于,接收待分类的故障日志,进一步包括:
    根据所述废词库将所述待分类的故障日志中相应的词组删除。
  5. 如权利要求1所述的方法,其特征在于,根据预设的语料库中的包含最多词汇的短语确定所述待分类的故障日志对应的若干个分割位置,进一步包括:
    根据所述包含最多词汇的短语的词汇数量确定分割步长M;
    判断所述待分类的故障日志的当前的第一个词汇与第M个词汇组成的词组是否能够与所述语料库中的词组匹配;
    响应于所述待分类的故障日志的当前的第一个词汇与第M个词汇组成的词组能够与所述语料库中的词组匹配,将所述待分类的故障日志的前M个词汇切割后,返回判断切割后的所述待分类的故障日志的当前的第一个词汇与第M个词汇组成的词组是否能够与所述语料库中的词组匹配。
  6. 如权利要求5所述的方法,其特征在于,还包括:
    响应于所述待分类的故障日志的当前的第一个词汇与第M个词汇组成的词组不能够与所述语料库中的词组匹配,判断所述待分类的故障日志的当前的第一个词汇与第M-1个词汇组成的词组是否能够与所述语料库中的词组匹配;
    响应于所述待分类的故障日志的当前的第一个词汇与第M-1个词汇组成的词组能够与所述语料库中的词组匹配,将所述待分类的故障日志的前M-1个词汇切割后,返回判断切割后的所述待分类的故障日志的当前的第一个词汇与第M个词汇组成的词组是否能够与所述语料库中的词组匹配;
    响应于所述待分类的故障日志的当前的第一个词汇与第M-1个词汇组成的词组不能够与所述语料库中的词组匹配,判断所述待分类的故障日志的当前的第一个词汇与第M-N个词汇组成的词组是否能够与所述语料库中的词组匹配,其中,N为迭代次数;
    响应于所述待分类的故障日志的当前的第一个词汇与第M-N个词汇组成的词组能够与所述语料库中的词组匹配,将所述待分类的故障日志的前M-N个词汇切割后,返回判断切割后的所述待分类的故障日志的当前的第一个词汇与第M个词汇组成的词组是否能够与所述语料库中的词组匹配。
  7. 如权利要求1所述的方法,其特征在于,利用若干个已分类的故障日志根据权重筛选出的若干个词组和待分类的故障日志根据权重筛选出的若干个词组计算所述待分类的故障日志与每一个已分类的故障日志之间的相似度,进一步包括:
    根据若干个已分类的故障日志根据权重筛选出的若干个词组和待分类的 故障日志根据权重筛选出的若干个词组得到所述每一个已分类的故障日志的特征向量和所述待分类的故障日志的特征向量;
    计算所述每一个已分类的故障日志对应的特征向量与所述待分类的故障日志对应的特征向量之间的相似度。
  8. 一种故障日志分类系统,其特征在于,包括:
    接收模块,所述接收模块配置为接收待分类的故障日志,并根据预设的语料库中的包含最多词汇的短语确定所述待分类的故障日志对应的若干个分割位置;
    分割模块,所述分割模块配置为根据对应的所述若干个分割位置对所述待分类的故障日志进行分割以得到多个词组;
    筛选模块,所述筛选模块配置为根据所述语料库确定每一个词组的权重并根据权重筛选出若干个词组;
    计算模块,所述计算模块配置为利用若干个已分类的故障日志根据权重筛选出的若干个词组和待分类的故障日志根据权重筛选出的若干个词组计算所述待分类的故障日志与每一个已分类的故障日志之间的相似度,进而根据所述相似度对所述待分类的故障日志分类。
  9. 一种计算机设备,包括:
    至少一个处理器;以及
    存储器,所述存储器存储有可在所述处理器上运行的计算机程序,其特征在于,所述处理器执行所述程序时执行如权利要求1-7任意一项所述的方法的步骤。
  10. 一种计算机可读存储介质,所述计算机可读存储介质存储有计算机程序,其特征在于,所述计算机程序被处理器执行时执行如权利要求1-7任意一项所述的方法的步骤。
PCT/CN2021/121437 2020-11-06 2021-09-28 一种故障日志分类方法、系统、设备以及介质 WO2022095637A1 (zh)

Priority Applications (1)

Application Number Priority Date Filing Date Title
US18/033,779 US20230401121A1 (en) 2020-11-06 2021-09-28 Fault log classification method and system, and device and medium

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN202011231058.9 2020-11-06
CN202011231058.9A CN112445912B (zh) 2020-11-06 2020-11-06 一种故障日志分类方法、系统、设备以及介质

Publications (1)

Publication Number Publication Date
WO2022095637A1 true WO2022095637A1 (zh) 2022-05-12

Family

ID=74735820

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2021/121437 WO2022095637A1 (zh) 2020-11-06 2021-09-28 一种故障日志分类方法、系统、设备以及介质

Country Status (3)

Country Link
US (1) US20230401121A1 (zh)
CN (1) CN112445912B (zh)
WO (1) WO2022095637A1 (zh)

Families Citing this family (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN112445912B (zh) * 2020-11-06 2022-06-07 苏州浪潮智能科技有限公司 一种故障日志分类方法、系统、设备以及介质
CN114090850A (zh) * 2021-11-15 2022-02-25 马上消费金融股份有限公司 日志分类方法、电子设备及计算机可读存储介质
CN114328408B (zh) * 2021-12-10 2024-01-16 苏州浪潮智能科技有限公司 一种日志筛选方法、系统、设备以及介质
CN116028868B (zh) * 2023-02-15 2023-06-27 深圳市信润富联数字科技有限公司 设备故障分类方法、装置、电子设备及可读存储介质
CN118133207B (zh) * 2024-04-30 2024-08-06 苏州元脑智能科技有限公司 跨领域日志异常检测模型构建方法、装置、设备及介质

Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2014106707A (ja) * 2012-11-27 2014-06-09 Yahoo Japan Corp 単語分割装置、単語分割用辞書のデータ構造、単語分割方法、およびプログラム
CN104750833A (zh) * 2015-04-03 2015-07-01 浪潮集团有限公司 一种文本分类方法及装置
CN106095845A (zh) * 2016-06-02 2016-11-09 腾讯科技(深圳)有限公司 文本分类方法和装置
CN106250362A (zh) * 2015-06-05 2016-12-21 富士通株式会社 文本分割装置以及文本分割方法
CN108062305A (zh) * 2017-12-29 2018-05-22 北京时空迅致科技有限公司 一种基于迭代的三步式无监督中文分词方法
CN111274125A (zh) * 2020-01-14 2020-06-12 中国银联股份有限公司 一种日志分析方法及装置
CN112445912A (zh) * 2020-11-06 2021-03-05 苏州浪潮智能科技有限公司 一种故障日志分类方法、系统、设备以及介质

Family Cites Families (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN108334605B (zh) * 2018-02-01 2020-06-16 腾讯科技(深圳)有限公司 文本分类方法、装置、计算机设备及存储介质
CN108388601A (zh) * 2018-02-02 2018-08-10 腾讯科技(深圳)有限公司 故障的分类方法、存储介质及计算机设备
CN109408640B (zh) * 2018-11-02 2021-04-20 东软集团股份有限公司 日志分类方法、装置及存储介质
CN110633371A (zh) * 2019-09-23 2019-12-31 北京安信天行科技有限公司 一种日志分类方法及系统

Patent Citations (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2014106707A (ja) * 2012-11-27 2014-06-09 Yahoo Japan Corp 単語分割装置、単語分割用辞書のデータ構造、単語分割方法、およびプログラム
CN104750833A (zh) * 2015-04-03 2015-07-01 浪潮集团有限公司 一种文本分类方法及装置
CN106250362A (zh) * 2015-06-05 2016-12-21 富士通株式会社 文本分割装置以及文本分割方法
CN106095845A (zh) * 2016-06-02 2016-11-09 腾讯科技(深圳)有限公司 文本分类方法和装置
CN108062305A (zh) * 2017-12-29 2018-05-22 北京时空迅致科技有限公司 一种基于迭代的三步式无监督中文分词方法
CN111274125A (zh) * 2020-01-14 2020-06-12 中国银联股份有限公司 一种日志分析方法及装置
CN112445912A (zh) * 2020-11-06 2021-03-05 苏州浪潮智能科技有限公司 一种故障日志分类方法、系统、设备以及介质

Also Published As

Publication number Publication date
CN112445912B (zh) 2022-06-07
US20230401121A1 (en) 2023-12-14
CN112445912A (zh) 2021-03-05

Similar Documents

Publication Publication Date Title
WO2022095637A1 (zh) 一种故障日志分类方法、系统、设备以及介质
US20200081899A1 (en) Automated database schema matching
CN107430612B (zh) 查找描述对计算问题的解决方案的文档
US9836541B2 (en) System and method of managing capacity of search index partitions
US8326819B2 (en) Method and system for high performance data metatagging and data indexing using coprocessors
US9864741B2 (en) Automated collective term and phrase index
US8756207B2 (en) Systems and methods for identifying potential duplicate entries in a database
US20190005050A1 (en) Regularities and trends discovery in a flow of business documents
WO2008063973A2 (en) Method and system for high performance data metatagging and data indexing using coprocessors
US10706030B2 (en) Utilizing artificial intelligence to integrate data from multiple diverse sources into a data structure
WO2020259280A1 (zh) 日志管理方法、装置、网络设备和可读存储介质
CN113407679B (zh) 文本主题挖掘方法、装置、电子设备及存储介质
JP2010506247A (ja) 迷惑情報をフィルタリングするネットワークベースの方法および装置
CN111090731A (zh) 基于主题聚类的电力舆情摘要提取优化方法及系统
WO2017091985A1 (zh) 停用词识别方法与装置
CN112433874A (zh) 一种故障定位方法、系统、电子设备及存储介质
CN112926297A (zh) 处理信息的方法、装置、设备和存储介质
CN109241281B (zh) 软件失效原因生成方法、装置及设备
CN114357996B (zh) 时序文本特征提取方法、装置、电子设备及存储介质
CN110674283A (zh) 文本摘要的智能抽取方法、装置、计算机设备及存储介质
CN113157857B (zh) 面向新闻的热点话题检测方法、装置及设备
CN115129890A (zh) 回馈数据图谱生成方法、生成设备、问答设备及冰箱
Jain et al. An extensible parsing pipeline for unstructured data processing
CN114090850A (zh) 日志分类方法、电子设备及计算机可读存储介质
CN113779200A (zh) 目标行业词库的生成方法、处理器及装置

Legal Events

Date Code Title Description
121 Ep: the epo has been informed by wipo that ep was designated in this application

Ref document number: 21888334

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

122 Ep: pct application non-entry in european phase

Ref document number: 21888334

Country of ref document: EP

Kind code of ref document: A1