A method and device for simulating power-on and power-off of equipment in a cloud environment

By adopting global network topology visual monitoring design and automated management technology in the cloud environment, multi-level unified monitoring and cross-level traceability are realized, and multi-device and multi-node power-up simulation drills are supported, which solves the problem of comprehensive coverage of complex situations in the existing technology and The lack of comprehensive monitoring and evaluation issues has improved the efficiency and reliability of the drill.

CN117873812BActive Publication Date: 2025-02-21INFORMATION & COMM BRANCH OF STATE GRID JIANGSU ELECTRIC POWER
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202311554720.8
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2023-11-20
Publication Date
2025-02-21
Estimated Expiration
2043-11-20

AI Technical Summary

Technical Problem

The existing power-up and down drilling methods for cloud environment equipment cannot fully cover a variety of complex situations, and the lack of comprehensive monitoring and evaluation has led to the failure to detect vulnerabilities and problems in a timely manner.

Method used

Adopt global network topology visual monitoring design to realize multi-level unified monitoring and cross-level traceability visual display of global topology structure, support random or designated multi-device and multi-node power-up simulation, and automatically monitor and track the entire process, collect power-up and down operation. and operation records, and automatically generate drill reports.

Benefits of technology

It improves the efficiency and reliability of equipment management, reduces human errors during the simulation drill, improves the efficiency of the simulation drill, and provides comprehensive data support after the drill, helping users understand the situation at different stages of the equipment start-stop process.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN117873812B_ABST
    Figure CN117873812B_ABST
Patent Text Reader

Abstract

The present invention discloses a method for simulating power-on and power-off drills of devices in a cloud environment, including: stratifying logs according to the sources of logs during the power-on and power-off process of the devices; calculating the weights of different log events; collecting anomalies that appear in historical logs, determining the event types contained in the historical logs, and for each event type, stratifying and counting the frequency of its occurrence in the logs, and setting the alarm thresholds of different log events based on weighted entropy increase; generating a global topology map; creating and executing power-on and power-off drill tasks, and collecting the state changes of each node during the power-on and power-off drill process according to the logical association of all topology maps, and automatically generating a simulation drill report for the power-on and power-off drill task. The present invention can realize the visualization display of the global topology structure with multi-level unified monitoring and cross-level traceability, support random or specified multi-device multi-node power-on and power-off simulation, automatically generate a drill report, and provide comprehensive data support for the review after the drill is completed.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present invention relates to the technical field of cloud environment disaster recovery simulation drill, and in particular to a method and device for simulating power on and off drill of equipment in a cloud environment. Background Art

[0002] With the vigorous development of cloud environment, the existing State Grid cloud platform carries 71 business systems such as the new generation of power trading and marketing 2.0. There are many internal components with high integration and large equipment scale. Once the regional power outage occurs in the computer room, the system recovery status cannot be guaranteed, and the business is affected, which may cause unpredictable serious consequences. As the pace of business migration to the cloud is getting faster and faster, the importance of the safe and stable operation of the cloud platform itself is becoming more and more prominent.

[0003] In the existing cloud environment equipment power-on and power-off drill methods, the drill scenarios are only for some equipment and do not cover the drills of various complex situations; there are no records of operations in many key links, resulting in irregular drill reports; the drill cycle is long, and failures cannot be responded to and handled quickly. There is a lack of comprehensive monitoring and evaluation after the drill, and in most cases there are vulnerabilities and problems that are not discovered in time. Summary of the invention

[0004] The purpose of the present invention is to propose a method and device for simulating power on and off of equipment in a cloud environment, combined with the global network topology visualization monitoring design, to achieve multi-level unified monitoring and cross-level traceability of the global topology structure visualization display, and support random or specified multi-device multi-node power on and off simulation; in addition, the present invention automatically monitors and tracks the entire process of the drill, collects the operation and operation records of the entire process of power on and off, promptly notifies the relevant personnel of abnormal information, and automatically generates a drill report to provide comprehensive data support for the review after the drill is completed.

[0005] In order to achieve the above technical objectives, the technical solution adopted by the present invention is:

[0006] The present invention discloses a device power-on and power-off simulation drill method in a cloud environment, and the device power-on and power-off simulation drill method comprises the following steps:

[0007] Step A: Divide the logs into five layers according to the log sources during the device power-on and power-off process: device layer logs, virtual layer logs, system layer logs, middleware logs, and application logs;

[0008] Step B, based on the hierarchical results, for each level of log information, set the parent level weight of each level and the sub-level weight of the log sub-level contained in each level according to their respective importance and priority; design and score the level division of log events at each level according to the actual business needs, and obtain the level hierarchy and level weight of the log; and obtain the weights of different log events by comprehensive calculation;

