System operation and maintenance method, device and server

By generating timing tasks on the operation and maintenance server and sending them to the proxy server, the problem of low operation and maintenance processing efficiency in the existing technology is solved, and efficient operation and maintenance processing of multiple business systems to be maintained is achieved, eliminating platform dependence and supporting complex operation and maintenance scenarios.

CN114217843BActive Publication Date: 2025-05-02AGRICULTURAL BANK OF CHINA
View PDF 2 Cites 0 Cited by

Patent Information

Application Number
CN202111533337.5
Authority / Receiving Office
CN · China
Patent Type
Patents(China)
Current Assignee / Owner
Filing Date
2021-12-15
Publication Date
2025-05-02
Estimated Expiration
2041-12-15

AI Technical Summary

Technical Problem

In the prior art, when operating and maintaining multiple business systems to be maintained, it is necessary to configure timed operation and maintenance tasks according to the type of each business system, resulting in low operation and maintenance processing efficiency.

Method used

By generating timing tasks on the operation and maintenance server, setting its initial status to be implemented, and generating script configuration instructions based on the operation and maintenance information entered by the user, sending them to the proxy server. The proxy server generates operation and maintenance scripts based on the instructions and sends them to the operation and maintenance server to the operation and maintenance server, automatic operation and maintenance processing is realized.

Benefits of technology

There is no need to consider the differences in the timed operation and maintenance tasks configured by the server to be operated and maintained for different system types, which improves the efficiency of operation and maintenance processing, eliminates platform dependence, and supports the processing of complex operation and maintenance scenarios.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN114217843B_ABST
    Figure CN114217843B_ABST
Patent Text Reader

Abstract

The present application provides a system operation and maintenance method, device and server, which relate to the field of Internet technology. In the method, the operation and maintenance server can send script configuration instructions to different proxy servers. After receiving the script configuration instructions, the proxy server can generate an operation and maintenance instruction carrying an operation and maintenance script according to the script configuration instructions, and send it to the server to be operated and maintained. There is no need to consider the differences in the configuration of scheduled operation and maintenance tasks for servers to be operated and maintained of different system types, thereby realizing batch processing of the servers to be operated and maintained, improving the efficiency of operation and maintenance processing, and eliminating platform dependence.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] This application relates to the field of Internet technology, and in particular to a system operation and maintenance method, device and server. Background Technology

[0002] As businesses across enterprises continue to grow, the increasing volume of business activities enhances the complexity of business systems and places higher demands on them. Therefore, maintenance and operation (O&M) are necessary during the use of business systems to ensure their normal operation and prevent losses to the enterprise. O&M refers to the upkeep of released business systems, enabling O&M personnel to promptly identify and correct any problems, thereby ensuring the normal functioning of all features within the business system.

[0003] Currently, the main method for performing maintenance on business systems is for maintenance personnel to log into the business system to be maintained, call the built-in scheduled task tool of the business system to be maintained, and configure the scheduled maintenance tasks to be executed so that the business system to be maintained can be maintained at the set time.

[0004] However, in the existing technology, when performing maintenance on multiple business systems that need to be maintained, it is necessary to configure scheduled maintenance tasks separately according to the type of each business system, which may result in low efficiency of maintenance processing. Summary of the Invention

[0005] This application provides a system operation and maintenance method, apparatus and server to solve the problem that in the prior art, when performing operation and maintenance on multiple business systems to be maintained, it is necessary to configure scheduled operation and maintenance tasks separately according to the type of each business system, which may result in low efficiency of operation and maintenance processing.

[0006] In a first aspect, embodiments of this application provide a system operation and maintenance method, applied to an operation and maintenance server, including:

[0007] Based on the operation and maintenance information input by the user, a scheduled task is generated, and the initial state of the scheduled task is set to pending execution. The operation and maintenance information includes the identifier of the target server to be operated and maintained, the operation and maintenance scenario, the operation and maintenance parameters, and the time range. The operation and maintenance scenario includes at least one operation and maintenance operation, and the scheduled task includes the time range.

[0008] According to the scheduled task, when the current time enters the time range and the status of the scheduled task is pending implementation, a first script configuration instruction is generated according to the operation and maintenance information, and the status of the scheduled task is changed to be implemented. The first script configuration instruction includes the identifier of the target server to be operated and maintained, the operation and maintenance scenario, and the operation and maintenance parameters.

[0009] Based on the identifier of the target server to be maintained and the pre-obtained mapping relationship between the identifier of the server to be maintained and the identifier of the proxy server, the identifier of the target proxy server corresponding to the identifier of the target server to be maintained is determined.

[0010] The first script configuration command is sent to the target proxy server corresponding to the identifier of the target proxy server.

[0011] In one possible design of the first aspect, the execution result and execution log returned by the target proxy server are received;

[0012] The execution results and execution logs are sent to a pre-configured terminal device for receiving operation and maintenance results.

[0013] Optionally, the timed task further includes a loop period, a loop state, an execution interval, and indication information, wherein the indication information is used to indicate whether to generate instructions again after execution failure, and the method further includes:

[0014] When the execution result is execution failure and the loop state is non-looping, and the indication information indicates that when generating instructions again after execution failure, a second script configuration instruction is generated according to the execution interval and the operation and maintenance information. The second script configuration instruction includes the identifier of the target server to be maintained, the operation and maintenance scenario, and the operation and maintenance parameters.

[0015] Send the second script configuration command to the target proxy server;

[0016] or;

[0017] When the execution result is execution failure, the loop state is loop, and the indication information indicates that when generating instructions again after execution failure, a third script configuration instruction is generated according to the loop cycle and the operation and maintenance information. The third script configuration instruction includes the identifier of the target server to be maintained, the operation and maintenance scenario, and the operation and maintenance parameters.

[0018] The third script configuration command is sent to the target proxy server.

[0019] Optionally, after receiving the execution results and execution logs returned by the target proxy server, the method further includes:

[0020] When the execution result is successful and the loop state is non-looping, the status of the scheduled task is changed from being implemented to being implemented;

[0021] or;

[0022] When the execution result is execution failure, the loop state is non-looping, and the indication information indicates that no more instructions will be generated after the execution failure, the status of the timed task will be changed from being implemented to being implemented.

[0023] Secondly, embodiments of this application provide a system operation and maintenance method applied to a proxy server, including:

[0024] Receive a first script configuration instruction sent by the operation and maintenance server. The first script configuration instruction includes the identifier of the target server to be operated and maintained, the operation and maintenance scenario, and the operation and maintenance parameters. The operation and maintenance scenario includes at least one operation and maintenance operation.

[0025] According to the first script configuration instructions, at least one first operation and maintenance script corresponding to the operation and maintenance scenario is obtained from a plurality of pre-stored operation and maintenance scripts;

[0026] Configure the at least one first operation and maintenance script according to the operation and maintenance scenario and the operation and maintenance parameters to generate a second operation and maintenance script;

[0027] A first maintenance instruction is sent to the target server to be maintained, and the first maintenance instruction carries the second maintenance script.

[0028] In one possible design of the second aspect, configuring the at least one first operation and maintenance script according to the operation and maintenance scenario and the operation and maintenance parameters to generate a second operation and maintenance script includes:

[0029] Write the operation and maintenance parameters into the at least one first operation and maintenance script, and obtain at least one first operation and maintenance script after writing the operation and maintenance parameters;

[0030] Based on the execution order of each operation and maintenance operation in the operation and maintenance scenario, the first operation and maintenance script, which is written with at least one operation and maintenance parameter, is concatenated to generate the second operation and maintenance script.

