CN113835987B - Chaotic experiment execution file generation method and device, electronic equipment and storage medium - Google Patents

Chaotic experiment execution file generation method and device, electronic equipment and storage medium Download PDF

Info

Publication number
CN113835987B
CN113835987B CN202111409366.0A CN202111409366A CN113835987B CN 113835987 B CN113835987 B CN 113835987B CN 202111409366 A CN202111409366 A CN 202111409366A CN 113835987 B CN113835987 B CN 113835987B
Authority
CN
China
Prior art keywords
information
alarm
chaotic experiment
execution file
alarm information
Prior art date
Legal status (The legal status 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 status listed.)
Active
Application number
CN202111409366.0A
Other languages
Chinese (zh)
Other versions
CN113835987A (en
Inventor
田科
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Beijing Century TAL Education Technology Co Ltd
Original Assignee
Beijing Century TAL Education Technology Co Ltd
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 Beijing Century TAL Education Technology Co Ltd filed Critical Beijing Century TAL Education Technology Co Ltd
Priority to CN202111409366.0A priority Critical patent/CN113835987B/en
Publication of CN113835987A publication Critical patent/CN113835987A/en
Application granted granted Critical
Publication of CN113835987B publication Critical patent/CN113835987B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring
    • G06F11/34Recording or statistical evaluation of computer activity, e.g. of down time, of input/output operation ; Recording or statistical evaluation of user activity, e.g. usability assessment
    • G06F11/3457Performance evaluation by simulation
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring
    • G06F11/32Monitoring with visual or acoustical indication of the functioning of the machine
    • G06F11/324Display of status information
    • G06F11/327Alarm or error message display
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/21Design or setup of recognition systems or techniques; Extraction of features in feature space; Blind source separation
    • G06F18/214Generating training patterns; Bootstrap methods, e.g. bagging or boosting
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F18/00Pattern recognition
    • G06F18/20Analysing
    • G06F18/24Classification techniques
    • G06F18/241Classification techniques relating to the classification model, e.g. parametric or non-parametric approaches
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F40/00Handling natural language data
    • G06F40/10Text processing
    • G06F40/194Calculation of difference between files
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F40/00Handling natural language data
    • G06F40/20Natural language analysis
    • G06F40/279Recognition of textual entities
    • G06F40/289Phrasal analysis, e.g. finite state techniques or chunking
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F40/00Handling natural language data
    • G06F40/30Semantic analysis

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • General Engineering & Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Artificial Intelligence (AREA)
  • Data Mining & Analysis (AREA)
  • Health & Medical Sciences (AREA)
  • Audiology, Speech & Language Pathology (AREA)
  • Computational Linguistics (AREA)
  • General Health & Medical Sciences (AREA)
  • Evolutionary Computation (AREA)
  • Evolutionary Biology (AREA)
  • Computer Vision & Pattern Recognition (AREA)
  • Bioinformatics & Computational Biology (AREA)
  • Bioinformatics & Cheminformatics (AREA)
  • Quality & Reliability (AREA)
  • Life Sciences & Earth Sciences (AREA)
  • Computer Hardware Design (AREA)
  • Debugging And Monitoring (AREA)

Abstract

The present disclosure provides a chaotic experiment execution file generation method, device, electronic device and storage medium, the method comprising: acquiring at least one alarm message sent by a system component in a computer system fault; determining system architecture information of system components corresponding to each alarm message, wherein the system architecture information is used for indicating a topological relation among the system components; inputting at least one piece of alarm information and system architecture information of a system component corresponding to the alarm information into a pre-trained chaotic experiment classification model to obtain at least one piece of chaotic experiment type information; and respectively generating an execution file aiming at each chaotic experiment type information. The chaotic experiment device and the chaotic experiment method can reduce the technical difficulty of chaotic experiment tests.

Description

Chaotic experiment execution file generation method and device, electronic equipment and storage medium
Technical Field
The invention relates to the technical field of system testing, in particular to a chaotic experiment execution file generation method and device, electronic equipment and a storage medium.
Background
Today, in order to ensure stable operation of various computer systems (e.g., distributed systems), it is often necessary to test the computer systems to determine whether the stability of the computer systems meets the usage requirements. Based on the above, Chaos Engineering (Chaos Engineering) is adopted, and the testing technology simulates the situation and phenomenon when an actual fault occurs by actively injecting the fault into the computer system through a technician, so as to realize controllable fault observation, so that the Chaos Engineering is a reliable computer system testing mode.
For a computer system, the faults are often various, and when a computer system is tested, a technician needs to design a chaotic experiment aiming at the faults possibly occurring in the computer system to obtain an execution file of the chaotic experiment, and the chaotic experiment is performed on the computer system by operating the execution file. However, because a computer system generally has multiple fault types, the chaos experiment is manually designed and corresponding execution files are generated aiming at different types of faults, the technical difficulty is high, and a technician needs to spend a long time, so that the generation efficiency of the chaos experiment execution files is low.
Disclosure of Invention
In order to solve the above problem, embodiments of the present disclosure provide a chaotic experiment execution file generation method and apparatus, an electronic device, and a storage medium, so as to at least partially solve the above problem.
According to an aspect of the present disclosure, there is provided a chaotic experiment execution file generation method for generating an execution file for performing a chaotic experiment on a computer system, including:
acquiring at least one alarm message sent by a system component in a computer system fault;
determining system architecture information of system components corresponding to each alarm message, wherein the system architecture information is used for indicating a topological relation among the system components;
inputting the at least one piece of alarm information and the system architecture information of the system component corresponding to the alarm information into a pre-trained chaotic experiment classification model to obtain at least one piece of chaotic experiment type information;
and respectively generating one execution file aiming at each chaotic experiment type information. According to another aspect of the present disclosure, there is provided a chaotic experiment execution file generating apparatus for generating an execution file for performing a chaotic experiment on a computer system, including:
the system comprises an acquisition module, a processing module and a processing module, wherein the acquisition module is used for acquiring at least one alarm message sent by a system component in the computer system failure;
the first determining module is used for determining system architecture information of the system components corresponding to each alarm message, wherein the system architecture information is used for indicating a topological relation among the system components;
the second determining module is used for inputting the at least one piece of alarm information and the system architecture information of the system component corresponding to the alarm information into a pre-trained chaotic experiment classification model to obtain at least one piece of chaotic experiment type information;
and the generating module is used for respectively generating one execution file according to each chaotic experiment type information.
According to another aspect of the present disclosure, there is provided an electronic device including:
a processor; and
a memory for storing a program, wherein the program is stored in the memory,
wherein the program comprises instructions which, when executed by the processor, cause the processor to perform the chaotic experiment execution file generation method described above.
According to another aspect of the present disclosure, there is provided a non-transitory computer readable storage medium storing computer instructions for causing the computer to execute the chaotic experiment execution file generation method as described above.
According to another aspect of the present disclosure, there is provided a computer program product comprising a computer program, wherein the computer program, when executed by the processor, implements the chaotic experiment execution file generation method described above.
The chaos experiment executing file generating method in the disclosed embodiment can obtain at least one alarm message sent by a system component in a computer system fault, then determine the system architecture message of the system component corresponding to each alarm message, the system architecture message is used for indicating the topological relation between the system components, then input the system architecture message of the system component corresponding to at least one alarm message and the alarm message into a chaos experiment classification model trained in advance to obtain at least one chaos experiment type message, and finally respectively generate an executing file aiming at each chaos experiment type message, therefore, in the disclosed embodiment, the chaos experiment test of the computer system is associated with the alarm message of the fault of the computer system, and corresponding chaos experiment type message and chaos experiment executing file can be automatically output for different fault types, and the rationality of the chaotic experiment can be ensured, so that the technical difficulty in designing the chaotic experiment is greatly reduced, the time of technicians is greatly saved, and the generation efficiency of chaotic experiment execution files is improved.
Drawings
Further details, features and advantages of the disclosure are disclosed in the following description of exemplary embodiments, taken in conjunction with the accompanying drawings, in which:
fig. 1 shows a flowchart of a chaotic experiment execution file generation method according to an exemplary embodiment of the present disclosure.
Fig. 2 illustrates an exemplary system architecture topology according to an exemplary embodiment of the present disclosure.
Fig. 3 shows a flowchart of an alternative training approach for a chaotic experimental classification model according to an exemplary embodiment of the present disclosure.
Fig. 4 shows a schematic block diagram of a chaotic experiment execution file generation apparatus according to an exemplary embodiment of the present disclosure.
FIG. 5 illustrates a block diagram of an exemplary electronic device that can be used to implement embodiments of the present disclosure.
Detailed Description
Embodiments of the present disclosure will be described in more detail below with reference to the accompanying drawings. While certain embodiments of the present disclosure are shown in the drawings, it is to be understood that the present disclosure may be embodied in various forms and should not be construed as limited to the embodiments set forth herein, but rather are provided for a more thorough and complete understanding of the present disclosure. It should be understood that the drawings and embodiments of the disclosure are for illustration purposes only and are not intended to limit the scope of the disclosure.
It should be understood that the various steps recited in the method embodiments of the present disclosure may be performed in a different order, and/or performed in parallel. Moreover, method embodiments may include additional steps and/or omit performing the illustrated steps. The scope of the present disclosure is not limited in this respect.
The term "include" and variations thereof as used herein are open-ended, i.e., "including but not limited to". The term "based on" is "based, at least in part, on". The term "one embodiment" means "at least one embodiment"; the term "another embodiment" means "at least one additional embodiment"; the term "some embodiments" means "at least some embodiments". Relevant definitions for other terms will be given in the following description. It should be noted that the terms "first", "second", and the like in the present disclosure are only used for distinguishing different devices, modules or units, and are not used for limiting the order or interdependence relationship of the functions performed by the devices, modules or units.
It is noted that references to "a", "an", and "the" modifications in this disclosure are intended to be illustrative rather than limiting, and that those skilled in the art will recognize that "one or more" may be used unless the context clearly dictates otherwise.
The names of messages or information exchanged between devices in the embodiments of the present disclosure are for illustrative purposes only, and are not intended to limit the scope of the messages or information.
In order to make those skilled in the art better understand the technical solutions in the embodiments of the present disclosure, the technical solutions in the embodiments of the present disclosure will be clearly and completely described below with reference to the drawings in the embodiments of the present disclosure, and it is obvious that the described embodiments are only a part of the embodiments of the present disclosure, but not all the embodiments. All other embodiments obtained by a person of ordinary skill in the art based on the embodiments in the present disclosure should fall within the scope of protection of the embodiments in the present disclosure.
Referring to fig. 1, a flowchart illustrating steps of a chaotic experiment execution file generation method for generating an execution file for performing a chaotic experiment on a computer system in an embodiment of the present disclosure is shown, which includes the following steps S101, S102, S103, and S104.
S101: at least one alarm message issued by a system component in a computer system failure is obtained.
The chaotic experiment execution file generation method can be executed by the chaotic experiment execution file generation device in the embodiment of the disclosure, for example, the chaotic experiment execution file generation device can be a device capable of processing data.
In the embodiment of the present disclosure, the computer system may be a distributed system, for example, a PaaS (Platform as a Service) system, or may also be another type of computer system, which is not limited in the embodiment of the present disclosure. The system components can be, for example, Load Balance (LB, Load balancing) components, Spring Boot components, MySQL components, and the like, when various faults occur in the system components, alarm information is generated and collected, and the chaos experiment execution file generation device acquires the alarm information.
In the embodiment of the present disclosure, the warning information may be sent by the system component when a fault occurs in the actual operation process of the computer system, and then obtained by the chaotic experiment execution file generation device, or may be sent by the system component after a technician actively injects a fault into the system computer system, and then obtained by the chaotic experiment execution file generation device. The embodiments of the present disclosure are not limited.
In one embodiment, the alarm information in the embodiment of the present disclosure may include at least the following: the alarm rule description is used for indicating the type of the fault corresponding to the historical alarm information, and the alarm influence coefficient is used for indicating the influence degree of the fault on the computer system.
In the embodiment of the present disclosure, the alarm influence coefficient may be determined in advance as needed according to the degree of influence of the actual fault on the computer system, for example, it may be characterized by an arabic number (for example, an alarm influence coefficient with a larger number indicates that the degree of influence of the actual fault on the computer system is larger), or may be characterized in other forms.
In addition to the alarm rule description and the alarm influence coefficient, other data related to the alarm information may be attached to the alarm information, for example: alarm time (which may characterize the time at which the fault occurred), the name of the system component that was alarmed, the alarm level (which corresponds to the alarm impact coefficient), and the IP address of the system component to which the alarm information corresponds, among other things.
For example, in one example, the alert information may include:
"alarm time: xxxx year xx month xx day xx: xx: xx; alarm system components: MySQL; and alarming IP address: xx.xxx.xxx; alarm influence coefficient: 10; alarm level: severe; and (3) alarm rule description: SQL executes for more than 1 minute. "
Of course, this is merely an example for ease of understanding and is not a limitation on the embodiments of the present disclosure.
In one embodiment, the chaotic experiment execution file generation method further includes: and if the number of the alarm information is multiple, performing duplicate removal processing on the alarm information.
In the embodiment of the present disclosure, the performing duplicate removal processing on multiple alarm information refers to processing multiple duplicate alarm information sent by the same system component for the same fault, so that only one alarm information is retained, and other duplicate alarm information is discarded. Because repeated alarm information is easy to interfere data generated in the chaos experiment execution file generation method in the embodiment of the present disclosure during subsequent execution, and the calculation amount is also easy to increase, multiple alarm information is subjected to deduplication processing in the embodiment of the present disclosure.
In the embodiment of the present disclosure, a plurality of alarm information having the same content except for different alarm times within a preset time may be determined as the repeated alarm information. The alarm information retained after the deduplication processing may be the alarm information with the earliest alarm time, or may be other alarm information retained, which is not limited in the embodiment of the present disclosure.
For example, a certain system component continuously sends out 9 alarm messages in 1 second, and respectively sends out the alarm messages at 10 different times (e.g., 0.1s, 0.2s, 0.3s, 0.4s, 0.5s, 0.6s, 0.7s, 0.8s, 0.9 s) in the 1 second, and the alarm messages are all the same except for the alarm time (e.g., alarm rule description, alarm impact coefficient, system component name of the alarm, alarm level, IP address of the system component corresponding to the alarm message, etc.), so that the 10 alarm messages are determined to be the same alarm message sent for the same fault, and only one of the alarm messages is retained after deduplication processing, where the alarm message with the earliest alarm time may be retained (e.g., the alarm message sent in the 0.1 s).
S102: and determining system architecture information of the system component corresponding to each alarm message.
In the embodiment of the present disclosure, the system architecture information is used to indicate a topological relationship between system components. In the embodiment of the disclosure, for each system component in a certain computer system, the connection relationship between the upper layer and the lower layer of the system component is determined, and the system architecture information of the system component is also determined.
Referring to fig. 2, an exemplary system architecture topology diagram in the embodiment of the present disclosure is shown, and of course, the system architecture topology diagram is far more simple than this for a complete computer system, and therefore, the diagram is only used as an explanation for easy understanding in the embodiment of the present disclosure, and is not a limitation in the embodiment of the present disclosure. For example, in the schematic diagram of fig. 2, the system architecture information corresponding to the MySQL component may be simply: the front component is a Spring Boot component (the Spring Boot component positioned above the topological graph), the rear component is a storage component, the front component of the Load Balance component is a front-end component, the front component is a Spring Boot component (the Spring Boot component positioned below the topological graph), the rear component is a storage component, and the front component of the Load Balance component is a front-end component; the system architecture information corresponding to the Spring Boot component (the Spring Boot component located above in the topological graph) may be simply: the front-end component is a Load Balance component, the back-end component is a MySQL component, and the front-end component of the Load Balance component is a front-end component; the system architecture information corresponding to the Spring Boot component (the Spring Boot component located below in the topological graph) may be simply: the front-end component is a Load Balance component, the back-end component is a MySQL component, and the front-end component of the Load Balance component is a front-end component; and so on.
In the embodiment of the present disclosure, the system architecture information of the system component may be uniformly stored in a pre-created database, and the system architecture information of the system component corresponding to each alarm information may be determined from the database according to each alarm information.
Specifically, in one embodiment, step S102 may specifically include: for each alarm message, executing: extracting the IP address of the system component corresponding to the alarm information from each alarm information; and acquiring system architecture information of the system component corresponding to the alarm information according to the extracted IP address.
Specifically, in one embodiment, the system architecture information of the system component corresponding to the alarm information may be obtained from a first database created in advance according to the extracted IP address. Specifically, the first database may store a correspondence between the IP address of the system component and the system architecture information in advance, so that the first database may be queried for the corresponding system architecture information through the IP address extracted from the warning information.
Since the names of the system components may be the same, for example, in the foregoing example, there are at least two Spring Boot components, so that the system architecture information is determined directly by the corresponding system component name in the alarm information (for example, by querying from the foregoing first database), there is a possibility of a matching error, for example, when the system architecture information of the upper Spring Boot component in fig. 2 is determined, the system architecture information of the lower Spring Boot component may be obtained, and thus, a situation in which the alarm information and the system architecture information are difficult to correspond occurs, and a subsequent chaos experiment is influenced in a targeted manner. And because the corresponding IP addresses of each system component of the computer system are different, the IP address of the system component corresponding to the alarm information is extracted from each alarm information, and then the system architecture information of the system component is matched according to the IP address, so that the problem of query error is avoided, and the alarm information and the system architecture information can be correctly corresponding.
S103: and inputting the at least one piece of alarm information and the system architecture information of the system component corresponding to the alarm information into a pre-trained chaotic experiment classification model to obtain at least one piece of chaotic experiment type information.
In the embodiment of the disclosure, the chaotic experiment classification model may perform calculation according to the input at least one alarm information and the system architecture information of the system component corresponding to the alarm information, and then output at least one chaotic experiment type information. Specifically, for one fault of the computer system, one chaotic experiment type information can be output according to the input corresponding alarm information and system architecture information, and for a plurality of faults, a plurality of chaotic experiment type information can be output according to the input corresponding alarm information and system architecture information. For the determined fault, a chaos experiment can be determined by using the corresponding chaos experiment type information to test the fault.
In the embodiment of the present disclosure, the chaos experiment classification model may be obtained by training in any suitable manner, which is not limited in the embodiment of the present disclosure. Alternatively, referring to the flowchart in fig. 3, the chaotic experiment classification in the embodiment of the present disclosure may be obtained by training in a manner including the following steps S201, S202, S203, and S204, specifically:
s201: and acquiring a plurality of sample data and performing word segmentation processing on the sample data to obtain at least one sample word segmentation.
In the embodiment of the disclosure, the sample data includes historical alarm information, system architecture information of a system component corresponding to the historical alarm information, and chaotic experiment type information, and in addition, the historical alarm information is alarm information sent by a system component in a history recording computer system fault.
It is understood that, in the embodiment of the present disclosure, the historical alarm information is not different from the alarm information described in the foregoing steps S101 and S102 in nature, but only the historical alarm information is the alarm information sent by the system component in the history record computer system fault before the chaos experiment classification model is not trained, and the alarm information described in the steps S101 and S102 is the alarm information sent by the system component in the computer system fault after the chaos experiment classification model is trained.
In the embodiment of the disclosure, the historical alarm information may be the historical alarm information obtained by sending alarm information by a system component when a fault is actually encountered before the chaos experiment classification model is trained and then recording the alarm information; or when a technician performs a chaos experiment test on the computer system in a targeted manner, the technician actively injects a fault into the computer system, then sends out alarm information by a system component, and then records the alarm information to obtain historical alarm information. In this regard, the present disclosure is not limited in embodiments.
In the embodiment of the disclosure, the system architecture information is used for indicating the topological relation between the system components, for each determined system component in the computer system, the upper and lower layer connection relations between the system components before and after the system component are determined, and the system architecture information of the system components is also determined, so that the chaotic experiment of the computer system can be classified conveniently based on the system architecture information. Specifically, the system architecture information can be understood by referring to the system architecture information in S101, and therefore, the detailed description thereof is omitted.
In one embodiment, the historical alarm information at least includes the following key alarm data: the alarm rule description is used for indicating the type of the fault corresponding to the historical alarm information, and the alarm influence coefficient is used for indicating the influence degree of the fault on the computer system.
In the embodiment of the present disclosure, the alarm influence coefficient may be determined in advance as needed according to the degree of influence of the actual fault on the computer system, for example, it may be characterized by an arabic number (for example, an alarm influence coefficient with a larger number indicates that the degree of influence of the actual fault on the computer system is larger), or may be characterized in other forms.
In this disclosure, the historical warning information may further include data such as an IP address and a system component name corresponding to the system component corresponding to the historical warning information, which is not limited in this disclosure.
In the embodiment of the disclosure, the acquired chaotic experiment type information is the type of the chaotic experiment corresponding to the historical alarm information sent by the system component. For a certain fault, a plurality of alarm information can be triggered, but only one chaotic experiment is corresponding to the certain fault, namely only one chaotic experiment type is triggered. For example, if "MySQL cannot be connected" is indicated in the alarm information, the chaos experiment type corresponding to the alarm information may be "stop MySQL".
In the embodiment of the disclosure, sample data (i.e., the historical alarm information, the system architecture information of the system component corresponding to the historical alarm information, and the chaotic experiment type information) may be stored in a character string form, and after obtaining a plurality of pieces of historical alarm information in the character string form, the system architecture information of the system component corresponding to the historical alarm information, and the chaotic experiment type information, in order to correctly analyze semantics of related data, the related data may be subjected to word segmentation to obtain sample word segmentation, which is each word result generated after the word segmentation is performed on the sample data.
In the context of chinese, a single word often has a difficult actual semantic meaning, and a sentence can be segmented into words according to a certain rule to facilitate analysis and processing of the semantic meaning, for example, the "number of service connections exceeds 10000" of the following historical alarm information is segmented, and then the sample segmentation (i.e., the segmentation processing result) can be "service, number of connections, exceeds, 10000" respectively, for example.
In the embodiment of the present disclosure, the method for word segmentation processing may be any suitable method for word segmentation processing as long as the requirement can be met, for example, in one embodiment, the word segmentation processing may be jieba word segmentation processing, which can ensure the accuracy of word segmentation on sample data such as historical alarm information.
In the embodiment of the disclosure, after the sample segmentation is obtained, the sample segmentation can be further processed, so that the classification model to be trained is trained subsequently, and the chaos experiment classification model is finally obtained.
S202: and respectively carrying out word vector conversion on each sample word segmentation to obtain a sample word vector.
In the embodiment of the disclosure, after the sample word segmentation is obtained, the sample word segmentation is converted into a sample word vector taking the word vector as a representation form. For example, an example of performing word vector conversion on sample participles may be converting a word obtained by participle processing (i.e., sample participles) "stop" into a word vector a1= [ x1, y1, z1], converting a word obtained by participle processing "pause" into a word vector a2= [ x2, y2, z2], converting a word obtained by participle processing "start" into a word vector B1= [ x3, y3, z3], and converting a word obtained by participle processing "query" into a word vector B2= [ x4, y4, z4 ]. Wherein x1, y1, z1, x2, y2, z2, x3, y3, z3, x4, y4 and z4 are constants. It is to be understood that the number of rows and columns of these exemplary word vectors are merely examples to meet the usage requirements, and are not limiting on the embodiments of the present disclosure.
In the embodiment of the present disclosure, the method for word vector conversion may be any suitable method for word vector conversion as long as the requirement can be met, for example, in one embodiment, the vector conversion may be that the sample participles are input into the word2vec model for word vector conversion processing, and the accuracy of word vector conversion on the sample participles can be ensured.
In one embodiment, in the embodiment of the present disclosure, similarity calculation may be performed on each word vector in the sample word vectors, so as to classify word vectors with similar semantics, which is convenient for subsequent labeling and model training. In one embodiment, the cosine similarity (i.e. the cosine value of the included angle between two word vectors) may be calculated pairwise for each sample word vector according to the following formula:
Figure 779182DEST_PATH_IMAGE001
here, A, B is a word vector, cos (θ) is a cosine similarity of the two, and θ is an angle between the word vectors A, B.
The portions of similarity in the embodiments of the present disclosure are briefly exemplified by the above-mentioned a1, a2, B1, B2. It can be understood that "stop" and "pause" are two sample participles with substantially similar semantics, and when calculating the similarity, the similarity between the sample word vectors a1 and a2 corresponding to the two words is higher, the cosine similarity cos (θ 1) of the two words is close to 1, and the included angle θ 1 between a1 and a2 is close to 0 °; the method comprises the following steps that (1) stop and start are two sample participles with basically opposite semantics, when similarity is calculated, the similarity between sample word vectors A1 and B1 corresponding to the two samples is low, the cosine similarity cos (theta 2) of the two samples is close to-1, and the included angle theta 2 between A1 and B1 is close to 180 degrees; the 'stop' and 'query' are two sample participles with basically irrelevant semantics, when the similarity is calculated, the similarity between the sample word vectors A1 and B2 corresponding to the two words is low, the cosine similarity cos (theta 3) of the two words is close to 0, and the included angle theta 3 between A1 and B2 is close to 90 degrees. The rest conditions can be analogized in the same way, and in brief, the closer the semantics of the sample word segmentation, the smaller the included angle between the sample word vectors and the greater the similarity.
Through the method, the sample word vectors with similar semantics can be classified into one class according to the similarity, so that subsequent labeling and model training are facilitated.
S203: obtaining training sample data, wherein the training sample data comprises the sample word vector and labeling information, and the labeling information is used for indicating the corresponding relation between the historical alarm information and the system architecture information corresponding to the sample word vector and the chaotic experiment type information.
In the embodiment of the disclosure, the chaotic experiment classification model may be a supervised machine learning model, the training sample data may be a sample word vector carrying label information, and the label information may indicate a correspondence between the historical alarm information and the system architecture information corresponding to the sample word vector and chaotic experiment type information.
The process of labeling the sample word vector using the labeling information may be performed manually, or may be performed automatically using a specific rule (for example, using another labeling model for automatic labeling). In this regard, the present disclosure is not limited in embodiments.
S204: and inputting the training sample data into a classification model to be trained for training to obtain the chaos experiment classification model.
In the embodiment of the disclosure, the classification model to be trained is trained by using the training sample data, and when the training ending condition is met, the training of the classification model to be trained is ended, so that the chaos experiment classification model after training is finally obtained.
In the embodiment of the present disclosure, the model to be trained may be based on a formed machine learning model framework, and may be reasonably selected according to actual needs, for example: TensorFlow, Theano, PyTorch,   Torch,   Caffe, SciKit-spare, etc., which are not limited in the examples of the present disclosure. In addition, specific information of the optional framework can refer to related technologies, and is not described herein again.
In the chaotic experiment classification model, data such as alarm information, system architecture information and the like are input, chaotic experiment type information is output, and when the chaotic experiment classification model is used, the data such as the alarm information, the system architecture information and the like are input into the chaotic experiment classification model, so that a corresponding chaotic experiment classification result can be directly output, namely, a corresponding chaotic experiment type information is output, and a chaotic experiment execution file can be generated according to the chaotic experiment type information subsequently.
In the embodiment of the present disclosure, the condition for ending the model training may be that when a loss value output by a loss function (which may be a conventional loss function, such as the foregoing cosine similarity function, and may also be an optional loss function) of the model training is within a preset loss value range, it is determined that the model training is ended. Or, when the number of iterations of training reaches a preset value during training, it may be determined that the iteration satisfies the end condition, so as to end the model training process.
In the embodiment of the disclosure, the chaotic experiment classification model is trained in the above manner, so that chaotic experiment type information can be reliably output by the chaotic experiment classification model according to data such as alarm information, system architecture information and the like when the chaotic experiment classification model is used, and technicians can conveniently and quickly determine an execution file of the chaotic experiment type information according to the chaotic experiment type information, thereby effectively reducing the technical difficulty of chaotic experiment testing on a computer, greatly saving the time of the technicians and improving the generation efficiency of the chaotic experiment execution file.
In one embodiment, step S103 specifically includes: determining the alarm information of the same fault as an alarm information group according to the system architecture information of the system component corresponding to the at least one alarm information; and respectively inputting the alarm information included by each alarm information group and the system architecture information of the system component corresponding to the alarm information into the chaotic experiment classification model to obtain at least one chaotic experiment type information.
For the same fault, the fault may affect a plurality of system components under the same system architecture, so that different system components send out alarm information, and therefore the alarm information is grouped according to the system architecture information corresponding to the alarm information, wherein the faults corresponding to different alarm information groups are different, and the corresponding chaotic experiment type information is also different. And respectively inputting the alarm information contained in each alarm information group and the system architecture information of the system component corresponding to the alarm information into the chaotic experiment classification model, and further respectively obtaining chaotic experiment type information corresponding to each alarm information group, so that the corresponding chaotic experiment execution file is respectively determined for the fault corresponding to each alarm information group subsequently, and the computer system can be conveniently tested.
In one embodiment, the step S103 of inputting the warning information included in each warning information group and the system architecture information of the system component corresponding to the warning information into the chaotic experiment classification model specifically includes: extracting key alarm data from each alarm information included in each alarm information group, wherein the key alarm data comprise at least one of an IP address, a system component name, an alarm rule description and an alarm influence coefficient corresponding to a system component; and respectively inputting the key alarm data extracted from each alarm information group and the system architecture information of the system component corresponding to each alarm information in the alarm information group into the chaotic experiment classification model.
In the embodiment of the disclosure, the key alarm data of the alarm information is extracted and then input into the chaotic experiment classification model, so that the calculation amount for determining the chaotic experiment type information is obviously reduced, the efficiency of generating the chaotic experiment execution file is further improved, and the chaotic experiment execution file is more accurate.
S104: and respectively generating one execution file aiming at each chaotic experiment type information.
In the embodiment of the disclosure, after the chaotic experiment execution file generation device determines at least one chaotic experiment type information, an execution file of a chaotic experiment can be generated according to each chaotic experiment type information, the execution file can be a script or a string of execution codes, and the execution file is input into a computer system to perform a chaotic experiment test on the computer system.
The chaos experiment executing file generating method in the disclosed embodiment can obtain at least one alarm message sent by a system component in a computer system fault, then determine the system architecture message of the system component corresponding to each alarm message, the system architecture message is used for indicating the topological relation between the system components, then input the system architecture message of the system component corresponding to at least one alarm message and the alarm message into a chaos experiment classification model trained in advance to obtain at least one chaos experiment type message, and finally respectively generate an executing file aiming at each chaos experiment type message, therefore, in the disclosed embodiment, the chaos experiment test of the computer system is associated with the alarm message of the fault of the computer system, and corresponding chaos experiment type message and chaos experiment executing file can be automatically output for different fault types, and the rationality of the chaotic experiment can be ensured, so that the technical difficulty in designing the chaotic experiment is greatly reduced, the time of technicians is greatly saved, and the generation efficiency of chaotic experiment execution files is improved.
In one embodiment, step S104 specifically includes: and aiming at each chaotic experiment type information, determining an execution file template corresponding to the chaotic experiment type information, and generating one execution file based on the execution file template.
In the embodiment of the present disclosure, the execution file template may be an execution script or execution code, which may record execution steps corresponding to a certain type of chaotic experiment.
In the embodiment of the disclosure, the execution file is generated based on the execution file template, so that the generation of the execution file of the chaotic experiment is more convenient, and the efficiency is higher.
For example, the execution file template in the embodiment of the present disclosure may be stored in a second database created in advance, for example, a correspondence between the chaotic experiment type and the execution file template may be stored in the second database in advance, so that the execution file template corresponding to each chaotic experiment type may be obtained from the second database through each obtained chaotic experiment type information. Optionally, the second database may also be the same as the first database, and this is not limited in the embodiment of the present disclosure.
In one embodiment, the generating one execution file based on the execution file template may include: and aiming at each chaotic experiment type information, extracting key information from the alarm information included in the alarm information group corresponding to the chaotic experiment type information, inputting the key information into the execution file template corresponding to the chaotic experiment type information, and obtaining the execution file corresponding to the chaotic experiment type information.
For example, if the determined chaotic experiment type information is MySQL procedure pause, the execution file template records relevant codes for pausing the MySQL procedure. According to the execution file template and some key information included by the alarm information, an execution file corresponding to the chaotic experiment can be finally generated, and the chaotic experiment test can be performed on the corresponding fault of the computer system by using the execution file.
The method for generating the text by performing the chaotic experiment in the embodiment of the present disclosure is further described with reference to an example. It should be understood that the following examples are for the purpose of facilitating understanding of the disclosed embodiments only, and are not intended to limit the disclosed embodiments in any way. For example, in an actual scenario example, the chaotic experiment execution file generation device in the embodiment of the present disclosure obtains an alarm message, which includes: "alarm time: 09 month 23 day 16 in 2021: 08: 40; alarm system components: MySQL; and alarming IP address: 10.157.23 a.24c; alarm influence coefficient: 10; alarm level: severe; and (3) alarm rule description: SQL executes for more than 1 minute. "(a, c are both constants). The chaos experiment execution file generating device extracts the IP address of the alarm component according to the alarm information, inquires system architecture information from a first database, and then inputs key alarm data (such as alarm rule description, alarm influence coefficient and the like) and system architecture information of the alarm information into the chaos experiment classification model trained according to the chaos experiment classification model training method, wherein the chaos experiment classification model outputs chaos experiment type information corresponding to the alarm information according to the alarm information and the system architecture information: the MySQL procedure is paused. The chaotic experiment execution file generation device queries the second database according to the chaotic experiment type information, determines an execution file template corresponding to the MySQL procedure pause (corresponding to this example, the execution file template may be a string of execution codes for causing the MySQL procedure pause experiment), extracts some key information of the alarm information to supplement the execution file template, and then obtains an available chaotic experiment execution file. Using the chaos experiment execution file to perform the following chaos experiment on a computer system: and stopping the MySQL process for 60 seconds to enable the SQL execution time to exceed 1 minute, thereby completing the chaotic experiment test. It is understood that in this example, "60 seconds" is input into the execution file template for implementation according to the key information "1 minute" in the alarm information.
It can be seen from the above examples that, in the embodiment of the present disclosure, the chaotic experiment test of the computer system is associated with the alarm information of the fault of the computer system, so that the corresponding chaotic experiment type information and the execution file of the chaotic experiment can be automatically output for different fault types, and the rationality of the chaotic experiment can be ensured, thereby greatly reducing the technical difficulty in designing the chaotic experiment, greatly saving the time of technicians, and improving the generation efficiency of the execution file of the chaotic experiment.
It is understood that, in other embodiments, the execution file template may be directly used as the execution file when the actual requirement can be met.
For example, in one embodiment, the key information includes: and the IP address of the system component corresponding to the alarm information. Namely: the IP address of the system component corresponding to the alarm information may be extracted from the alarm information included in the alarm information group corresponding to the chaotic experiment type information, and the extracted IP address may be input to the execution file template to obtain an execution file corresponding to the chaotic experiment type information.
Specifically, in this optional embodiment, if the chaotic experiment type information corresponds to only one alarm information, the IP address of the system component corresponding to the alarm information is extracted from the alarm information, and the IP address is input into the execution file template, so that the obtained execution file can be used for performing a targeted chaotic experiment test on the system component at the IP address; if the chaotic experiment type information corresponds to an alarm information group which comprises alarm information sent by a plurality of different system components, the IP addresses of one or more system components needing to be input into the execution file template can be determined by combining the chaotic experiment type information.
In the embodiment of the disclosure, the IP address of the system component corresponding to the alarm information is embedded into the execution file template, so that the execution file of the chaotic experiment can be generated in a targeted manner, and the chaotic experiment test can be better performed on the computer system.
The method for generating the text by performing the chaotic experiment in the embodiment of the present disclosure is further described below with reference to an example. It should be understood that the following examples are for the purpose of facilitating understanding of the disclosed embodiments only, and are not intended to limit the disclosed embodiments in any way. For example, in an actual scenario example, the chaotic experiment execution file generation device in the embodiment of the present disclosure acquires two pieces of alarm information, one of which includes: "alarm time: 09 month 13 day 16 in 2021: 54: 25; alarm system components: spring Boot; and alarming IP address: 10.157.23 a.24b; alarm influence coefficient: 9; alarm level: severe; and (3) alarm rule description: the number of service connections exceeds 10000 ", another of which includes: "alarm time: 09 month 13 day 16 in 2021: 54: 25; alarm system components: MySQL; and alarming IP address: 10.157.23 a.24c; alarm influence coefficient: 10; alarm level: severe; and (3) alarm rule description: SQL executes for more than 1 minute. "(a, b, c are all constants). The chaos experiment execution file generating device extracts the IP addresses of the alarm components according to the two pieces of alarm information, inquires system architecture information from the first database, and determines that the two pieces of alarm information are alarm information under the same system architecture and are related alarm information sent by different system components caused by the same fault. Then, inputting key alarm data (such as alarm rule description, alarm influence coefficient and the like) and system architecture information of the two pieces of alarm information into a chaotic experiment classification model trained according to the chaotic experiment classification model training method, wherein the chaotic experiment classification model outputs chaotic experiment type information corresponding to the two pieces of alarm information according to the alarm information and the system architecture information: high concurrency calls. The corresponding failure directly results in too many concurrencies (over 10000) for the Spring Boot service and subsequently results in slow execution of MySQL response for over 1 minute. Then, the chaotic experiment execution file generation device queries in the second database according to the chaotic experiment type information, determines an execution file template corresponding to the high concurrency call (corresponding to this example, the execution file template may be a string of execution codes of the high concurrency experiment), extracts an IP address in the alarm information, supplements the execution file template, and obtains an available chaotic experiment execution file. Using the chaos experiment execution file to perform the following chaos experiment on a computer system: 10000 concurrent requests are made to the server with the IP address of 10.157.23a.24b, so that the chaotic experiment test is completed.
It should be noted that the above examples are only for the convenience of understanding the embodiments of the present disclosure, and do not serve as any limitation to the embodiments of the present disclosure.
In summary, in the chaotic experiment execution file generation method in the embodiment of the disclosure, since at least one piece of alarm information sent by a system component in a computer system fault can be acquired, then the system architecture information of the system component corresponding to each piece of alarm information is determined, the system architecture information is used for indicating the topological relation among the system components, then the at least one piece of alarm information and the system architecture information of the system component corresponding to the alarm information are input into a chaotic experiment classification model trained in advance to obtain at least one piece of chaotic experiment type information, and finally an execution file is respectively generated for each piece of chaotic experiment type information, in the embodiment of the disclosure, the chaotic experiment test of the computer system is associated with the alarm information of the fault of the computer system, and corresponding chaotic experiment type information and chaotic experiment execution files can be automatically output for different fault types, and the rationality of the chaotic experiment can be ensured, so that the technical difficulty in designing the chaotic experiment is greatly reduced, the time of technicians is greatly saved, and the generation efficiency of chaotic experiment execution files is improved.
Referring to the block diagram in fig. 4, a chaotic experiment execution file generation apparatus 100 for generating an execution file for performing a chaotic experiment on a computer system in the embodiment of the present disclosure is shown, including:
an obtaining module 110, configured to obtain at least one alarm message sent by a system component in a computer system failure;
a first determining module 120, configured to determine system architecture information of system components corresponding to each piece of alarm information, where the system architecture information is used to indicate a topological relationship between the system components;
a second determining module 130, configured to input the at least one piece of alarm information and the system architecture information of the system component corresponding to the alarm information into a pre-trained chaotic experiment classification model to obtain at least one piece of chaotic experiment type information;
the generating module 140 is configured to generate one execution file for each chaotic experiment type.
In one embodiment, the chaos experimental classification model is obtained by training as follows: obtaining a plurality of sample data and performing word segmentation processing on the sample data to obtain at least one sample word segmentation, wherein the sample data comprises historical alarm information, system architecture information of a system component corresponding to the historical alarm information and chaotic experiment type information, and the historical alarm information is alarm information sent by the system component in a history recording computer system fault; respectively carrying out word vector conversion on each sample word segmentation to obtain a sample word vector; obtaining training sample data, wherein the training sample data comprises the sample word vector and label information, and the label information is used for indicating the corresponding relation between the historical alarm information and the system architecture information corresponding to the sample word vector and the chaotic experiment type information; and inputting the training sample data into a classification model to be trained for training to obtain the chaos experiment classification model.
In one embodiment, the historical alarm information at least includes: the alarm rule description is used for indicating the type of the fault corresponding to the historical alarm information, and the alarm influence coefficient is used for indicating the influence degree of the fault on the computer system.
In one embodiment, the second determining module 130 is specifically configured to: determining the alarm information of the same fault as an alarm information group according to the system architecture information of the system component corresponding to the at least one alarm information; and respectively inputting the alarm information included by each alarm information group and the system architecture information of the system component corresponding to the alarm information into the chaotic experiment classification model to obtain at least one chaotic experiment type information.
In one embodiment, the second determining module 130 is specifically configured to: extracting key alarm data from each alarm information included in each alarm information group, wherein the key alarm data comprise at least one of an IP address, a system component name, an alarm rule description and an alarm influence coefficient corresponding to a system component; and respectively inputting the key alarm data extracted from each alarm information group and the system architecture information of the system component corresponding to each alarm information in the alarm information group into the chaotic experiment classification model.
In one embodiment, the first determining module 120 is specifically configured to: extracting the IP address of the system component corresponding to the alarm information from each alarm information; and acquiring system architecture information of the system component corresponding to the alarm information according to the extracted IP address.
In one embodiment, the generating module 140 is specifically configured to: performing for each of the chaotic experiment types: and aiming at each chaotic experiment type information, determining an execution file template corresponding to the chaotic experiment type information, and generating one execution file based on the execution file template.
In one embodiment, the generating module 140 is specifically configured to: and aiming at each chaotic experiment type information, extracting key information from the alarm information included in the alarm information group corresponding to the chaotic experiment type information, inputting the key information into the execution file template corresponding to the chaotic experiment type information, and obtaining the execution file corresponding to the chaotic experiment type information.
In one embodiment, the key information includes: and the IP address of the system component corresponding to the alarm information.
The chaotic experiment execution file generation device 100 in the embodiment of the present disclosure corresponds to the chaotic experiment execution file generation method in the foregoing embodiment, and related contents thereof can be understood with reference to the chaotic experiment execution file generation method described above, which is not described herein again.
In the chaotic experiment execution file generation device 100 in the disclosed embodiment, since the obtaining module 110 can obtain at least one piece of alarm information sent by a system component in a computer system fault, then the first determining module 120 can determine the system architecture information of the system component corresponding to each piece of alarm information, the system architecture information is used for indicating the topological relation between the system components, then the second determining module 130 can input the at least one piece of alarm information and the system architecture information of the system component corresponding to the alarm information into a chaotic experiment classification model trained in advance to obtain at least one piece of chaotic experiment type information, and finally the generating module 140 can generate an execution file for each chaotic experiment type, the chaotic experiment test of the computer system is associated with the alarm information of the computer system fault in the disclosed embodiment, the chaotic experiment device can automatically output corresponding chaotic experiment type information and chaotic experiment execution files for different fault types, and can ensure the rationality of the chaotic experiment, thereby greatly reducing the technical difficulty of designing the chaotic experiment, greatly saving the time of technicians and improving the generation efficiency of the chaotic experiment execution files.
An exemplary embodiment of the present disclosure also provides an electronic device including: at least one processor; and a memory communicatively coupled to the at least one processor. The memory stores a computer program executable by the at least one processor, the computer program, when executed by the at least one processor, is for causing the electronic device to perform a chaotic experiment execution file generation method according to an embodiment of the present disclosure.
The disclosed exemplary embodiments also provide a non-transitory computer readable storage medium storing a computer program, wherein the computer program, when executed by a processor of a computer, is configured to cause the computer to perform the chaotic experiment execution file generation method according to the disclosed embodiments.
The exemplary embodiments of the present disclosure also provide a computer program product comprising a computer program, wherein the computer program, when executed by a processor of a computer, is configured to cause the computer to execute the chaotic experiment execution file generation method according to the embodiments of the present disclosure.
Referring to fig. 5, a block diagram of a structure of an electronic device 500, which may be a server or a client of the present disclosure, which is an example of a hardware device that may be applied to aspects of the present disclosure, will now be described. Electronic device is intended to represent various forms of digital electronic computer devices, such as laptops, desktops, workstations, personal digital assistants, servers, blade servers, mainframes, and other suitable computers. The electronic device may also represent various forms of mobile devices, such as personal digital processing, cellular phones, smart phones, wearable devices, and other similar computing devices. The components shown herein, their connections and relationships, and their functions, are meant to be examples only, and are not meant to limit implementations of the disclosure described and/or claimed herein.
As shown in fig. 5, the electronic device 500 includes a computing unit 501, which can perform various appropriate actions and processes according to a computer program stored in a Read Only Memory (ROM) 502 or a computer program loaded from a storage unit 508 into a Random Access Memory (RAM) 503. In the RAM 503, various programs and data required for the operation of the device 500 can also be stored. The calculation unit 501, the ROM 502, and the RAM 503 are connected to each other by a bus 504. An input/output (I/O) interface 505 is also connected to bus 504.
A number of components in the electronic device 500 are connected to the I/O interface 505, including: an input unit 506, an output unit 507, a storage unit 508, and a communication unit 509. The input unit 506 may be any type of device capable of inputting information to the electronic device 500, and the input unit 506 may receive input numeric or character information and generate key signal inputs related to user settings and/or function controls of the electronic device. Output unit 507 may be any type of device capable of presenting information and may include, but is not limited to, a display, speakers, a video/audio output terminal, a vibrator, and/or a printer. Storage unit 504 may include, but is not limited to, magnetic or optical disks. The communication unit 509 allows the electronic device 500 to exchange information/data with other devices via a computer network, such as the internet, and/or various telecommunications networks, and may include, but is not limited to, modems, network cards, infrared communication devices, wireless communication transceivers and/or chipsets, such as bluetooth (TM) devices, WiFi devices, WiMax devices, cellular communication devices, and/or the like.
The computing unit 501 may be a variety of general-purpose and/or special-purpose processing components having processing and computing capabilities. Some examples of the computing unit 501 include, but are not limited to, a Central Processing Unit (CPU), a Graphics Processing Unit (GPU), various dedicated Artificial Intelligence (AI) computing chips, various computing units running machine learning model algorithms, a Digital Signal Processor (DSP), and any suitable processor, controller, microcontroller, and so forth. The calculation unit 501 performs the respective methods and processes described above. For example, in some embodiments, the chaotic experiment execution file generation method described above may be implemented as a computer software program tangibly embodied in a machine-readable medium, such as storage unit 508. In some embodiments, part or all of the computer program may be loaded and/or installed onto the electronic device 500 via the ROM 502 and/or the communication unit 509. In some embodiments, the computing unit 501 may be configured to perform the chaotic experiment execution file generation method described above in any other suitable manner (e.g., by way of firmware).
The program code for implementing the chaotic experiment execution file generation method of the embodiments of the present disclosure may be written in any combination of one or more programming languages. These program codes may be provided to a processor or controller of a general purpose computer, special purpose computer, or other programmable data processing apparatus, such that the program codes, when executed by the processor or controller, cause the functions/operations specified in the flowchart and/or block diagram to be performed. The program code may execute entirely on the machine, partly on the machine, as a stand-alone software package partly on the machine and partly on a remote machine or entirely on the remote machine or server.
In the context of this disclosure, a machine-readable medium may be a tangible medium that can contain, or store a program for use by or in connection with an instruction execution system, apparatus, or device. The machine-readable medium may be a machine-readable signal medium or a machine-readable storage medium. A machine-readable medium may include, but is not limited to, an electronic, magnetic, optical, electromagnetic, infrared, or semiconductor system, apparatus, or device, or any suitable combination of the foregoing. More specific examples of a machine-readable storage medium would include an electrical connection based on one or more wires, a portable computer diskette, a hard disk, a Random Access Memory (RAM), a read-only memory (ROM), an erasable programmable read-only memory (EPROM or flash memory), an optical fiber, a portable compact disc read-only memory (CD-ROM), an optical storage device, a magnetic storage device, or any suitable combination of the foregoing.
As used in this disclosure, the terms "machine-readable medium" and "computer-readable medium" refer to any computer program product, apparatus, and/or device (e.g., magnetic discs, optical disks, memory, Programmable Logic Devices (PLDs)) used to provide machine instructions and/or data to a programmable processor, including a machine-readable medium that receives machine instructions as a machine-readable signal. The term "machine-readable signal" refers to any signal used to provide machine instructions and/or data to a programmable processor.
To provide for interaction with a user, the systems and techniques described here can be implemented on a computer having: a display device (e.g., a CRT (cathode ray tube) or LCD (liquid crystal display) monitor) for displaying information to a user; and a keyboard and a pointing device (e.g., a mouse or a trackball) by which a user can provide input to the computer. Other kinds of devices may also be used to provide for interaction with a user; for example, feedback provided to the user can be any form of sensory feedback (e.g., visual feedback, auditory feedback, or tactile feedback); and input from the user may be received in any form, including acoustic, speech, or tactile input.
The systems and techniques described here can be implemented in a computing system that includes a back-end component (e.g., as a data server), or that includes a middleware component (e.g., an application server), or that includes a front-end component (e.g., a user computer having a graphical user interface or a web browser through which a user can interact with an implementation of the systems and techniques described here), or any combination of such back-end, middleware, or front-end components. The components of the system can be interconnected by any form or medium of digital data communication (e.g., a communication network). Examples of communication networks include: local Area Networks (LANs), Wide Area Networks (WANs), and the Internet.
The computer system may include clients and servers. A client and server are generally remote from each other and typically interact through a communication network. The relationship of client and server arises by virtue of computer programs running on the respective computers and having a client-server relationship to each other.
As for the embodiments of the apparatus, the electronic device, the computer storage medium, and the computer program product, since they are substantially similar to the embodiments of the chaotic experiment execution file generation method, the description is simple, and relevant points can be found in the partial description of the embodiments of the chaotic experiment execution file generation method.
Finally, it should be noted that: the above embodiments are only used for illustrating the technical solutions of the embodiments of the present disclosure, and not for limiting the same; although the present disclosure has been described in detail with reference to the foregoing embodiments, it should be understood by those of ordinary skill in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some technical features may be equivalently replaced; and such modifications or substitutions do not depart from the spirit and scope of the corresponding technical solutions of the embodiments of the present disclosure.

Claims (11)

1. A chaotic experiment execution file generation method is used for generating an execution file for chaotic experiments of a computer system, and comprises the following steps:
acquiring at least one alarm message sent by a system component in a computer system fault;
determining system architecture information of the system component corresponding to each alarm information, including: extracting the IP address of the system component corresponding to the alarm information from each alarm information; acquiring system architecture information of a system component corresponding to the alarm information according to the extracted IP address; wherein the system architecture information is used to indicate topological relationships between system components;
inputting the at least one piece of alarm information and the system architecture information of the system component corresponding to the alarm information into a pre-trained chaotic experiment classification model to obtain at least one piece of chaotic experiment type information;
the chaos experiment classification model is obtained by training in the following way: obtaining a plurality of sample data and performing word segmentation processing on the sample data to obtain at least one sample word segmentation, wherein the sample data comprises historical alarm information, system architecture information of a system component corresponding to the historical alarm information and chaotic experiment type information, and the historical alarm information is alarm information sent by the system component in a history recording computer system fault; respectively carrying out word vector conversion on each sample word segmentation to obtain a sample word vector; obtaining training sample data, wherein the training sample data comprises the sample word vector and label information, and the label information is used for indicating the corresponding relation between the historical alarm information and the system architecture information corresponding to the sample word vector and the chaotic experiment type information; inputting the training sample data into a classification model to be trained for training to obtain the chaos experiment classification model;
and respectively generating one execution file aiming at each chaotic experiment type information.
2. The chaotic experiment execution file generation method according to claim 1, wherein the historical alarm information at least comprises: the alarm rule description is used for indicating the type of the fault corresponding to the historical alarm information, and the alarm influence coefficient is used for indicating the influence degree of the fault on the computer system.
3. The chaotic experiment execution file generation method according to claim 1, wherein the inputting the at least one piece of alarm information and the system architecture information of the system component corresponding to the alarm information into a chaotic experiment classification model trained in advance to obtain at least one piece of chaotic experiment type information comprises:
determining the alarm information of the same fault as an alarm information group according to the system architecture information of the system component corresponding to the at least one alarm information;
and respectively inputting the alarm information included by each alarm information group and the system architecture information of the system component corresponding to the alarm information into the chaotic experiment classification model to obtain at least one chaotic experiment type information.
4. The chaotic experiment execution file generation method according to claim 3, wherein the inputting of the alarm information included in each alarm information group and the system architecture information of the system component corresponding to the alarm information into the chaotic experiment classification model respectively comprises:
extracting key alarm data from each alarm information included in each alarm information group, wherein the key alarm data comprise at least one of an IP address, a system component name, an alarm rule description and an alarm influence coefficient corresponding to a system component;
and respectively inputting the key alarm data extracted from each alarm information group and the system architecture information of the system component corresponding to each alarm information in the alarm information group into the chaotic experiment classification model.
5. The chaotic experiment execution file generation method according to claim 1, wherein the generating one execution file for each chaotic experiment type information, respectively, comprises:
and aiming at each chaotic experiment type information, determining an execution file template corresponding to the chaotic experiment type information, and generating one execution file based on the execution file template.
6. The chaotic experiment execution file generation method according to claim 5, wherein the generating one of the execution files based on the execution file template comprises:
and aiming at each chaotic experiment type information, extracting key information from the alarm information included in the alarm information group corresponding to the chaotic experiment type information, inputting the key information into the execution file template corresponding to the chaotic experiment type information, and obtaining the execution file corresponding to the chaotic experiment type information.
7. The chaotic experiment execution file generation method of claim 6, wherein the key information comprises: and the IP address of the system component corresponding to the alarm information.
8. A chaos experiment execution file generating device is used for generating an execution file for chaos experiment of a computer system, and comprises the following components:
the system comprises an acquisition module, a processing module and a processing module, wherein the acquisition module is used for acquiring at least one alarm message sent by a system component in the computer system failure;
the first determining module is used for determining system architecture information of the system components corresponding to each alarm message, wherein the system architecture information is used for indicating a topological relation among the system components;
the second determining module is used for inputting the at least one piece of alarm information and the system architecture information of the system component corresponding to the alarm information into a pre-trained chaotic experiment classification model to obtain at least one piece of chaotic experiment type information;
and the generating module is used for respectively generating one execution file according to each chaotic experiment type information.
9. An electronic device, comprising:
a processor; and
a memory for storing a program, wherein the program is stored in the memory,
wherein the program comprises instructions which, when executed by the processor, cause the processor to perform the chaotic experiment execution file generation method according to any one of claims 1 to 7.
10. A non-transitory computer readable storage medium storing computer instructions for causing a computer to perform the chaotic experiment execution file generation method according to any one of claims 1 to 7.
11. A computer program product comprising a computer program, wherein the computer program, when executed by a processor, implements the chaotic experiment execution file generation method of any one of claims 1-7.
CN202111409366.0A 2021-11-25 2021-11-25 Chaotic experiment execution file generation method and device, electronic equipment and storage medium Active CN113835987B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN202111409366.0A CN113835987B (en) 2021-11-25 2021-11-25 Chaotic experiment execution file generation method and device, electronic equipment and storage medium

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN202111409366.0A CN113835987B (en) 2021-11-25 2021-11-25 Chaotic experiment execution file generation method and device, electronic equipment and storage medium

Publications (2)

Publication Number Publication Date
CN113835987A CN113835987A (en) 2021-12-24
CN113835987B true CN113835987B (en) 2022-04-15

Family

ID=78971722

Family Applications (1)

Application Number Title Priority Date Filing Date
CN202111409366.0A Active CN113835987B (en) 2021-11-25 2021-11-25 Chaotic experiment execution file generation method and device, electronic equipment and storage medium

Country Status (1)

Country Link
CN (1) CN113835987B (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN115081410A (en) * 2022-07-19 2022-09-20 中电金信软件有限公司 Method and device for automatically generating experiment report

Family Cites Families (7)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103699111B (en) * 2013-09-26 2016-04-06 青岛海信网络科技股份有限公司 The fault detection method of distributed monitoring system and device
CN108664374B (en) * 2018-05-17 2020-05-08 腾讯科技(深圳)有限公司 Fault alarm model creating method and device and fault alarm method and device
CN110765023B (en) * 2019-10-29 2023-10-27 中国工商银行股份有限公司 Distributed system testing method and system based on chaos experiment
US11397665B2 (en) * 2020-02-20 2022-07-26 Jpmorgan Chase Bank, N.A. Chaos engineering trials
CN112612715A (en) * 2020-12-30 2021-04-06 平安壹钱包电子商务有限公司 System testing method and device based on chaotic engineering, computer equipment and storage medium
CN113238924B (en) * 2021-04-09 2023-09-15 杭州欧若数网科技有限公司 Chaotic engineering realization method and system in distributed graph database system
CN113553210A (en) * 2021-07-30 2021-10-26 平安普惠企业管理有限公司 Alarm data processing method, device, equipment and storage medium

Also Published As

Publication number Publication date
CN113835987A (en) 2021-12-24

Similar Documents

Publication Publication Date Title
JP7373611B2 (en) Log auditing methods, equipment, electronic equipment, media and computer programs
US20220350690A1 (en) Training method and apparatus for fault recognition model, fault recognition method and apparatus, and electronic device
CN116089231B (en) Fault alarm method and device, electronic equipment and storage medium
CN113835987B (en) Chaotic experiment execution file generation method and device, electronic equipment and storage medium
CN112612664A (en) Electronic equipment testing method and device, electronic equipment and storage medium
CN113377614A (en) Generation method and device of call chain information, electronic equipment and storage medium
CN115357450A (en) Node maintenance method and device based on artificial intelligence, computer equipment and medium
EP3011454A1 (en) Generating a fingerprint representing a response of an application to a simulation of a fault of an external service
CN113641544A (en) Method, apparatus, device, medium and product for detecting application status
CN117033058A (en) Analysis method, device, equipment and medium for software crash data
CN116089985A (en) Encryption storage method, device, equipment and medium for distributed log
CN115794473A (en) Root cause alarm positioning method, device, equipment and medium
CN112989797B (en) Model training and text expansion methods, devices, equipment and storage medium
CN114444087A (en) Unauthorized vulnerability detection method and device, electronic equipment and storage medium
CN113238765B (en) Method, device, equipment and storage medium for distributing small program
CN113138903B (en) Method and apparatus for tracking performance of a storage system
CN113760765B (en) Code testing method and device, electronic equipment and storage medium
WO2024066622A1 (en) Cloud system testing method and apparatus
CN113239296B (en) Method, device, equipment and medium for displaying small program
CN117112873B (en) API blasting method, device, equipment and storage medium based on code injection
JP7349012B2 (en) Methods, devices and electronic devices for monitoring wake-up indicators
CN115357420A (en) Virtual machine fault positioning method and device, electronic equipment and storage medium
CN115426143A (en) Method, device, equipment and storage medium for identifying abnormal identity
CN116302086A (en) Application processing method and device, electronic equipment and readable storage medium
CN116150031A (en) Program performance test early warning method, device, equipment and storage medium

Legal Events

Date Code Title Description
PB01 Publication
PB01 Publication
SE01 Entry into force of request for substantive examination
SE01 Entry into force of request for substantive examination
GR01 Patent grant
GR01 Patent grant