[0009] Step C, collecting anomalies appearing in historical logs, determining the event types contained in the historical logs, hierarchically counting the frequency of each event type appearing in the logs, and setting alarm thresholds for different log events based on weighted entropy increase;

[0010] Step D: Group and associate the global topology nodes. They are divided into four groups according to the level: device layer, virtual layer, middleware, and application layer. Small groups are established in each level according to their respective facilities or clusters. In each group, nodes are created for key devices, components, and instances. Nodes with associated indicators or functions are created according to business needs. At the same time, mapping relationships are designed between nodes for association. Monitoring trigger conditions are set between associated nodes and business semantics are configured. Different colors are used to identify the current start and stop status of nodes to generate a global topology map.

[0011] Step E: Create and execute power-on and power-off drill tasks based on the global topology map, collect state changes of each node during the power-on and power-off drill according to the logical association of all topology maps, and automatically generate a simulation drill report for the power-on and power-off drill tasks.

[0012] Further, in step A, the device layer log is used to record the operation logs of physical servers, network devices, and storage devices, including power on / off logs, network connection logs, and storage read / write logs. The log content includes device number, model, location, real-time operation status, operation content, operation time, operator, fault content, CPU / memory usage, throughput, delay data, voltage, current, signal strength, and signal-to-noise ratio;

[0013] The virtual layer log is used to record the life cycle, configuration changes, resource utilization and status information of virtual machines and containers;

[0014] The system layer log is used to collect operation logs, access logs, and error logs of the operating system, cluster management system, and database;

[0015] The middleware log is used to collect the operating indicators and logs of the web server, cache, and message queue;

[0016] The application log is used to collect the program's running log and error log.

[0017] Furthermore, in step B, the process of comprehensively calculating the weights of different log events includes the following steps:

[0018] Step B1, based on the hierarchical result, for each level of log information, the parent level weight of each level and the sub-level weight of the log sub-level contained in each level are set according to their respective importance and priority;

[0019] Step B2, according to the actual business needs, the log events at each level are divided into three levels: high-level logs, medium-level logs and low-level logs, and the level scores are set for different levels, and then the level weights are set for the log events at different levels; among them, the connection and disconnection events of the hardware media in the device layer log, and the start and stop changes of the components under the four levels of logs, namely, the virtual layer log, the system layer log, the middleware log and the application log, are set as high-level logs; the voltage and current, configuration changes, and operation indicators are set as medium-level logs; the changes in signal strength and signal-to-noise ratio and other parameters are set as low-level logs;

[0020] Step B3, use the following formula to comprehensively calculate the weights of different log events:

[0021] w i =w i,1 ×0.4+w i,2 ×0.3+w i,3 ×0.3

[0022] Among them, w i is the weight of log event i, w i,1 is the parent class hierarchy weight to which log event i belongs, w i,2 is the subclass hierarchy weight to which log event i belongs, w i,3 is the level weight of log event i.

[0023] Furthermore, in step C, the anomalies appearing in the historical logs are collected, the event types contained in the historical logs are determined, and for each event type, the frequency of occurrence in the logs is hierarchically counted. The process of setting the alarm thresholds for different log events based on weighted entropy increase includes the following steps:

[0024] Collect the anomalies in the historical logs, determine the event types contained in the logs, and perform hierarchical statistics on the frequency of occurrence of each event type corresponding to each anomaly. Use the weighted entropy increase formula combined with the weight of the log event to perform weighted calculation processing to obtain the weighted entropy increase H corresponding to the log event i. i :

[0025] H i =-Σ(P i × i ×log2(P i × i ))

[0026] Among them, P i represents the frequency of log event i in the log, w i Represents the weight of log event i, weighted entropy increase H i The larger the value of , the higher the priority and importance of log event i;

[0027] Based on log stratification, weighted entropy increase H based on log event i i Set the corresponding alarm threshold for log event i to trigger an alarm notification of the corresponding level.

[0028] Furthermore, in step D, the process of generating the global topology map includes the following steps:

[0029] The global topology nodes are grouped and associated, and divided into four major groups according to the level: device layer, virtual layer, middleware and application layer. Small groups are established in each level according to their respective facilities or clusters. Among them, the device layer is divided according to assets, the virtual layer is divided according to virtual machine clusters, the middleware layer is divided according to middleware clusters, and the application layer is divided according to application systems;

[0030] In each group, nodes are created for key equipment, components, and instances. Nodes with associated indicators or functions are created according to business needs. At the same time, mapping relationships are designed between nodes for association. Key attributes including start and stop instructions are configured for each node, and key attribute labels are set.

[0031] Set monitoring trigger conditions and configure business semantics between associated nodes. Use different colors to identify the current start and stop status of nodes for monitoring node status and associated display. The setting of monitoring trigger conditions between nodes is divided into status monitoring including start, connection, and stop, and abnormal event monitoring.