[0031] In another possible design of the second aspect, the method further includes:

[0032] Receive the execution results and execution logs sent by the target server to be maintained;

[0033] The execution results and execution logs are sent to the operation and maintenance server.

[0034] In another possible design of the second aspect, after sending the first maintenance instruction to the target server to be maintained, the method further includes:

[0035] The system receives a second script configuration instruction sent by the operation and maintenance server. The second script configuration instruction includes the identifier of the target server to be operated and maintained, the operation and maintenance scenario, and the operation and maintenance parameters.

[0036] According to the second script configuration instructions, obtain the pre-stored second operation and maintenance script;

[0037] Based on the identifier of the target server to be maintained, a second maintenance instruction is sent to the target server to be maintained, the second maintenance instruction carrying the second maintenance script;

[0038] or;

[0039] Receive a third script configuration instruction sent by the operation and maintenance server, the third script configuration instruction including the identifier of the target server to be operated and maintained, the operation and maintenance scenario and the operation and maintenance parameters;

[0040] According to the third script configuration instructions, the pre-stored second operation and maintenance script is obtained;

[0041] Based on the identifier of the target server to be maintained, a third maintenance instruction is sent to the target server to be maintained, the third maintenance instruction carrying the second maintenance script.

[0042] Thirdly, embodiments of this application provide a system operation and maintenance device applied to an operation and maintenance server, comprising:

[0043] The generation module is used to generate a scheduled task based on the operation and maintenance information input by the user, and set the initial state of the scheduled task to be implemented. The operation and maintenance information includes the identifier of the target server to be operated and maintained, the operation and maintenance scenario, the operation and maintenance parameters and the time range. The operation and maintenance scenario includes at least one operation and maintenance operation, and the scheduled task includes the time range.

[0044] The generation module is further configured to, based on the scheduled task, when the current time enters the time range and the status of the scheduled task is pending implementation, generate a first script configuration instruction based on the operation and maintenance information, and change the status of the scheduled task to be implemented. The first script configuration instruction includes the identifier of the target server to be maintained, the operation and maintenance scenario, and the operation and maintenance parameters.

[0045] The determination module is used to determine the identifier of the target proxy server corresponding to the identifier of the target server to be maintained, based on the identifier of the target server to be maintained and the pre-obtained mapping relationship between the identifier of the server to be maintained and the identifier of the proxy server.

[0046] The sending module is used to send the first script configuration command to the target proxy server corresponding to the identifier of the target proxy server.

[0047] In one possible design of the third aspect, the device further includes:

[0048] The receiving module is used to receive the execution results and execution logs returned by the target proxy server;

[0049] The sending module is also used to send the execution result and the execution log to a pre-configured terminal device for receiving operation and maintenance results.

[0050] Optionally, the scheduled task further includes a loop cycle, a loop state, an execution interval, and indication information. The indication information is used to indicate whether to generate an instruction again after execution failure. The generation module is used to generate a second script configuration instruction based on the execution interval and the operation and maintenance information when the execution result is execution failure, the loop state is non-looping, and the indication information indicates that an instruction should be generated again after execution failure. The second script configuration instruction includes the identifier of the target server to be maintained, the operation and maintenance scenario, and the operation and maintenance parameters.

[0051] The sending module is used to send the second script configuration command to the target proxy server;

[0052] or;

[0053] The generation module is used to generate a third script configuration instruction based on the cycle period and the operation and maintenance information when the execution result is execution failure, the loop state is loop, and the indication information indicates that an instruction should be generated again after execution failure. The third script configuration instruction includes the identifier of the target server to be maintained, the operation and maintenance scenario, and the operation and maintenance parameters.

[0054] The sending module is used to send the third script configuration command to the target proxy server.

[0055] Optionally, after receiving the execution results and execution logs returned by the target proxy server, the apparatus includes:

[0056] The module is configured to change the status of the scheduled task from "being implemented" to "being implemented" when the execution result is "execution successful" and the loop status is "non-looping".

[0057] or;

[0058] When the execution result is execution failure, the loop state is non-looping, and the indication information indicates that no more instructions will be generated after the execution failure, the status of the timed task will be changed from being implemented to being implemented.

[0059] Fourthly, embodiments of this application provide a system operation and maintenance device applied to a proxy server, comprising:

[0060] The receiving module is used to receive a first script configuration instruction sent by the operation and maintenance server. The first script configuration instruction includes the identifier of the target server to be operated and maintained, the operation and maintenance scenario, and the operation and maintenance parameters. The operation and maintenance scenario includes at least one operation and maintenance operation.

[0061] The acquisition module is used to acquire at least one first operation and maintenance script corresponding to the operation and maintenance scenario from a plurality of pre-stored operation and maintenance scripts according to the first script configuration instructions;

[0062] A generation module is used to configure the at least one first operation and maintenance script according to the operation and maintenance scenario and the operation and maintenance parameters, and generate a second operation and maintenance script;

[0063] The sending module is used to send a first maintenance instruction to the target server to be maintained, the first maintenance instruction carrying the second maintenance script.

[0064] In one possible design of the fourth aspect, the generation module is specifically used for:

[0065] Write the operation and maintenance parameters into the at least one first operation and maintenance script, and obtain at least one first operation and maintenance script after writing the operation and maintenance parameters;

[0066] Based on the execution order of each operation and maintenance operation in the operation and maintenance scenario, the first operation and maintenance script, which is written with at least one operation and maintenance parameter, is concatenated to generate the second operation and maintenance script.

[0067] In another possible design of the fourth aspect, the receiving module is also used to receive the execution results and execution logs sent by the target server to be maintained;

[0068] The sending module is also used to send the execution result and the execution log to the operation and maintenance server.

[0069] In another possible design of the fourth aspect, after sending the first maintenance instruction to the target server to be maintained, the receiving module is further configured to receive a second script configuration instruction sent by the maintenance server, the second script configuration instruction including the identifier of the target server to be maintained, the maintenance scenario and the maintenance parameters;

[0070] The acquisition module is further configured to acquire the pre-stored second operation and maintenance script according to the second script configuration instructions;

[0071] The sending module is further configured to send a second maintenance instruction to the target maintenance server according to the identifier of the target maintenance server, wherein the second maintenance instruction carries the second maintenance script;

[0072] or;

[0073] The receiving module is further configured to receive a third script configuration instruction sent by the operation and maintenance server, the third script configuration instruction including the identifier of the target server to be operated and maintained, the operation and maintenance scenario and the operation and maintenance parameters;

[0074] The acquisition module is further configured to acquire the pre-stored second operation and maintenance script according to the third script configuration instruction;

[0075] The sending module is further configured to send a third maintenance instruction to the target maintenance server based on the identifier of the target maintenance server, the third maintenance instruction carrying the second maintenance script.

[0076] Fifthly, embodiments of this application provide a server, including: a processor, a memory, and computer program instructions stored in the memory and executable on the processor, wherein the processor executes the computer program instructions to implement the first aspect, the second aspect, and the methods possibly designed and provided in the first and second aspects.