[0032] Among them, status monitoring refers to setting connection status monitoring instructions between associated nodes, and establishing dependency relationships between nodes. When a node starts or stops, an event notification is sent to the associated node. According to the connection status between the monitored associated nodes, the association identifier between the nodes is updated to display the connection or disconnection status; abnormal event monitoring refers to setting trigger conditions for the node. When a node fails, the monitoring of its associated nodes is triggered, and the monitoring of the fault impact range is automatically carried out.

[0033] Furthermore, in step E, the process of creating and executing the power-on and power-off drill task based on the global topology map includes the following steps:

[0034] Based on the global topology, a power-on and power-off drill task is created. The drill task includes the node scheduled power-off time, multiple node selections, scheduled power-on time, and whether to enable automatic task log collection settings.

[0035] After the task is started, a log monitoring task will be automatically created 5 minutes before the stop time, and log monitoring will be automatically started;

[0036] When the power-off time is reached, the stop operation instructions of each node are automatically executed, and the log and topology monitoring automatically record the status and abnormalities of each device;

[0037] When the power-on time is reached, the startup and running instructions configured for each node are automatically executed to confirm that each node is enabled normally and that the log has no abnormalities within 2 minutes, then the collection is automatically stopped, or the collection can be stopped manually.

[0038] Furthermore, in step E, the process of creating and executing the power-on and power-off drill task based on the global topology map further includes the following steps:

[0039] Create a random task, configure the power-on and power-off timing, select multiple random power-off groups, and generate random node power-on and power-off drill tasks.

[0040] Furthermore, when the global topology map detects that the upstream node is in a node stop state, the connection between the associated nodes is changed to a disconnected state. If the abnormal upstream node is not started normally and successfully connected within 30 minutes, the configuration of the associated downstream node is automatically switched to other nodes that can be connected normally in the same group as the abnormal upstream node, and an alarm is generated for the abnormal information to be notified to the relevant person in charge for investigation and processing.

[0041] Furthermore, in step E, according to the logical association of all topological diagrams, the state changes of each node during the power-on and power-off drill are collected, and the process of automatically generating a simulation drill report for the power-on and power-off drill task includes the following steps:

[0042] Before the simulated power-on and power-off drill begins, the drill tasks are parsed, the simulated device numbers and key node numbers are confirmed, and the key node status monitoring and log collection are enabled; during the drill, the node status changes are monitored in real time through the global topology map, and key node logs are collected at the same time; after the drill, the key node logs are parsed, and the key node status changes and timestamps are automatically extracted, as well as the abnormal logs of the associated nodes;

[0043] Analyze and count the abnormal logs generated by the associated nodes and generate abnormal log reports;

[0044] According to the logical association of the topology diagram, the state changes of each key node during the power-on and power-off drill are collected, including the node name, state item, initial state, time of each state change, new state after the change and description, and a state record table for each stage and a process description table for each node state change are generated; among which, the description is used to reflect the state changes of downstream nodes caused by the state changes of upstream nodes;

[0045] Combined with the state change timestamp, simulation equipment number, key node number, operation records of each stage, state record table of each stage, abnormal log report and process description table, a simulation exercise report is automatically generated for the exercise task.

[0046] The present invention also discloses a device power-on and power-off simulation drill device in a cloud environment, and the device power-on and power-off simulation drill device comprises:

[0047] The log layering module is used to divide the logs into five layers according to the log sources during the device power-on and power-off process: device layer logs, virtual layer logs, system layer logs, middleware logs, and application logs;

[0048] The log event weight calculation module is used to set the parent class weight of each level and the subclass weight of each level of log information according to their respective importance and priority based on the hierarchical results; design and score the level of log events at each level according to the actual business needs, and obtain the level level and level weight of the log; and obtain the weights of different log events through comprehensive calculation;

[0049] The alarm threshold setting module is used to collect anomalies in historical logs, determine the event types contained in the historical logs, and for each event type, perform hierarchical statistics on its frequency P in the logs, and set alarm thresholds for different log events based on weighted entropy increase;

[0050] The topology map generation module is used to group and associate global topology nodes. It is divided into four major groups according to the hierarchy: device layer, virtual layer, middleware, and application layer. Small groups are established in each layer according to their respective facilities or clusters. In each group, nodes are created for key devices, components, and instances. Nodes with associated indicators or functions are created according to business needs. At the same time, mapping relationships are designed between nodes for association. Monitoring trigger conditions are set between associated nodes and business semantics are configured. Different colors are used to identify the current start and stop status of nodes to generate a global topology map.

[0051] The report generation module is used to create and execute power-on and power-off drill tasks based on the global topology map. According to the logical association of all topology maps, the state changes of each node during the power-on and power-off drill process are collected, and a simulation drill report for the power-on and power-off drill task is automatically generated.

[0052] Compared with the prior art, the present invention has the following beneficial effects:

[0053] First, the method and device for simulating power on and off of equipment in a cloud environment of the present invention, combined with the global network topology visualization monitoring design, realizes a visualized display of a global topology structure with multi-level unified monitoring and cross-level traceability, supports random or specified power on and off simulation of multiple devices and multiple nodes, improves the efficiency and reliability of equipment management, reduces human error operations during simulation exercises, and improves the efficiency of simulation exercises.

[0054] Second, the method and device for simulating power-on and power-off drills of equipment in a cloud environment of the present invention automatically monitor and track the entire drill process, collect the operation and operation records of the entire power-on and power-off process, promptly notify the relevant personnel of abnormal information, and automatically generate a drill report to help users more clearly understand the conditions at different stages of the equipment startup and shutdown process, and provide comprehensive data support for review after the drill is completed. BRIEF DESCRIPTION OF THE DRAWINGS

[0055] Figure 1 A schematic diagram of a log hierarchical structure according to an embodiment of the present invention;

[0056] Figure 2 A schematic diagram of a topological structure of an embodiment of the present invention;

[0057] Figure 3 This is a flow chart of a device power-on and power-off simulation drill method in a cloud environment according to an embodiment of the present invention. DETAILED DESCRIPTION

[0058] The embodiments of the present invention are further described in detail below in conjunction with the accompanying drawings.

[0059] See also Figure 3 The embodiment of the present invention discloses a device power-on and power-off simulation drill method in a cloud environment, and the device power-on and power-off simulation drill method comprises the following steps:

[0060] In step A, logs are divided into five layers according to the log sources during the power-on and power-off process of the device: device layer logs, virtual layer logs, system layer logs, middleware logs, and application logs.

[0061] Step B, based on the stratification results, for each level of log information, set the parent level weight of each level and the sub-level weight of the log sub-level contained in each level according to their respective importance and priority; according to the actual business needs, design and score the level division of log events at each level to obtain the level hierarchy and level weight of the log; and comprehensively calculate the weights of different log events.

[0062] Step C, collects anomalies appearing in historical logs, determines the event types contained in the historical logs, and for each event type, performs hierarchical statistics on its frequency of occurrence in the logs, and sets alarm thresholds for different log events based on weighted entropy increase.

[0063] Step D: Group and associate the global topology nodes. They are divided into four major groups according to the hierarchy: device layer, virtual layer, middleware, and application layer. Small groups are established in each layer according to their respective facilities or clusters. In each group, nodes are created for key devices, components, and instances. Nodes with associated indicators or functions are created according to business needs. At the same time, mapping relationships are designed between nodes for association. Monitoring trigger conditions are set between associated nodes and business semantics are configured. Different colors are used to identify the current start and stop status of nodes to generate a global topology map.

[0064] Step E: Create and execute power-on and power-off drill tasks based on the global topology map, collect state changes of each node during the power-on and power-off drill according to the logical association of all topology maps, and automatically generate a simulation drill report for the power-on and power-off drill tasks.

[0065] In order to ensure the correctness and reliability of cloud environment infrastructure during power on and off, the embodiment of the present invention monitors the failures and errors of servers, network devices, storage devices, middleware, and applications during power on and off, and provides timely feedback and automatic processing. A cloud environment equipment power on and off simulation drill method is involved, which mainly includes three technical contents: log hierarchical monitoring and analysis, multi-level topology visualization, and automated management during the power on and off simulation drill.

[0066] 1. Log layered monitoring and analysis

[0067] In order to more clearly detect the situation at each stage of device power on and off, this method mainly collects and manages the logs during the device power on and off process in a hierarchical and classified manner.

[0068] First, logs are divided into five layers according to their sources: device layer logs, virtual layer logs, system layer logs, middleware logs, and application logs.

[0069] For device layer logs (P0), they mainly record the operation logs of physical servers, network devices, and storage devices, namely, power on / off logs, network connection logs, and storage read / write logs. The log content includes the device number, model, location, real-time operation status, operation content, operation time, operator, and fault content. At the same time, it is necessary to record CPU / memory usage, throughput, latency data, voltage, current, signal strength, and signal-to-noise ratio.

[0070] For the virtual layer log (P1), it mainly records the life cycle, configuration changes, resource utilization, and status information of virtual machines and containers, as well as virtual hardware.

[0071] For system-level logs (P2), we mainly collect operation logs, access logs, and error logs of the operating system, cluster management system, and database;

[0072] For middleware logs (P3), the main purpose is to collect the operating indicators and logs of the web server, cache, and message queue;

[0073] For application logs (P4), the main focus is on collecting program operation logs and error logs.