[0077] The operation and maintenance method, apparatus, and server provided in this application embodiment allow the operation and maintenance server to send script configuration instructions to different proxy servers. Upon receiving the script configuration instructions, the proxy servers can generate operation and maintenance instructions carrying the operation and maintenance scripts and send them to the server to be maintained. This eliminates the need to consider the differences in scheduled operation and maintenance tasks configured on different system types of servers to be maintained. The server to be maintained can automatically complete the operation and maintenance process according to the operation and maintenance instructions, achieving batch processing of servers to be maintained, improving the efficiency of operation and maintenance processing, and eliminating platform dependence. Furthermore, the proxy server can generate operation and maintenance instructions carrying complex operation and maintenance scripts based on the script configuration instructions sent by the operation and maintenance server. In contrast, in the prior art, the scheduled tasks built into the server to be maintained only support simple operation commands and cannot meet the needs of complex scenarios with dependencies. This solution further improves the diversity of operation and maintenance processing. Attached Figure Description

[0078] The accompanying drawings, which are incorporated in and form part of this specification, illustrate embodiments consistent with this application and, together with the description, serve to explain the principles of this application.

[0079] Figure 1 A schematic diagram illustrating an application scenario of the operation and maintenance method of the system provided in this application embodiment;

[0080] Figure 2 A schematic diagram of the system structure of the automated operation and maintenance platform provided in the embodiments of this application;

[0081] Figure 3 A flowchart illustrating an embodiment of the system operation and maintenance method provided in this application;

[0082] Figure 4 A flowchart illustrating a second embodiment of the system operation and maintenance method provided in this application.

[0083] Figure 5 A flowchart illustrating the third embodiment of the system operation and maintenance method provided in this application;

[0084] Figure 6 A flowchart illustrating the fourth embodiment of the system operation and maintenance method provided in this application;

[0085] Figure 7 A schematic diagram of the structure of the operation and maintenance device of the system provided in this application embodiment;

[0086] Figure 8 A schematic diagram of the structure of the operation and maintenance device of the system provided in this application, according to Embodiment 2;

[0087] Figure 9 This is a schematic diagram of the server structure provided in an embodiment of this application.

[0088] The accompanying drawings have illustrated specific embodiments of this disclosure, which will be described in more detail below. These drawings and descriptions are not intended to limit the scope of the concept in any way, but rather to illustrate the concepts of this disclosure to those skilled in the art through reference to particular embodiments. Detailed Implementation

[0089] To make the objectives, technical solutions, and advantages of the embodiments of this application clearer, the technical solutions of the embodiments of this application will be clearly and completely described below with reference to the accompanying drawings. Obviously, the described embodiments are only some embodiments of this application, not all embodiments. Based on the embodiments of this application, all other embodiments obtained by those skilled in the art without creative effort are within the scope of protection of this application.

[0090] Before introducing the embodiments of this application, the application background of the embodiments of this application will be explained first:

[0091] For modern enterprise business systems, system maintenance is frequently required at certain times, such as machine startup / shutdown and system verification. Currently, there are two main methods for performing maintenance on business systems:

[0092] 1) Operation and maintenance personnel need to go to the data center at a specified time to perform operation and maintenance on the business system. However, if the specified time is a holiday or at night, it will affect the rest time of the operation and maintenance personnel, resulting in high labor and time costs and low processing efficiency.

[0093] 2) The maintenance personnel log in to the business system to be maintained, call the built-in scheduled task tool of the business system to be maintained (such as crontab on Unix system platform, task scheduler on Windows system platform), configure the scheduled maintenance tasks to be executed, so that the business system to be maintained is maintained at the set time.

[0094] However, in the above method, when performing maintenance on multiple business systems to be maintained, it is necessary to log in to each business system to be maintained and configure scheduled maintenance tasks one by one according to the type of each business system. This is difficult to operate and may result in low efficiency of maintenance.

[0095] To address the aforementioned problems, the inventive concept of this application is as follows: Manually configuring scheduled maintenance tasks for business systems requiring maintenance is time-consuming, difficult to operate, and cannot guarantee efficient maintenance processing. Based on this, the inventors discovered that if a corresponding agent application can be installed on the system requiring maintenance, the maintenance server can periodically generate script configuration instructions based on the required maintenance time of the system and send them to the agent server corresponding to the agent installed on the system. The agent server then generates a corresponding script based on the script configuration instructions and sends it to the system requiring maintenance, enabling the system to automatically execute the script and complete the maintenance processing. This solves the problem of low efficiency in existing maintenance processes.

[0096] For example, the system operation and maintenance method provided in this application embodiment can be applied to Figure 1 The diagram shows one application scenario. Figure 1 This diagram illustrates an application scenario of the system operation and maintenance method provided in this application embodiment, used to solve the aforementioned technical problems. For example... Figure 1 As shown, the application scenario may include: an operation and maintenance server 11, a proxy server 12 and a server to be operated and maintained 13, and may also include a data storage device 14 connected to the proxy server 12.

[0097] Optionally, the operations and maintenance server 11 can provide a graphical user interface (GUI) for users by running a browser or client, allowing users to interact with the GUI through clicks. In response to user clicks on the GUI, the operations and maintenance server 11 obtains the operations and maintenance information entered by the user and sends script configuration commands to the agent server 12 based on this information.

[0098] Optionally, the proxy server 12 can pre-obtain and store multiple operation and maintenance scripts from the network, pre-obtain and store multiple operation and maintenance scripts from the data storage device 14, or receive and store multiple operation and maintenance scripts pre-input by the user. After obtaining the script configuration instructions, the proxy server 12 processes the stored multiple operation and maintenance scripts, obtains the target operation and maintenance script, and sends the target operation and maintenance script to the server 13 to be operated and maintained, so that the server 13 to be operated and maintained can execute the target operation and maintenance script and perform operation and maintenance on it.

[0099] The proxy server 12 and the server to be maintained 13 can be independent physical devices, or the functions of the proxy server 12 and the server to be maintained 13 can be integrated into the same physical device, or a physical device can integrate some of the functions of the proxy server 12 and some of the functions of the server to be maintained 13.

[0100] It should be noted that the appendix Figure 1 This is merely a schematic diagram illustrating one application scenario provided by an embodiment of this application. This embodiment does not necessarily represent... Figure 1 The included equipment is not limited, nor is it restricted. Figure 1 The positional relationships between devices are defined, for example, in Figure 1 In this context, the data storage device 14 can be an external storage device relative to the proxy server 12. In other cases, the data storage device 14 can also be placed within the proxy server 12.

[0101] For example, the system operation and maintenance method provided in the embodiments of this application can be applied to an automated operation and maintenance platform. Figure 2 This is a schematic diagram of a system architecture for an automated operation and maintenance platform provided in an embodiment of this application. For example... Figure 2 As shown, the system architecture may include: system access layer, proxy layer, data layer, business logic layer, and presentation layer.

[0102] Among them, automated operation and maintenance refers to the automation of daily task processing and operation and maintenance processes of Internet Technology (IT) infrastructure and business applications through operation and maintenance tools and platforms, thereby improving efficiency and reducing risks, and promoting the maturity of servers to be maintained and the upgrading of various capabilities.

[0103] The system access layer stores application programs and application databases, and is the foundational information for all servers connected to the automated operation and maintenance platform that are to be maintained.

[0104] The proxy layer is used to store the mapping relationship between the identifier of the server to be maintained and the identifier of the proxy server.

[0105] The data layer is used to store operation and maintenance operation definitions, operation and maintenance operation instantiation, and scenario orchestration. It contains the operation information of each server to be maintained that can perform operations. Scenario orchestration refers to organizing multiple operation and maintenance operations into complex tasks according to a certain order and triggering conditions.

[0106] The business logic layer is used to store the internal logic for basic operation and maintenance operations and scenarios.

[0107] The basic operation and maintenance (O&M) operations consist of three parts: O&M operation definition, O&M operation implementation, and interfaces. The O&M operation definition specifies the O&M operation type, name, parameters, and permissions. For example, currently supported O&M operations include system stop, system start, script execution, file viewing, simulated trading, health check, and network verification. The O&M operation implementation supports the execution of O&M operations and the viewing of results. The interfaces provide access to these basic services for other systems.

[0108] The scenario comprises three parts: scenario orchestration, scenario execution, and scenario interface. Scenario orchestration arranges multiple basic operational tasks together in a logical order. Using the Go language (also known as Golang), the scenario is stored as a graph, recording the dependencies between each node. Scenario execution performs a breadth-first search based on the node dependencies to execute each node. The scenario interface provides interface services for other systems to call the scenario.

[0109] The presentation layer is used to display the execution results and execution logs.

[0110] Optionally, the automated operation and maintenance platform corresponds to the operation and maintenance server.

[0111] The technical solution of this application will now be described in detail through specific embodiments.

[0112] It should be noted that the following specific embodiments can be combined with each other, and the same or similar concepts or processes may not be described again in some embodiments.

[0113] Figure 3 This is a flowchart illustrating an embodiment of the system operation and maintenance method provided in this application. Figure 3 As shown, the operation and maintenance method of this system may include the following steps:

[0114] S31. Based on the operation and maintenance information input by the user, generate a scheduled task and set the initial status of the scheduled task to pending execution.

[0115] The operation and maintenance information includes the identifier of the target server to be operated and maintained, the operation and maintenance scenario, the operation and maintenance parameters and time range, and the operation and maintenance scenario includes at least one operation and maintenance operation.

[0116] In one possible implementation, the operations and maintenance server displays a graphical user interface (GUI) on the screen via software or a browser, allowing users to interact with the server through the GUI. The operations and maintenance server retrieves user-inputted operational information by responding to user clicks on the GUI.

[0117] For example, a user can click the dropdown menu corresponding to the maintenance operation on the graphical user interface, select at least one maintenance operation, and then drag and drop the operation to adjust its order. Alternatively, after selecting an operation, the user can click the "move up" or "move down" control to adjust its order. Furthermore, the user can click the dropdown menu corresponding to the identifier of the server to be maintained, select the target server identifier, click the dropdown menus corresponding to the start and end times to select the start and end times respectively, and finally click the "complete" control. The maintenance server obtains the maintenance information entered by the user by responding to the user's click on the "complete" control.

[0118] In another possible implementation, the operations and maintenance server obtains the operations and maintenance information input by the user by receiving voice commands sent by the user.

[0119] Furthermore, the operations and maintenance server generates scheduled tasks based on the time range carried in the operations and maintenance information. These scheduled tasks include the time range carried in the operations and maintenance information.

[0120] S32. Based on the scheduled task, when the current time enters the time range and the status of the scheduled task is pending, generate the first script configuration instruction according to the operation and maintenance information, and change the status of the scheduled task to be implemented.

[0121] The first script configuration instructions include the identifier of the target server to be maintained, the maintenance scenario, and maintenance parameters.

[0122] In one specific implementation, the operation and maintenance server uses the Quartz scheduled task framework to obtain scheduled tasks with a status of pending execution at preset time intervals. It compares the current time with the time range of the scheduled task. If the current time is within the time range, it generates a first script configuration instruction and changes the status of the scheduled task to be executed. If the current time is not within the time range, it does not perform any operation.

[0123] Quartz is an open-source job scheduling framework written entirely in Java. Job scheduling refers to executing a piece of code at a certain time or time interval.

[0124] For example, the preset time interval can be 1 minute, 2 minutes, or 3 minutes, and can be set according to the actual performance of the operation and maintenance server. This application embodiment does not specifically limit this.

[0125] S33. Based on the identifier of the target server to be maintained and the mapping relationship between the identifier of the target server to be maintained and the identifier of the proxy server obtained in advance, determine the identifier of the target proxy server corresponding to the identifier of the target server to be maintained.

[0126] Optionally, the mapping relationship between the identifier of the server to be maintained and the identifier of the proxy server can be pre-stored by the maintenance personnel in the proxy layer of the automated maintenance platform. For example, the maintenance personnel can store the mapping relationship in the maintenance server through a terminal device used to receive the mapping relationship.

[0127] For example, the mapping relationship between the identifier of the server to be maintained and the identifier of the proxy server can be shown in Table 1 below:

[0128] Table 1

[0129] Identifier of servers awaiting maintenance Proxy server identifier Server A to be maintained Proxy server A Server B to be maintained Proxy server B Server C to be maintained Proxy server C

[0130] Taking the mapping relationship shown in Table 1 as an example, if the identifier of the target server to be maintained is server B, then according to the mapping relationship, the identifier of the proxy server corresponding to the identifier of the target server to be maintained is proxy server B.

[0131] S34. Send the first script configuration command to the target proxy server corresponding to the identifier of the target proxy server.

[0132] In one possible implementation, the operations and maintenance server calls the proxy control service and sends the first script configuration command to the target proxy server corresponding to the identifier of the target proxy server via a socket.

[0133] Correspondingly, the proxy server receives the first script configuration command sent by the operations and maintenance server.

[0134] S35. According to the first script configuration instructions, obtain at least one first operation and maintenance script corresponding to the operation and maintenance scenario from a plurality of pre-stored operation and maintenance scripts.

[0135] The operation and maintenance script can be obtained in advance from the network, entered in advance by the operation and maintenance personnel, or obtained in advance from the data storage device. It can be limited according to the actual situation, and this application embodiment does not impose specific restrictions on it.

[0136] In one specific implementation, at least one first operation and maintenance script is obtained from multiple operation and maintenance scripts according to the operation and maintenance operations of the operation and maintenance scenario in the first script configuration instructions.

[0137] In this application, the operation and maintenance operation and the first operation and maintenance script can be in a one-to-one correspondence, or one operation and maintenance operation can correspond to multiple first operation and maintenance scripts. This application does not impose specific restrictions on this.

[0138] It should be understood that different proxy servers store different types of operation and maintenance scripts beforehand. For example, assuming the operation and maintenance scenario is to check network services, the operation and maintenance scripts stored in the Linux proxy server are shell scripts, while those stored in the Windows proxy server are batch scripts.

[0139] Optionally, the proxy server can process tasks using multiple threads. That is, the proxy server can receive multiple script configuration instructions at the same time and allocate different threads to each script configuration instruction so that the proxy server can process multiple script configuration instructions simultaneously.

[0140] S36. Configure at least one first operation and maintenance script according to the operation and maintenance scenario and operation and maintenance parameters, and generate a second operation and maintenance script.

[0141] In one specific implementation, the operation and maintenance parameters are written into at least one first operation and maintenance script, and at least one first operation and maintenance script after the operation and maintenance parameters are written is obtained. Then, according to the execution order of each operation and maintenance operation in the operation and maintenance scenario, the at least one first operation and maintenance script after the operation and maintenance parameters are written is concatenated to generate a second operation and maintenance script.

[0142] In the first operation and maintenance script, each operation and maintenance parameter can be empty, and the proxy server will write the operation and maintenance parameters into the corresponding blank position in the first operation and maintenance script; or each operation and maintenance parameter in the first operation and maintenance script can be a preset initial value, and the proxy server will write the operation and maintenance parameters into the corresponding position in the first operation and maintenance script, overwriting the initial value in the first operation and maintenance script.