[0074] In order to help users more clearly understand the log information at different stages of the device startup and shutdown process, avoid information overload and redundancy, and improve the efficiency and reliability of device management. Based on the stratification results, the logs are further weighted. For each level of log information, weighting is performed according to its importance and priority.

[0075] Set basic weights for the above five levels of logs: device layer logs > virtual layer logs > system layer logs > middleware logs > application logs. Each level of logs is further weighted according to its subcategories. Furthermore, based on actual business needs, the log content design levels are divided and scored at each level. The log level design can be configured as required. Here, the example is mainly divided into three levels: high (7-10 points), medium (4-7 points), and low (1-3 points): set the connection and disconnection events of the hardware media, and the start and stop changes of the components at the other four levels as high-level logs; record voltage and current, configuration changes, operating indicators, etc. as medium-level logs; record changes in signal strength and signal-to-noise ratio and other parameters as low-level logs. Use the following formula to calculate the weight of log event i:

[0076] w i =w i,1 ×0.4+w i,2 ×0.3+w i,3 ×0.3

[0077] Among them, w i is the weight of log event i, w i,1 is the parent class hierarchy weight to which log event i belongs, w i,2 is the subclass hierarchy weight to which log event i belongs, w i,3 is the level weight of log event i.

[0078] Collect the anomalies that appear in the historical logs, determine the event types contained in the logs (i.e., Error, Warning messages), and for each event type, count the frequency of its occurrence in the logs using the above-mentioned hierarchical statistics, and use the entropy increase formula to evaluate the amount of information in the logs. In order to more accurately determine the priority and importance of the logs, the present invention further combines the entropy increase formula with the log hierarchical weights for weighted calculation processing, and the weighted entropy increase formula used is:

[0079] H i =-Σ(P i × i×log2(P i × i ))

[0080] Where P i represents the frequency of log event i in the log, w i Represents the weight of log event i, weighted entropy increase H i The larger the calculated value, the higher the priority and importance of the log.

[0081] Based on log stratification, i Set the corresponding alarm threshold to trigger alarm notifications of corresponding levels (notification, warning, general, severe, fatal).

[0082] 2. Multi-level topology visualization

[0083] In order to realize status monitoring and rapid fault location during power on and off, a multi-level topology visualization method is designed to support the visualization of the global topology structure with multi-level unified monitoring and cross-level traceability.

[0084] Step 2.1: Cross-level tracing

[0085] In order to establish a multi-level global monitoring topology, the global topology nodes are first grouped and associated and managed. They are divided into four major groups (i.e., device layer, virtual layer, middleware, and application layer) according to the level. Small groups are established within each level according to their respective facilities or clusters. The device layer is divided according to assets, the virtual layer is divided according to virtual machine clusters, the middleware layer is divided according to middleware clusters, and the application layer is divided according to application systems.

[0086] Within each group, nodes can be created for key devices, components, and instances, or nodes associated with certain indicators or functions can be created according to business needs. At the same time, mapping relationships can be designed between nodes for association, such as the association between network device nodes and virtual machine nodes. At the same time, key attributes (including start and stop instructions) are configured for each node, and labels are set to facilitate filtering and association. When a high-level topology node is clicked, it can be traced back to the underlying infrastructure, thereby realizing linked browsing of the global topology.

[0087] Step 2.2: Multi-level unified monitoring

[0088] You can set monitoring trigger conditions and configure business semantics between associated nodes, and use different colors to identify the current start and stop status of the node for monitoring node status and associated display. The setting of monitoring trigger conditions between nodes is divided into status monitoring (start, connect, stop) and abnormal event monitoring:

[0089] Status monitoring, in addition to the connection status monitoring instructions set between associated nodes, also needs to establish dependencies between nodes. When a node starts (Completed) or stops (Stopped), an event notification is sent to the associated node. At the same time, based on the connection status between the monitored associated nodes, the association identifier between the nodes is updated to display the connection (Connected) or disconnected status (Disconnected).

[0090] Abnormal event monitoring requires access to the log monitoring and analysis module described in 4.1, and setting trigger conditions for nodes, such as resource utilization > X%, or the number of connections increased by > m within n minutes. Combined with the log stratification weight H_i, node abnormal events are triggered. When a node fails, the monitoring of its associated nodes is triggered, and the monitoring of the scope of the fault impact is automatically carried out. That is, when the trigger conditions are met, the indicator collection and log recording of the associated nodes are pre-started for the report.

[0091] 3. Automated Management

[0092] Step 3.1, node power on and off simulation:

[0093] Based on the multi-level global monitoring topology diagram obtained above, the present invention also provides an automated method for simulating abnormal events, which supports powering on and off nodes in a specified topology diagram, as well as powering on and off random nodes.

[0094] For a fully maintained global topology, you can create a task, configure the scheduled power-off time of the node, select multiple nodes, scheduled power-on time, and whether to enable automatic collection of task logs in the task.

[0095] After the task is started, a log monitoring task will be automatically created 5 minutes before the stop time, and log monitoring will be automatically started;

[0096] When the power-off time is reached, the shutdown instructions of each node are automatically executed, and the log and topology monitoring automatically record the status and abnormalities of each device;

[0097] When the power-on time is reached, the startup and running instructions configured for each node are automatically executed to confirm that each node is normally enabled and that the log has no abnormalities within 2 minutes, then the collection is automatically stopped, or the collection can be stopped manually;

[0098] In addition to specifying nodes, you can also create random tasks, that is, configure the power-on and power-off timing, select multiple groups that need to be randomly powered off, and then perform random node power-on and power-off simulation.

[0099] In order to ensure the integrity of the business and the stability of the platform when simulating the power off of a designated node or a random node, the present invention also supports automatic switching of abnormal nodes. When the above global topology map detects that the upstream node is in a node stop state, the connection between the associated nodes will be changed to a disconnected state. If the abnormal upstream node is not started normally and successfully connected within 30 minutes, the configuration of the associated downstream node will be automatically switched to other nodes that can be connected normally in the same group of the abnormal upstream node to ensure the normal operation of the remaining downstream nodes. In addition, the abnormal information generates an alarm notification to the corresponding person in charge for investigation and processing.

[0100] Step 3.2, the simulation exercise report is automatically generated:

[0101] In order to better reflect the drill process and facilitate relevant personnel to quickly locate the root cause, the topology status perception and log analysis are used to automatically generate a simulation drill report based on step 3.1.

[0102] Before the simulated power-on and power-off drill begins, for the drill task, first confirm the key nodes, turn on the node status monitoring and log collection, and during the drill, monitor the node status changes in real time through the topology map, and collect node logs at the same time; after the drill, parse the logs, automatically extract the status changes and timestamps of the power-on and power-off nodes, and the abnormal logs of their associated nodes; secondly, analyze and count the abnormal logs generated by the associated nodes, and generate reports; then, based on the logical association of the topology map, collect the status changes of each node during the power-on and power-off drill, including node name, status item, initial status, time of each status change, new status, and description. The description is mainly reflected in the status changes of downstream nodes caused by the status changes of upstream nodes, and finally generate a process description table of node status changes; finally, combined with the task time, simulated equipment and nodes, operation records of each stage, status records of each stage, abnormalities that occurred, and the above-mentioned generated reports, automatically generate a simulation drill report for the drill task to facilitate subsequent review and improvement.

[0103] Those skilled in the art will appreciate that the embodiments of the present application can be provided as methods, systems, or computer program products. Therefore, the present application can adopt the form of complete hardware embodiments, complete software embodiments, or embodiments in combination with software and hardware. Moreover, the present application can adopt the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, CD-ROM, optical storage, etc.) that contain computer-usable program code. The scheme in the embodiments of the present application can be implemented in various computer languages, for example, object-oriented programming language Java and literal scripting language JavaScript, etc.

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

[0105] These computer program instructions may also be stored in a computer readable memory capable of directing a computer or other programmable data processing device to operate in a specific manner, so that the instructions stored in the computer readable memory produce an article of manufacture including an instruction device, which implements the process Figure 1 A process or multiple processes and / or boxes Figure 1 A function specified in one or more boxes.

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

[0107] Although the preferred embodiments of the present application have been described, those skilled in the art may make other changes and modifications to these embodiments once they have learned the basic creative concept. Therefore, the appended claims are intended to be interpreted as including the preferred embodiments and all changes and modifications falling within the scope of the present application.

[0108] Obviously, those skilled in the art can make various changes and modifications to the present application without departing from the spirit and scope of the present application. Thus, if these modifications and variations of the present application fall within the scope of the claims of the present application and their equivalents, the present application is also intended to include these modifications and variations.

Claims