[0143] S37. Send the first maintenance instruction to the target server to be maintained.

[0144] The first maintenance instruction carries the second maintenance script.

[0145] The operation and maintenance method of the system provided in the above embodiments allows the operation and maintenance server to send script configuration instructions to different proxy servers. Upon receiving the script configuration instructions, the proxy servers can generate operation and maintenance instructions carrying the operation and maintenance scripts and send them to the server to be maintained. This eliminates the need to consider the differences in the scheduled operation and maintenance tasks configured on servers of different system types. The server to be maintained can automatically complete the operation and maintenance process according to the operation and maintenance instructions, achieving batch processing of servers to be maintained, improving the efficiency of operation and maintenance, and eliminating platform dependence. Furthermore, the proxy server can generate operation and maintenance instructions carrying complex operation and maintenance scripts based on the script configuration instructions sent by the operation and maintenance server. In contrast, in existing technologies, the scheduled tasks built into the server to be maintained only support simple operation commands and cannot meet the needs of complex scenarios with dependencies. This solution further improves the diversity of operation and maintenance processing.

[0146] Figure 4 This is a flowchart illustrating a second embodiment of the system operation and maintenance method provided in this application. Figure 4 As shown, for a proxy server, based on any of the above embodiments, after S37, the operation and maintenance method of the system may include the following steps:

[0147] For the server to be maintained, it receives the first maintenance instruction sent by the agent server, executes the instruction, and generates execution results and logs during execution. After completing the first maintenance instruction, the server sends the execution results and logs back to the agent server through a pre-installed agent application.

[0148] The execution result includes successful execution and execution failure.

[0149] S41. Receive the execution results and execution logs sent by the target server to be maintained;

[0150] S42. Send the execution results and execution logs to the operations and maintenance server.

[0151] In one possible implementation, the proxy server sends the execution results and execution logs to the operations and maintenance server via a socket.

[0152] Correspondingly, the operation and maintenance server receives the execution results and execution logs sent by the proxy server.

[0153] S43. Send the execution results and execution logs to the pre-configured terminal device for receiving operation and maintenance results.

[0154] Among them, the terminal device used to receive the operation and maintenance results can be the user's terminal device, such as the mobile phone or computer of the operation and maintenance personnel, or it can be other pre-set terminal devices, such as the terminal devices of other staff in the operation and maintenance department or the terminal devices of other department members of the enterprise.

[0155] Optionally, the operation and maintenance information entered by the user may carry the identifier of the terminal device, so that the execution results and execution logs are sent to the terminal device corresponding to the identifier.

[0156] For example, the operation and maintenance server can send execution results and execution logs to the terminal device by sending SMS or email, or it can send execution results and execution logs to the terminal device through an application (such as WeChat).

[0157] Optionally, in some embodiments, the operation and maintenance server can also display the execution results and execution logs through its own or external display devices, such as through a graphical user interface.

[0158] The system operation and maintenance method provided in the above embodiments sends the execution result and execution log of the first operation and maintenance instruction executed by the server to be maintained to a pre-configured terminal device, so that operation and maintenance personnel or other staff can know the execution result in a timely manner. In case of execution failure, subsequent repair operations can be performed in a timely manner, avoiding production risks caused by the failure of execution leading to the non-operation of certain functions of the system to be maintained.

[0159] Optionally, the scheduled task may also include a loop period, loop state, execution interval, and indication information, which indicates whether to generate instructions again after execution failure.

[0160] Figure 5 This is a flowchart illustrating a third embodiment of the system operation and maintenance method provided in this application. Figure 5 As shown, when a scheduled task includes a loop cycle, loop status, execution interval, and indication information, after the operations and maintenance server receives the execution results and execution logs sent by the agent server, the system's operations and maintenance methods may include the following steps:

[0161] S51. When the execution result is execution failure, the loop status is non-looping, and the indication information indicates that the instruction should be generated again after the execution failure, a second script configuration instruction is generated based on the execution interval and operation and maintenance information.

[0162] The second script configuration instructions include the identifier of the target server to be maintained, the maintenance scenario, and maintenance parameters.

[0163] Optionally, assuming the execution interval is 10 minutes, when the execution result is execution failure, the loop status is non-looping, and the indication message indicates that the instruction will be generated again after the execution failure, the timer will start counting. When the cumulative time obtained by the timer reaches 10 minutes, the second script configuration instruction will be generated according to the operation and maintenance information.

[0164] S52. Send the second script configuration command to the target proxy server.

[0165] Correspondingly, the proxy server receives the second script configuration instructions sent by the operations and maintenance server.

[0166] S53. Obtain the pre-stored second operation and maintenance script according to the second script configuration instructions.

[0167] Specifically, based on the operation and maintenance scenario and operation and maintenance parameters in the second script configuration instructions, the pre-stored second operation and maintenance script corresponding to the operation and maintenance scenario and operation and maintenance parameters is obtained.

[0168] S54. Based on the identifier of the target server to be maintained, send a second maintenance instruction to the target server to be maintained. The second maintenance instruction carries a second maintenance script.

[0169] Figure 6 This is a flowchart illustrating Embodiment 4 of the system operation and maintenance method provided in this application. Figure 6 As shown, when a scheduled task includes a loop cycle, loop status, execution interval, and indication information, after the operations and maintenance server receives the execution results and execution logs sent by the agent server, the system's operations and maintenance methods may include the following steps:

[0170] S61. When the execution result is execution failure, the loop status is loop, and the indication information indicates that the instruction should be generated again after the execution failure, a third script configuration instruction is generated based on the loop cycle and operation and maintenance information.

[0171] The third script configuration instructions include the identifier of the target server to be maintained, the maintenance scenario, and maintenance parameters.

[0172] Optionally, assuming the cycle is 10 minutes, when the execution result is execution failure, the cycle status is cycle, and the indication message indicates that the instruction will be generated again after the execution failure, the timer will start counting. When the cumulative time obtained by the timer reaches 10 minutes, the third script configuration instruction will be generated based on the operation and maintenance information.

[0173] S62. Send the third script configuration command to the target proxy server.

[0174] Correspondingly, for the proxy server, it receives the third script configuration instructions sent by the operation and maintenance server. The third script configuration instructions include the identifier of the target server to be operated and maintained, the operation and maintenance scenario, and the operation and maintenance parameters.

[0175] S63. Obtain the pre-stored second operation and maintenance script according to the third script configuration instructions.

[0176] Specifically, based on the operation and maintenance scenario and operation and maintenance parameters in the third script configuration instructions, a pre-stored second operation and maintenance script corresponding to the operation and maintenance scenario and operation and maintenance parameters is obtained.

[0177] S64. Based on the identifier of the target server to be maintained, send a third maintenance instruction to the target server to be maintained. The third maintenance instruction carries the second maintenance script.

[0178] Optionally, after receiving the execution result and execution log returned by the target proxy server, if the execution result is successful and the loop status is non-looping, the operation and maintenance server changes the status of the scheduled task from "in execution" to "executed".

[0179] Optionally, after receiving the execution results and execution logs returned by the target proxy server, if the execution result is execution failure, the loop status is non-looping, and the indication message indicates that no more instructions will be generated after the execution failure, the status of the scheduled task is changed from being implemented to being implemented.

[0180] In the above embodiments, when the execution result is a failure, the operation and maintenance server can determine whether to generate the instruction again based on the indication information in the operation and maintenance information, which reduces the manual cost and time cost of the operation and maintenance personnel to manually set it again, and further improves the efficiency and automation level of operation and maintenance processing.