1. A method for simulating power-on and power-off of equipment in a cloud environment, characterized in that: The device power-on and power-off simulation drill method comprises the following steps: Step A: Divide the logs into five layers according to the log sources during the device power-on and power-off process: device layer logs, virtual layer logs, system layer logs, middleware logs, and application logs; Step B, based on the hierarchical results, for each level of log information, set the parent level weight of each level and the sub-level weight of the log sub-level contained in each level according to their respective importance and priority; design and score the level division of log events at each level according to the actual business needs, and obtain the level hierarchy and level weight of the log; and obtain the weights of different log events by comprehensive calculation; Step C, collecting anomalies appearing in historical logs, determining the event types contained in the historical logs, hierarchically counting the frequency of each event type appearing in the logs, and setting alarm thresholds for different log events based on weighted entropy increase; Step D: Group and associate the global topology nodes. They are divided into four groups according to the level: device layer, virtual layer, middleware, and application layer. Small groups are established in each level according to their respective facilities or clusters. In each group, nodes are created for key devices, components, and instances. Nodes with associated indicators or functions are created according to business needs. At the same time, mapping relationships are designed between nodes for association. Monitoring trigger conditions are set between associated nodes and business semantics are configured. Different colors are used to identify the current start and stop status of nodes to generate a global topology map. Step E: based on the global topology map, create and execute the power-on and power-off drill task, collect the state changes of each node during the power-on and power-off drill according to the logical association of all topology maps, and automatically generate a simulation drill report for the power-on and power-off drill task; In step C, the anomalies appearing in the historical logs are collected, the event types contained in the historical logs are determined, and for each event type, the frequency of occurrence in the logs is hierarchically counted. The process of setting the alarm thresholds for different log events based on weighted entropy increase includes the following steps: Collect the anomalies in the historical logs, determine the event types contained in the logs, and perform hierarchical statistics on the frequency of occurrence of each event type corresponding to each anomaly. Use the weighted entropy increase formula combined with the weight of the log event to perform weighted calculation processing to obtain the weighted entropy increase H corresponding to the log event i. i : H i =-∑(P i ×w i ×log2(P i ×w i )) Among them, P i represents the frequency of log event i in the log, w i Represents the weight of log event i, weighted entropy increase H i The larger the value of , the higher the priority and importance of log event i; Based on log stratification, weighted entropy increase H based on log event i i Set the corresponding alarm threshold for log event i to trigger an alarm notification of the corresponding level.

2. The method for simulating power-on and power-off of equipment in a cloud environment according to claim 1, characterized in that: In step A, the device layer log is used to record the operation logs of physical servers, network devices, and storage devices, including power on / off logs, network connection logs, and storage read / write logs. The log content includes device number, model, location, real-time operation status, operation content, operation time, operator, fault content, CPU / memory usage, throughput, latency data, voltage, current, signal strength, and signal-to-noise ratio; The virtual layer log is used to record the life cycle, configuration changes, resource utilization and status information of virtual machines and containers; The system layer log is used to collect operation logs, access logs, and error logs of the operating system, cluster management system, and database; The middleware log is used to collect the operating indicators and logs of the web server, cache, and message queue; The application log is used to collect the program's running log and error log.

3. The method for simulating power-on and power-off of equipment in a cloud environment according to claim 1, characterized in that: In step B, the process of comprehensively calculating the weights of different log events includes the following steps: Step B1, based on the hierarchical result, for each level of log information, the parent level weight of each level and the sub-level weight of the log sub-level contained in each level are set according to their respective importance and priority; Step B2, according to the actual business needs, the log events at each level are divided into three levels: high-level logs, medium-level logs and low-level logs, and the level scores are set for different levels, and then the level weights are set for the log events at different levels; among them, the connection and disconnection events of the hardware media in the device layer log, and the start and stop changes of the components under the four levels of logs, namely, the virtual layer log, the system layer log, the middleware log and the application log, are set as high-level logs; the voltage and current, configuration changes, and operation indicators are set as medium-level logs; the changes in signal strength and signal-to-noise ratio and other parameters are set as low-level logs; Step B3, use the following formula to comprehensively calculate the weights of different log events: In i =in i,1 ×0.4+in i,2 ×0.3+in i,3 ×0.3 Among them, w i is the weight of log event i, w i,1 is the parent class hierarchy weight to which log event i belongs, w i,2 is the subclass hierarchy weight to which log event i belongs, w i,3 is the level weight of log event i.

4. The method for simulating power-on and power-off of equipment in a cloud environment according to claim 1, characterized in that: In step D, the process of generating the global topology map includes the following steps: The global topology nodes are grouped and associated, and divided into four major groups according to the level: device layer, virtual layer, middleware and application layer. Small groups are established in each level according to their respective facilities or clusters. Among them, the device layer is divided according to assets, the virtual layer is divided according to virtual machine clusters, the middleware layer is divided according to middleware clusters, and the application layer is divided according to application systems; In each group, nodes are created for key equipment, components, and instances. Nodes with associated indicators or functions are created according to business needs. At the same time, mapping relationships are designed between nodes for association. Key attributes including start and stop instructions are configured for each node, and key attribute labels are set. Set monitoring trigger conditions and configure business semantics between associated nodes. Use different colors to identify the current start and stop status of nodes for monitoring node status and associated display. The setting of monitoring trigger conditions between nodes is divided into status monitoring including start, connection, and stop, and abnormal event monitoring. Among them, status monitoring refers to setting connection status monitoring instructions between associated nodes, and establishing dependency relationships between nodes. When a node starts or stops, an event notification is sent to the associated node. According to the connection status between the monitored associated nodes, the association identifier between the nodes is updated to display the connection or disconnection status; abnormal event monitoring refers to setting trigger conditions for the node. When a node fails, the monitoring of its associated nodes is triggered, and the monitoring of the fault impact range is automatically carried out.