[0181] The following are embodiments of the apparatus described in this application, which can be used to execute the embodiments of the method described in this application. For details not disclosed in the apparatus embodiments of this application, please refer to the embodiments of the method described in this application.

[0182] Figure 7 This is a schematic diagram of the structure of the operation and maintenance device of the system provided in this application, according to embodiment one. Figure 7 As shown, the system's operation and maintenance equipment includes:

[0183] The generation module 71 is used to generate a scheduled task based on the operation and maintenance information input by the user, and set the initial state of the scheduled task to be implemented. The operation and maintenance information includes the identifier of the target server to be operated and maintained, the operation and maintenance scenario, the operation and maintenance parameters and the time range. The operation and maintenance scenario includes at least one operation and maintenance operation, and the scheduled task includes the time range.

[0184] The generation module 71 is also used to generate a first script configuration instruction based on the operation and maintenance information when the current time enters the time range and the status of the scheduled task is pending implementation, and to change the status of the scheduled task to be implemented. The first script configuration instruction includes the identifier of the target server to be operated and maintained, the operation and maintenance scenario and operation and maintenance parameters.

[0185] The determination module 72 is used to determine the identifier of the target proxy server corresponding to the identifier of the target server to be maintained, based on the identifier of the target server to be maintained and the pre-obtained mapping relationship between the identifier of the server to be maintained and the identifier of the proxy server.

[0186] The sending module 73 is used to send the first script configuration command to the target proxy server corresponding to the identifier of the target proxy server.

[0187] In one possible design of an embodiment of this application, the apparatus further includes:

[0188] The receiving module is used to receive the execution results and execution logs returned by the target proxy server;

[0189] The sending module 73 is also used to send the execution results and execution logs to a pre-configured terminal device for receiving operation and maintenance results.

[0190] Optionally, the scheduled task also includes a loop cycle, a loop state, an execution interval, and an indication message. The indication message is used to indicate whether to generate the instruction again after the execution fails. The generation module 71 is used to generate a second script configuration instruction based on the execution interval and operation and maintenance information when the execution result is execution failure, the loop state is non-looping, and the indication message indicates that the instruction should be generated again after the execution failure. The second script configuration instruction includes the identifier of the target server to be maintained, the operation and maintenance scenario, and the operation and maintenance parameters.

[0191] Sending module 73 is used to send the second script configuration instructions to the target proxy server;

[0192] or;

[0193] The generation module 71 is used to generate a third script configuration instruction based on the cycle period and operation and maintenance information when the execution result is execution failure, the loop status is loop, and the indication information indicates that the instruction should be generated again after the execution failure. The third script configuration instruction includes the identifier of the target server to be maintained, the operation and maintenance scenario, and the operation and maintenance parameters.

[0194] The sending module 73 is used to send the third script configuration instructions to the target proxy server.

[0195] Optionally, after sending the first script configuration command to the target proxy server corresponding to the target server to be maintained, the device includes:

[0196] Modify the module to change the status of the scheduled task from "In Execution" to "Executed" when the execution result is "Successful" and the loop status is "Non-looping".

[0197] or;

[0198] When the execution result is execution failure, the loop status is non-looping, and the indication message indicates that no more instructions will be generated after the execution failure, the status of the scheduled task will be changed from "in execution" to "executed".

[0199] The system operation and maintenance device provided in this application embodiment can be used to execute the system operation and maintenance device in any of the above embodiments. Its implementation principle and technical effect are similar, and will not be described again here.

[0200] Figure 8 This is a schematic diagram of the structure of the operation and maintenance device of the system provided in this application, according to embodiment two. Figure 8 As shown, the system's operation and maintenance equipment includes:

[0201] The receiving module 81 is used to receive a first script configuration instruction sent by the operation and maintenance server. The first script configuration instruction includes the identifier of the target server to be operated and maintained, the operation and maintenance scenario and operation and maintenance parameters. The operation and maintenance scenario includes at least one operation and maintenance operation.

[0202] The acquisition module 82 is used to acquire at least one first operation and maintenance script corresponding to the operation and maintenance scenario from a plurality of pre-stored operation and maintenance scripts according to the first script configuration instructions;

[0203] The generation module 83 is used to configure at least one first operation and maintenance script according to the operation and maintenance scenario and operation and maintenance parameters, and generate a second operation and maintenance script.

[0204] The sending module 84 is used to send a first maintenance instruction to the target server to be maintained, and the first maintenance instruction carries a second maintenance script.

[0205] In one possible design of this application embodiment, the generation module 83 is specifically used for:

[0206] Write the operation and maintenance parameters into at least one first operation and maintenance script, and obtain at least one first operation and maintenance script after writing the operation and maintenance parameters;

[0207] Based on the execution order of each operation and maintenance operation in the operation and maintenance scenario, at least one first operation and maintenance script written with operation and maintenance parameters is concatenated to generate a second operation and maintenance script.

[0208] In another possible design of this application embodiment, the receiving module 81 is further configured to receive the execution result and execution log sent by the target server to be maintained;

[0209] The sending module 84 is also used to send the execution results and execution logs to the operation and maintenance server.

[0210] In another possible design of this application embodiment, after sending the first maintenance instruction to the target server to be maintained, the receiving module 81 is further configured to receive the second script configuration instruction sent by the maintenance server. The second script configuration instruction includes the identifier of the target server to be maintained, the maintenance scenario, and maintenance parameters.

[0211] The acquisition module 82 is also used to acquire the pre-stored second operation and maintenance script according to the second script configuration instructions;

[0212] The sending module 84 is also used to send a second maintenance instruction to the target maintenance server according to the identifier of the target maintenance server, the second maintenance instruction carrying a second maintenance script;

[0213] or;

[0214] The receiving module 81 is also used to receive a third script configuration instruction sent by the operation and maintenance server. The third script configuration instruction includes the identifier of the target server to be operated and maintained, the operation and maintenance scenario, and the operation and maintenance parameters.

[0215] The acquisition module 82 is also used to acquire the pre-stored second operation and maintenance script according to the third script configuration instructions;

[0216] The sending module 84 is also used to send a third maintenance instruction to the target maintenance server based on the identifier of the target maintenance server. The third maintenance instruction carries a second maintenance script.

[0217] The system operation and maintenance device provided in this application embodiment can be used to execute the system operation and maintenance device in any of the above embodiments. Its implementation principle and technical effect are similar, and will not be described again here.

[0218] It should be noted that the division of the various modules in the above device is merely a logical functional division. In actual implementation, they can be fully or partially integrated into a single physical entity, or they can be physically separated. Furthermore, these modules can be implemented entirely in software via processing element calls; they can be fully implemented in hardware; or some modules can be implemented by processing element calls to software, while others are implemented in hardware. Additionally, these modules can be fully or partially integrated together, or implemented independently. The processing element mentioned here can be an integrated circuit with signal processing capabilities. In the implementation process, each step of the above method or each of the above modules can be completed through the integrated logic circuits in the hardware of the processor element or through software instructions.

[0219] Figure 9 This is a schematic diagram of the server structure provided in an embodiment of this application. Figure 9As shown, the server may include: a processor 91, a memory 92, and computer program instructions stored in the memory 92 and executable on the processor 91. When the processor 91 executes the computer program instructions, it implements the operation and maintenance method of the system provided in any of the foregoing embodiments.

[0220] Optionally, the various components of the server can be connected via a system bus.

[0221] The memory 92 can be a separate memory unit or a memory unit integrated into the processor. There can be one or more processors.

[0222] Optionally, the server may also include interfaces for interacting with other devices.

[0223] Optionally, the server may also include a transceiver for communicating with other computers, which constitutes a communication interface.

[0224] Optionally, in terms of hardware implementation, the above Figure 7 The transmitting module 73 and the receiving module in the illustrated embodiment, or the above-mentioned Figure 8 The receiving module 81 and the transmitting module 84 in the illustrated embodiment correspond to the transceiver in this embodiment.

[0225] It should be understood that processor 91 can be a Central Processing Unit (CPU), or other general-purpose processors, digital signal processors (DSPs), application-specific integrated circuits (ASICs), etc. A general-purpose processor can be a microprocessor or any conventional processor. The steps of the method disclosed in this application can be directly implemented by a hardware processor, or implemented by a combination of hardware and software modules within the processor.

[0226] The system bus can be a Peripheral Component Interconnect (PCI) bus or an Extended Industry Standard Architecture (EISA) bus, etc. The system bus can be divided into address bus, data bus, control bus, etc. For ease of representation, only one thick line is used in the diagram, but this does not indicate that there is only one bus or one type of bus. Memory may include random access memory (RAM) and may also include non-volatile memory (NVM), such as at least one disk storage device.

[0227] All or part of the steps in the above-described method embodiments can be implemented by hardware related to program instructions. The aforementioned program can be stored in a readable memory. When the program is executed, it performs the steps of the above-described method embodiments; and the aforementioned memory (storage medium) includes: read-only memory (ROM), RAM, flash memory, hard disk, solid-state drive, magnetic tape, floppy disk, optical disk, and any combination thereof.

[0228] The server provided in this application embodiment can be used to execute the operation and maintenance method of the system provided in any of the above method embodiments. Its implementation principle and technical effect are similar, and will not be described again here.

[0229] This application provides a computer-readable storage medium storing computer instructions that, when executed on a computer, cause the computer to perform the operation and maintenance method of the aforementioned system.

[0230] The aforementioned computer-readable storage medium can be implemented by any type of volatile or non-volatile storage device or a combination thereof, such as static random access memory, electrically erasable programmable read-only memory, erasable programmable read-only memory, programmable read-only memory, read-only memory, magnetic storage, flash memory, magnetic disk, or optical disk. The readable storage medium can be any available medium accessible to a general-purpose or special-purpose computer.

[0231] Optionally, a readable storage medium can be coupled to a processor, enabling the processor to read information from and write information to the readable storage medium. Alternatively, the readable storage medium can be an integral part of the processor. Both the processor and the readable storage medium can reside in an Application Specific Integrated Circuit (ASIC). Alternatively, the processor and the readable storage medium can exist as discrete components within the device.

[0232] This application also provides a computer program product, which includes a computer program stored in a computer-readable storage medium. At least one processor can read the computer program from the computer-readable storage medium, and when the at least one processor executes the computer program, it can implement the operation and maintenance method of the above-mentioned system.

[0233] It should be understood that this disclosure is not limited to the precise structures described above and shown in the accompanying drawings, and various modifications and changes can be made without departing from its scope. The scope of this disclosure is limited only by the appended claims.

Claims

1. A system operation and maintenance method, characterized in that: Applicable to operation and maintenance servers, including: Generate a scheduled task according to the operation and maintenance information input by the user, and set the initial state of the scheduled task to be implemented, wherein the operation and maintenance information includes the identifier of the target server to be operated and maintained, the operation and maintenance scenario, the operation and maintenance parameters and the time range, wherein the operation and maintenance scenario includes at least one operation and maintenance operation, and the scheduled task includes the time range; According to the scheduled task, when the current moment enters the time range and the status of the scheduled task is to be implemented, a first script configuration instruction is generated according to the operation and maintenance information, and the status of the scheduled task is changed to being implemented, wherein the first script configuration instruction includes an identifier of the target server to be operated and maintained, the operation and maintenance scenario, and the operation and maintenance parameters; Determine the identifier of the target proxy server corresponding to the identifier of the target server to be operated and maintained according to the identifier of the target server to be operated and maintained and the mapping relationship between the identifier of the server to be operated and maintained and the identifier of the proxy server obtained in advance; The first script configuration instruction is sent to the target proxy server corresponding to the identifier of the target proxy server; the first script configuration instruction is used by the target proxy server to obtain at least one first operation and maintenance script corresponding to the operation and maintenance scenario from a plurality of pre-stored operation and maintenance scripts, so as to configure the at least one first operation and maintenance script according to the operation and maintenance scenario and the operation and maintenance parameters, and generate a second operation and maintenance script; The method further comprises: Receiving the execution result and execution log returned by the target proxy server; Sending the execution result and the execution log to a pre-configured terminal device for receiving operation and maintenance results; The timed task also includes a cycle period, a cycle state, an execution interval and indication information, wherein the indication information is used to indicate whether to generate an instruction again after an execution failure. The method also includes: When the execution result is execution failure, the loop state is non-loop, and the indication information indicates to generate an instruction again after the execution failure, a second script configuration instruction is generated according to the execution interval and the operation and maintenance information, wherein the second script configuration instruction includes an identifier of the target server to be operated and maintained, the operation and maintenance scenario, and the operation and maintenance parameters; Sending the second script configuration instruction to the target proxy server; or; When the execution result is execution failure, the loop state is loop, and the indication information indicates to generate instructions again after the execution fails, a third script configuration instruction is generated according to the loop period and the operation and maintenance information, and the third script configuration instruction includes an identifier of the target server to be operated and maintained, the operation and maintenance scenario, and the operation and maintenance parameters; The third script configuration instruction is sent to the target proxy server.

2. The method according to claim 1, characterized in that After receiving the execution result and the execution log returned by the target proxy server, the method further includes: When the execution result is successful execution and the loop state is non-loop, changing the state of the scheduled task from being executed to implemented; or; When the execution result is execution failure, the loop state is non-loop, and the indication information indicates that no instructions will be generated after the execution failure, the state of the scheduled task is changed from being implemented to implemented.

3. A system operation and maintenance method, characterized in that: Applicable to proxy servers, including: Receive a first script configuration instruction sent by the operation and maintenance server, the first script configuration instruction is generated according to the operation and maintenance information, the operation and maintenance information includes the identifier of the target server to be operated and maintained, the operation and maintenance scenario, the operation and maintenance parameters and the time range, the operation and maintenance scenario includes at least one operation and maintenance operation; the first script configuration instruction is generated according to the operation and maintenance information by the operation and maintenance server when the scheduled task enters the time range at the current moment and the status of the scheduled task is to be implemented; there is a mapping relationship between the identifier of the proxy server and the identifier of the target server to be operated and maintained, receive the execution result and the execution log sent by the target server to be operated and maintained; wherein the scheduled task also includes a loop period, a loop state, an execution interval and indication information, and the execution result and the execution log are mapped to the proxy server; The execution log is sent to the operation and maintenance server, so that when the execution result is execution failure, the loop state is non-loop, and the indication information indicates that the instruction is generated again after the execution failure, the operation and maintenance server generates a second script configuration instruction according to the execution interval and the operation and maintenance information, and the second script configuration instruction includes the identifier of the target server to be operated and maintained, the operation and maintenance scenario and the operation and maintenance parameters; or, when the execution result is execution failure, the loop state is loop, and the indication information indicates that the instruction is generated again after the execution failure, the operation and maintenance server generates a third script configuration instruction according to the loop period and the operation and maintenance information, and the third script configuration instruction includes the identifier of the target server to be operated and maintained, the operation and maintenance scenario and the operation and maintenance parameters; According to the first script configuration instruction, obtaining at least one first operation and maintenance script corresponding to the operation and maintenance scenario from a plurality of pre-stored operation and maintenance scripts; Configuring the at least one first operation and maintenance script according to the operation and maintenance scenario and the operation and maintenance parameters to generate a second operation and maintenance script; Sending a first operation and maintenance instruction to the target server to be operated and maintained, where the first operation and maintenance instruction carries the second operation and maintenance script; The method further comprises: Receive the second script configuration instruction or the third script configuration instruction sent by the operation and maintenance server.