5. The method for simulating power-on and power-off of equipment in a cloud environment according to claim 1, characterized in that: In step E, the process of creating and executing the power-on and power-off drill task based on the global topology map includes the following steps: Based on the global topology, a power-on and power-off drill task is created. The drill task includes the node scheduled power-off time, multiple node selections, scheduled power-on time, and whether to enable automatic task log collection settings. After the task is started, a log monitoring task will be automatically created 5 minutes before the stop time, and log monitoring will be automatically started; When the power-off time is reached, the stop operation instructions of each node are automatically executed, and the log and topology monitoring automatically record the status and abnormalities of each device; When the power-on time is reached, the startup and running instructions configured for each node are automatically executed to confirm that each node is enabled normally and that the log has no abnormalities within 2 minutes, then the collection is automatically stopped, or the collection can be stopped manually.

6. The method for simulating power-on and power-off of equipment in a cloud environment according to claim 1, characterized in that: In step E, the process of creating and executing the power-on and power-off drill task based on the global topology map further includes the following steps: Create a random task, configure the power-on and power-off timing, select multiple random power-off groups, and generate random node power-on and power-off drill tasks.

7. The method for simulating power-on and power-off of equipment in a cloud environment according to claim 1, characterized in that: When the global topology map detects that the upstream node is in a stopped state, the connection between the associated nodes will be changed to a disconnected state. If the abnormal upstream node is not started normally and successfully connected within 30 minutes, the configuration of the associated downstream node will be automatically switched to other nodes that can be connected normally in the same group as the abnormal upstream node. The abnormal information will generate an alarm notification to the relevant person in charge for investigation and processing.

8. The method for simulating power-on and power-off of equipment in a cloud environment according to claim 1, characterized in that: In step E, according to the logical association of all topological diagrams, the state changes of each node during the power-on and power-off drill are collected, and the process of automatically generating a simulation drill report for the power-on and power-off drill task includes the following steps: Before the simulated power-on and power-off drill begins, the drill tasks are parsed, the simulated device numbers and key node numbers are confirmed, and the key node status monitoring and log collection are enabled; during the drill, the node status changes are monitored in real time through the global topology map, and key node logs are collected at the same time; after the drill, the key node logs are parsed, and the key node status changes and timestamps are automatically extracted, as well as the abnormal logs of the associated nodes; Analyze and count the abnormal logs generated by the associated nodes and generate abnormal log reports; According to the logical association of the topology diagram, the state changes of each key node during the power-on and power-off drill are collected, including the node name, state item, initial state, time of each state change, new state after the change and description, and a state record table for each stage and a process description table for each node state change are generated; among which, the description is used to reflect the state changes of downstream nodes caused by the state changes of upstream nodes; Combined with the state change timestamp, simulation equipment number, key node number, operation records of each stage, state record table of each stage, abnormal log report and process description table, a simulation exercise report is automatically generated for the exercise task.

9. A device for simulating power on and off of equipment in a cloud environment based on the method described in any one of claims 1 to 8, characterized in that: The equipment power-on and power-off simulation drill device comprises: The log layering module is used to divide the logs into five layers according to the log sources during the device power-on and power-off process: device layer logs, virtual layer logs, system layer logs, middleware logs, and application logs; The log event weight calculation module is used to set the parent class weight of each level and the subclass weight of each level of log information according to their respective importance and priority based on the hierarchical results; design and score the level of log events at each level according to the actual business needs, and obtain the level level and level weight of the log; and obtain the weights of different log events through comprehensive calculation; The alarm threshold setting module is used to collect anomalies in historical logs, determine the event types contained in the historical logs, and for each event type, perform hierarchical statistics on its frequency P in the logs, and set alarm thresholds for different log events based on weighted entropy increase; The topology map generation module is used to group and associate global topology nodes. It is divided into four major groups according to the hierarchy: device layer, virtual layer, middleware, and application layer. Small groups are established in each layer according to their respective facilities or clusters. In each group, nodes are created for key devices, components, and instances. Nodes with associated indicators or functions are created according to business needs. At the same time, mapping relationships are designed between nodes for association. Monitoring trigger conditions are set between associated nodes and business semantics are configured. Different colors are used to identify the current start and stop status of nodes to generate a global topology map. The report generation module is used to create and execute power-on and power-off drill tasks based on the global topology map. According to the logical association of all topology maps, the state changes of each node during the power-on and power-off drill process are collected, and a simulation drill report for the power-on and power-off drill task is automatically generated.

Citation Information

Patent Citations

  • Method and system for judging reliability of distributed cluster through weighted entropy

    CN107590008A

  • Log analysis method and device, equipment and storage medium

    CN116775400A