4. The method according to claim 3, characterized in that The configuring the at least one first operation and maintenance script according to the operation and maintenance scenario and the operation and maintenance parameters to generate a second operation and maintenance script includes: Writing the operation and maintenance parameters into the at least one first operation and maintenance script, and obtaining at least one first operation and maintenance script after the operation and maintenance parameters are written; According to the execution order of each operation and maintenance operation in the operation and maintenance scenario, the at least one first operation and maintenance script after the operation and maintenance parameter is written is spliced ​​to generate the second operation and maintenance script.

5. The method according to claim 3 or 4, characterized in that: After sending the first operation and maintenance instruction to the target server to be operated and maintained, the method further includes: Receive a second script configuration instruction sent by the operation and maintenance server, where the second script configuration instruction includes an identifier of the target server to be operated and maintained, the operation and maintenance scenario, and the operation and maintenance parameters; According to the second script configuration instruction, obtaining the pre-stored second operation and maintenance script; Sending a second operation and maintenance instruction to the target server to be operated and maintained according to the identifier of the target server to be operated and maintained, where the second operation and maintenance instruction carries the second operation and maintenance script; or; Receive a third script configuration instruction sent by the operation and maintenance server, where the third script configuration instruction includes an identifier of the target server to be operated and maintained, the operation and maintenance scenario, and the operation and maintenance parameters; According to the third script configuration instruction, obtaining the second operation and maintenance script stored in advance; According to the identifier of the target server to be operated and maintained, a third operation and maintenance instruction is sent to the target server to be operated and maintained, where the third operation and maintenance instruction carries the second operation and maintenance script.

6. A system operation and maintenance device, characterized in that: Applicable to operation and maintenance servers, including: A generation module, configured to generate a scheduled task according to the operation and maintenance information input by the user, and set the initial state of the scheduled task to be implemented, wherein the operation and maintenance information includes the identifier of the target server to be operated and maintained, the operation and maintenance scenario, the operation and maintenance parameters and the time range, wherein the operation and maintenance scenario includes at least one operation and maintenance operation, and the scheduled task includes the time range; The generating module is further configured to generate, according to the scheduled task, a first script configuration instruction according to the operation and maintenance information, and change the state of the scheduled task to being implemented, when the current moment enters the time range and the state of the scheduled task is to be implemented, wherein the first script configuration instruction includes an identifier of the target server to be operated and maintained, the operation and maintenance scenario, and the operation and maintenance parameters; A determination module, configured to determine an identifier of a target proxy server corresponding to the identifier of the target server to be maintained, according to the identifier of the target server to be maintained and a mapping relationship between the identifier of the server to be maintained and the identifier of the proxy server obtained in advance; A sending module, configured to send the first script configuration instruction to a target proxy server corresponding to the identifier of the target proxy server; the first script configuration instruction is used by the target proxy server to obtain at least one first operation and maintenance script corresponding to the operation and maintenance scenario from a plurality of pre-stored operation and maintenance scripts, so as to configure the at least one first operation and maintenance script according to the operation and maintenance scenario and the operation and maintenance parameters, and generate a second operation and maintenance script; The receiving module is used to receive the execution result and execution log returned by the target proxy server; The sending module is further used to send the execution result and the execution log to a pre-configured terminal device for receiving operation and maintenance results; The scheduled task also includes a loop period, a loop state, an execution interval and indication information, the indication information is used to indicate whether to generate instructions again after execution failure, the generation module is further used to generate a second script configuration instruction according to the execution interval and the operation and maintenance information when the execution result is execution failure, the loop state is no loop, and the indication information indicates to generate instructions again after execution failure, the second script configuration instruction includes the identifier of the target server to be operated and maintained, the operation and maintenance scenario and the operation and maintenance parameters; The sending module is further used to send the second script configuration instruction to the target proxy server; Alternatively, the generating module is further configured to generate a third script configuration instruction according to the loop period and the operation and maintenance information when the execution result is an execution failure, the loop state is a loop, and the indication information indicates to generate an instruction again after the execution failure, wherein the third script configuration instruction includes an identifier of the target server to be operated and maintained, the operation and maintenance scenario, and the operation and maintenance parameters; The sending module is further used to send the third script configuration instruction to the target proxy server.

7. A system operation and maintenance device, characterized in that: Applicable to proxy servers, including: A receiving module, used to receive a first script configuration instruction sent by an operation and maintenance server, wherein the first script configuration instruction is generated according to operation and maintenance information, wherein the operation and maintenance information includes an identifier of a target server to be operated and maintained, an operation and maintenance scenario, operation and maintenance parameters and a time range, wherein the operation and maintenance scenario includes at least one operation and maintenance operation; the first script configuration instruction is generated according to the operation and maintenance information when the operation and maintenance server enters the time range at the current moment and the status of the scheduled task is to be implemented; there is a mapping relationship between the identifier of the proxy server and the identifier of the target server to be operated and maintained, and an execution result and an execution log sent by the target server to be operated and maintained are received; wherein the scheduled task also includes a cycle period, a cycle status, an execution interval and indication information, and the execution result is and the execution log is sent to the operation and maintenance server, so that when the execution result is execution failure, the loop state is non-loop, and the indication information indicates that the instruction is generated again after the execution failure, the operation and maintenance server generates a second script configuration instruction according to the execution interval and the operation and maintenance information, and the second script configuration instruction includes the identifier of the target server to be operated and maintained, the operation and maintenance scenario and the operation and maintenance parameters; or, when the execution result is execution failure, the loop state is loop, and the indication information indicates that the instruction is generated again after the execution failure, the operation and maintenance server generates a third script configuration instruction according to the loop period and the operation and maintenance information, and the third script configuration instruction includes the identifier of the target server to be operated and maintained, the operation and maintenance scenario and the operation and maintenance parameters; An acquisition module, configured to acquire, according to the first script configuration instruction, at least one first operation and maintenance script corresponding to the operation and maintenance scenario from a plurality of pre-stored operation and maintenance scripts; A generating module, configured to configure the at least one first operation and maintenance script according to the operation and maintenance scenario and the operation and maintenance parameters to generate a second operation and maintenance script; A sending module, configured to send a first operation and maintenance instruction to the target server to be operated and maintained, wherein the first operation and maintenance instruction carries the second operation and maintenance script; The receiving module is further used to receive the second script configuration instruction or the third script configuration instruction sent by the operation and maintenance server.

8. A server, comprising: A processor, a memory, and computer program instructions stored in the memory and executable on the processor, wherein the processor is used to implement the system operation and maintenance method as described in any one of claims 1 to 5 when executing the computer program instructions.

Citation Information

Patent Citations

  • Script execution method and device, computer equipment and storage medium

    CN109800145A

  • Automatic operation and maintenance management system and method

    CN111193602A