WO2021121067A1 - 一种任务执行的方法及装置 - Google Patents

一种任务执行的方法及装置 Download PDF

Info

Publication number
WO2021121067A1
WO2021121067A1 PCT/CN2020/134356 CN2020134356W WO2021121067A1 WO 2021121067 A1 WO2021121067 A1 WO 2021121067A1 CN 2020134356 W CN2020134356 W CN 2020134356W WO 2021121067 A1 WO2021121067 A1 WO 2021121067A1
Authority
WO
WIPO (PCT)
Prior art keywords
node
execution
management
management node
command
Prior art date
Application number
PCT/CN2020/134356
Other languages
English (en)
French (fr)
Inventor
陈交交
伦秉力
Original Assignee
深圳前海微众银行股份有限公司
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by 深圳前海微众银行股份有限公司 filed Critical 深圳前海微众银行股份有限公司
Publication of WO2021121067A1 publication Critical patent/WO2021121067A1/zh

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring
    • G06F11/3089Monitoring arrangements determined by the means or processing involved in sensing the monitored data, e.g. interfaces, connectors, sensors, probes, agents
    • G06F11/3093Configuration details thereof, e.g. installation, enabling, spatial arrangement of the probes
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring
    • G06F11/3003Monitoring arrangements specially adapted to the computing system or computing system component being monitored
    • G06F11/3006Monitoring arrangements specially adapted to the computing system or computing system component being monitored where the computing system is distributed, e.g. networked systems, clusters, multiprocessor systems
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06FELECTRIC DIGITAL DATA PROCESSING
    • G06F11/00Error detection; Error correction; Monitoring
    • G06F11/30Monitoring
    • G06F11/3051Monitoring arrangements for monitoring the configuration of the computing system or of the computing system component, e.g. monitoring the presence of processing resources, peripherals, I/O links, software programs

Definitions

  • the present invention relates to the field of computers, and in particular to a method and device for task execution.
  • saltstack (salt for short).
  • minion management system (hosting system) node, running the salt-minion daemon, used to receive commands and configurations sent by the master.
  • the salt-syndic process is a special salt-minion process, which is mainly responsible for receiving the salt-master( Also known as the command issued by the master of the master, it is issued twice through the local salt-master to the minions connected to the salt-master (salt-master running on the syndic). So the salt-master on the syndic node is the minions (regional autonomy) of the management area, and the salt-master on the master node can manage all the minions.
  • Figure 1 is an example diagram of task execution using a master-minion two-tier structure in the prior art. As shown in Figure 1, when the number of managed execution nodes is not large (less than 10,000), a simple master-minion two-tier structure can be used, and the master (control node) manages all minions (execution nodes).
  • the above two-tier structure is only applicable when the number of execution nodes is not large.
  • the simple two-tier structure may cause the load of the master to be too large.
  • master-syndic-minion will be used.
  • the three-tier structure decomposes the pressure of the master by adding syndic nodes (agent nodes).
  • syndic nodes agents nodes
  • the salt system sends commands to the specified minion by using the command line or calling api (Application Programming Interface) in the master or syndic, regardless of whether it is a two-layer or three-layer salt structure, the top layer Any one of the masters can control all minions, and the three-layer syndic can control the partial minions that belong to the syndic control.
  • api Application Programming Interface
  • all tasks in the three-tier architecture are issued by the master and finally reached the minion for execution through syndic.
  • the tasks are issued by the master to the minion for execution, that is to say whether it is in the second-tier or three-tier architecture
  • the final execution of the task is in the minion, but even if the syndic is directly connected to the minion in the three-layer structure, the task still has to go through the master, which shows that this efficiency is reduced.
  • the embodiments of the present invention provide a method and device for task execution, which are used to solve the problem of how to perform tasks efficiently.
  • an embodiment of the present invention provides a task execution method, which is suitable for a remote execution system including a monitoring center monitor, a control node master, an agent node syndic, and an execution node minion; wherein, the agent node and the control node are the execution nodes Management node; control node is also used to manage agent nodes; including:
  • a first command to be executed where the first command includes an identifier of a first execution node; the first execution node is one of the execution nodes;
  • the monitoring center determines the first management node corresponding to the first execution node according to the identification of the first execution node and the comparison relationship between the execution node and the management node, and the first management node is the first agent node or A first control node; the first management node is one of the management nodes;
  • the monitoring center obtains an execution result from the first management node; the execution result is returned to the first management node after the first execution node executes the first command.
  • the monitoring center directly sends the command to the first management node after receiving the command sent by the upper-layer service, thereby improving the efficiency of task execution and the reliability of the system.
  • the monitoring center provides an interface for executing the command externally, and the upper-layer service (service) You don’t need to care about which management node the command should be executed, just call the interface of the monitoring center, and the monitoring center decides how to execute it, so that the system supports the mixed deployment of salt two-layer and three-layer multi-environment, and in the three-tier architecture ,
  • the task is directly issued by the monitoring center to the first management node, avoiding the problem of errors when the execution results are returned in the three-tier architecture.
  • the method further includes:
  • the monitoring center receives an update message sent by a second management node, where the update message is used to instruct to update an execution node under the second management node;
  • the second management node is a second agent node or a second control node;
  • the second management node is any one of the management nodes;
  • the monitoring center updates the comparison relationship between the execution node and the management node according to the update message.
  • the execution node selects the next management node to connect, and the comparison relationship between the execution node and the management node changes, and the monitoring center obtains the change information through the interface deployed on each management node. Update the existing comparison table to realize that the system supports the dynamic establishment of the relationship between the execution node and the management node, so that the command can be executed quickly.
  • the method before the monitoring center receives the update message sent by the second management node, the method further includes:
  • the first execution node determines that the first management node is abnormal
  • the first execution node selects the second management node from the management nodes corresponding to the first execution node and establishes a connection with the second management node.
  • the execution node selects the next management node to connect. After the connection is successful, the data interface on the management node obtains the data of the execution node and reports it to the monitoring center. Make the monitoring center change the comparison relationship.
  • the comparison relationship between the execution node and the management node is obtained in the following manner:
  • the management node runs a second command, the second command is used to instruct to create a data file of the second execution node; the second execution node is that the management node does not obtain data from the cache The execution node of the file; the management node runs a third command after executing the second command, and the third command is used to instruct to determine each execution node with data files from the cache; the management node will Each execution node with a data file reports to the monitoring center;
  • the monitoring center establishes a comparison relationship between the execution node and the management node according to each execution node with data files reported by each management node.
  • the data file is created on the execution node that cannot be obtained in the cache because the data file does not exist, so that the data interface is directly All normal execution nodes can be obtained by reading the local cache of the management node.
  • the method further includes:
  • the management node receives the abnormal alarm information of the fourth execution node; the abnormal alarm information is caused by the expiration of the data file of the fourth execution node;
  • the management node runs a fourth command, and the fourth command is used to refresh the data file of the fourth execution node;
  • the management node After determining that the fourth execution node has not been reported to the monitoring center, the management node reports the fourth execution node to the monitoring center, so that the monitoring center updates the comparison between the execution node and the management node relationship.
  • the management node executes the fourth command (for example, executes salt "xxx” saltutil.refresh_pillar in the salt system) to refresh the data file to solve the problem. Data file "expired" problem.
  • determining the execution node for which the management node has not obtained the data file from the cache in the following manner includes:
  • the management node sends a fifth command to each execution node under the management node; the fifth command is used to obtain the execution status of the execution node, and the execution status includes connected, connection refused, and waiting for commands;
  • the management node obtains the execution node of the existing data file by traversing the file;
  • the management node determines the execution node that has not obtained the data file from the cache according to the execution status of each execution node and the execution node that already has the data file.
  • the data interface deployed on the management node has provided all the interfaces for executing the fifth command.
  • the monitoring center can periodically obtain the status of the execution node on each management node through these interfaces, and periodically create data files.
  • the node status is read from the local cache, so the efficiency will be very high, and it will not bring too much pressure to the system.
  • an embodiment of the present invention provides a task execution device, which is suitable for a remote execution system including a monitoring center, a control node, an agent node, and an execution node; wherein the agent node and the control node are the management nodes of the execution node; control Nodes are also used to manage agent nodes; including:
  • An obtaining module configured to obtain a first command to be executed, where the first command includes an identifier of a first execution node; the first execution node is one of the execution nodes;
  • the processing module is configured to determine the first management node corresponding to the first execution node through the comparison relationship between the execution node and the management node according to the identifier of the first execution node, and the first management node is a first proxy node Or a first control node; the first management node is one of the management nodes;
  • the execution result is obtained from the first management node; the execution result is returned to the first management node after the first execution node executes the first command.
  • processing module is also used to:
  • the second management node is a second proxy node or a second control node; the second The management node is any one of the management nodes;
  • the comparison relationship between the execution node and the management node is updated.
  • processing module is also used to:
  • the monitoring center Before the monitoring center receives the update message sent by the second management node, determining that the first management node is abnormal;
  • processing module is specifically configured to: obtain the comparison relationship between the execution node and the management node in the following manner:
  • the second command is used to instruct the creation of the data file of the second execution node; for the execution node that the management node does not obtain the data file from the cache; the management node executes After finishing the second command, run a third command, which is used to instruct to determine each execution node with data files from the cache; report each execution node with data files to the monitoring center;
  • processing module is also used to:
  • the abnormal alarm information of the fourth execution node is received; the abnormal alarm information is caused by the expiration of the data file of the fourth execution node ;
  • the fourth execution node After it is determined that the fourth execution node has not been reported to the monitoring center, the fourth execution node is reported to the monitoring center, so that the monitoring center updates the comparison relationship between the execution node and the management node.
  • processing module is specifically configured to:
  • the following methods are used to determine the execution node for which the management node has not obtained the data file from the cache, including:
  • each execution node and the execution node that already has the data file determine the execution node that has not obtained the data file from the cache.
  • an embodiment of the present invention provides a computer controlled device, including:
  • Memory used to store program instructions
  • the processor is configured to call the program instructions stored in the memory, and execute the method described in the first aspect above according to the obtained program.
  • an embodiment of the present invention provides a computer-readable non-volatile storage medium, including computer-readable instructions.
  • the computer reads and executes the computer-readable instructions, the computer executes the above-mentioned first aspect Methods.
  • Figure 1 is a schematic diagram of task execution in a master-minion two-tier structure provided by the prior art
  • Figure 2 is a schematic diagram of task execution in a three-tier master-syndic-minion structure provided by the prior art
  • FIG. 3 is a schematic diagram of a system architecture provided by an embodiment of the present invention.
  • FIG. 4 is a schematic diagram of a system architecture provided by an embodiment of the present invention.
  • FIG. 5 is a schematic diagram of a system architecture provided by an embodiment of the present invention.
  • FIG. 6 is a schematic flowchart of a task execution method provided by an embodiment of the present invention.
  • FIG. 7 is a schematic diagram of a process for establishing a comparison relationship according to an embodiment of the present invention.
  • FIG. 8 is a schematic structural diagram of a task execution device provided by an embodiment of the present invention.
  • the salt system will deploy a distribution module on the master to receive and execute commands.
  • this distribution module is called a worker.
  • the salt system performs the following steps:
  • Step 1 The worker sends corresponding commands on the master through the command line or calling the api method.
  • Step 2 The master immediately returns a task identification jid to the worker.
  • Step 3 After the command is successfully executed by master-syndic-minion, syndic will write the result into the database (such as redis, remote dictionary server, remote dictionary service), and the jid corresponding to the result will be marked.
  • the database such as redis, remote dictionary server, remote dictionary service
  • Step 4 The upper service service queries the database (such as redis) according to the jid. Specifically, when the master sends corresponding commands up and down, the jid will be generated during the execution of the command. Each jid corresponds to a task. The minion will not save it. After the minion executes the task, the result will be returned to the salt-master, and the salt-master will Correlate this result with jid and save it locally or in other storage media, such as redis.
  • the database such as redis
  • a task queue MQ can be added between the upper service service and the worker.
  • the service does not directly issue the task to the worker but first sends the task to the MQ, and then Workers on each master go to MQ to obtain tasks.
  • FIG. 4 is a schematic diagram of the system architecture after being added to the queue.
  • the service first sends multiple tasks to MQ (such as task 1, task 2,..., task 10), and then the workers on each master go to the MQ to obtain tasks.
  • MQ such as task 1, task 2,..., task 10.
  • worker1 on master1 goes to MQ to get task 1,...
  • worker10 on master10 goes to MQ to get task 10 (It should be noted that workers and tasks may not have a one-to-one correspondence.
  • a new task 11 is added.
  • Master1 can continue to obtain tasks from MQ 11).
  • the minion in the two-tier structure and the minion in the three-tier structure cannot be compared, which brings the expansion of the architecture Inconvenient to come. Further, the above solution cannot establish a dynamic connection relationship between the minion and the master or syndic, that is, when the master or syndic connected to the minion is abnormal, the upper-layer service cannot perceive the change of the minion to a specific salt environment.
  • the embodiment of the present invention provides a task execution method, which is used to solve the problem of avoiding abnormalities in the return of the execution result while efficiently executing tasks.
  • the task execution method provided by the embodiment of the present invention can be applied to the salt system architecture as shown in FIG. 5, and the salt system architecture includes a monitoring center monitor, a first management node (master or syndic), and a first execution node minion.
  • the monitoring center monitor is used to obtain the state of the first execution node minion, establish the relationship between the first execution node minion and the first management node, and send the command to be executed to the first management node corresponding to the establishment of the first execution node minion.
  • the monitoring center monitor provides an interface for uniformly executing commands to the outside.
  • the comparison relationship between the execution node and the management node established by the monitor is shown in Table 1, where salt_type indicates the type of the first management node corresponding to the first execution node, and the first management node is the first agent node syndic or the first agent node.
  • One control node master One control node master.
  • the minion_list is a collection of the identities of the first execution node, generally the IP address of the minion (Internet Protocol, the protocol for interconnection between networks), and the identity of the first execution node is included in the first command.
  • agent_url is the agent service address deployed on the first management node corresponding to the first execution node.
  • the monitor accepts the command sent by the upper-layer service service
  • the identifier of the first execution node in the acquisition command is "10.255.34.135".
  • the first management node corresponding to the first execution node is the first management node.
  • An agent node whose network address is ⁇ https://10.255.36.10:9443/s26 ⁇ , the monitor sends the first command directly to the first agent node, and the first agent node sends the first command to the first execution Node, after the execution is completed, the first agent node sends the result returned by the first execution node to the monitor.
  • salt_type indicates the type of the first management node corresponding to the first execution node
  • the first management node is the first agent node syndic or the first control node master.
  • the minion_list is a collection of the identities of the first execution node, generally the IP address of the minion (Internet Protocol, the protocol for interconnection between networks), and the identity of the first execution node is included in the first command.
  • agent_url is the agent service address deployed on the first management node corresponding to the first execution node. Specifically, when the monitor accepts the command sent by the upper-layer service service, the identifier of the first execution node in the acquisition command is "10.255.34.135".
  • the first management node corresponding to the first execution node is the first management node.
  • An agent node whose network address is ⁇ https://10.255.36.10:9443/s26 ⁇ , the monitor sends the first command directly to the first agent node, and the first agent node sends the first command to the first execution Node, after the execution is completed, the first agent node sends the result returned by the first execution node to the monitor.
  • the monitoring center monitor obtains the state of the first execution node minion through the agent (equivalent to an external data interface) on the first management node. That is, in the embodiment of the present application, an agent can be deployed on both the master and the syndic, and the interaction with the monitor can be realized through the agent.
  • the first management node includes the first control node master and the first agent node syndic, which is used to receive tasks issued by the monitor of the monitoring center and send the tasks to the corresponding first execution node minion.
  • FIG. 6 is a schematic flowchart corresponding to a task execution method provided by an embodiment of the present invention. As shown in FIG. 6, the method includes:
  • Step 601 The monitoring center obtains the first command to be executed.
  • the first command includes the identifier of the first execution node, and the first execution node is one of the execution nodes.
  • the monitoring center monitor deploys a data interface (agent) on the first agent node syndic and the first control node master, the monitor can quickly and efficiently obtain all the data of the first execution node minion, so that the monitor can provide externally.
  • the upper-level service service issues a task, the service does not need to determine the internal structure of the salt system, that is, the introduction of the monitor enables the system to support the mixed deployment of salt two-tier and three-tier multi-environment.
  • Step 602 The monitoring center determines the first management node corresponding to the first execution node through the comparison relationship between the execution node and the management node according to the identification of the first execution node.
  • the first management node is the first agent node syndic or the first control node master, and the first management node is one of the management nodes.
  • Step 603 The monitoring center sends the command to be executed to the first management node.
  • the monitor obtains the state of the minion through the agent in the above process, the relationship between the minion and the management node is established.
  • the monitor accepts the command sent by the upper service service, the monitor can quickly query the comparison between the execution node and the management node. Relationship, determine the first management node corresponding to the first execution node.
  • Step 604 The monitoring center obtains the execution result from the first management node.
  • the execution result is returned to the first management node after the first execution node executes the first command.
  • the reverse relationship (the relationship between the execution node and the management node) can be obtained, such as Table two shows:
  • minion agent_url_list 10.255.36.27 ["master_https://10.255.36.10:9443/m131"] 10.255.36.31 ["syndic_https://10.255.36.10:9443/s26"] 10.255.34.58 ["syndic_https://10.255.36.10:9443/s12"] 10.255.36.17 ["syndic_https://10.255.36.10:9443/s30"] 10.255.34.137 ["syndic_https://10.255.36.10:9443/s26"]
  • the monitor can issue the command to be executed to the designated syndic or master.
  • the command directly issued to the syndic execution efficiency will be faster.
  • the monitor of the monitoring center first determines which first execution node minion needs to create a data file.
  • the monitor obtains the normal minion data from the cache after the data file is created, so that the system supports fast and efficient acquisition of the status of all minions, and then establishes the relationship between the minion and the first management node (syndic or master), so that the monitor can accept the upper service service After the command is sent, the command is directly sent to the first management node, thereby improving the efficiency of task execution and the reliability of the system.
  • monitor does not depend on the specific environment of the minion itself (minion is in a two-tier structure (Still in the three-tier structure), it is only used to deploy data interfaces on all masters and syndics. Through these data interfaces, monitor can collect the minions controlled by syndic and master respectively, and then establish a correspondence between minion and syndic/master, monitor Provides an interface for executing commands externally.
  • the upper-level service service does not need to care about which master or syndic the command should be executed. It only calls the monitor interface, and the monitor decides how to execute it, so that the system supports salt two and three layers. Mixed environment deployment.
  • the management node runs the second command, the second command is used to instruct to create the data file of the second execution node; the second execution node is the execution node that the management node does not obtain the data file from the cache; the management node executes After finishing the second command, run the third command.
  • the third command is used to instruct each execution node with data files to be determined from the cache; the management node reports each execution node with data files to the monitoring center;
  • the monitoring center establishes a comparison relationship between the execution node and the management node according to each execution node with data files reported by each management node.
  • the salt "xxx" test.ping method is used in the existing solution to detect the status of all minions. This method requires the master to send commands to the minion.
  • the salt-run manage.present method is used to obtain the minion status. This method directly reads the master or syndic local cache without sending commands to the minion from the master, which improves efficiency and does not give the master or syndic Cause a lot of pressure.
  • minionid is the minion identifier, generally expressed by ip; here
  • data.p file of a specific minion in the cachedir directory Even if the minion is normal, if data.p does not exist, the agent still cannot get the minion from the cache.
  • the problem that the minion is normal but the corresponding data.p does not exist is solved by executing salt "xxx" pillar.items. Furthermore, after solving the problem that data.p does not exist, all normal minions can be obtained through manage.present.
  • the execution node for which the management node has not obtained the data file from the cache is determined by the following method:
  • the management node sends the fifth command to each execution node under the management node.
  • the fifth command is used to obtain the execution status of the execution node, and the execution status includes connected, connection refused, and waiting for commands.
  • the management node obtains the execution node of the existing data file by traversing the file. Then, the management node determines the execution node that has not obtained the data file from the cache according to the execution status of each execution node and the execution node that already has the data file.
  • accepted_keys, denied_keys, unaccepted_keys, rejected_keys are the results returned after the management node executes the salt-key command.
  • the minion in the salt system will initiate an authentication request to the master when it is started, and send its own public key to the master. After the master is authenticated, it will save and encrypt the received public key with the AES key and return it to the minion. Minion uses the private key to decrypt.
  • Execute the salt-key command on the management node to manage the minion key For example, execute the salt-key-L command to query, the returned result is:
  • slave1 is the minion that has established a connection with the management node, and slave3 has appeared in unaccepted keys, indicating that the minion corresponding to slave3 has contacted the management node, and the management node has obtained the minion public key, waiting for the next step instruction.
  • Both slave2 and slave4 are minions that have been rejected by the management node. Among them, slave2 is automatically rejected by the management node due to the duplication of IDs or the new secret key in the minion is generated but the previous secret key is not deleted, and slave4 is rejected by the management node by executing the salt-key.
  • conn_keys is a normal minionid, that is, a normal minion obtained from the cache directly using the second command
  • already_has_datap_keys is a minionid of an existing data.p, which is obtained by traversing the file.
  • the agent deployed on the master or syndic has provided all the interfaces of the above operations.
  • the monitor can obtain the status of the minion on each master or syndic regularly through these interfaces, and create the data file regularly, because the minion status is obtained through Read the local cache method, so the efficiency will be very high, and it will not bring too much pressure to the system.
  • the management node after the management node reports each execution node with data files to the monitoring center, the management node receives the abnormal alarm information of the fourth execution node.
  • abnormal alarm information is caused by the expiration of the data file of the fourth execution node.
  • the management node runs the fourth command. It should be noted that the fourth command is used to refresh the data file of the fourth execution node.
  • the management node determines that the fourth execution node has not been reported to the monitoring center, it reports the fourth execution node to the monitoring center, so that the monitoring center updates the comparison relationship between the execution node and the management node.
  • the above content is set in a scenario where an exception occurs during the execution of the task. This is because in the salt system, except for some minions that cannot be normally obtained by the data interface due to the absence of data files, there are also very few minions that have data files, but the data files are out of date. , The data interface still cannot be obtained normally. Therefore, the expired minions of these data files will be exposed during the task execution.
  • the management node executes the fourth command (execute salt "xxx" saltutil.refresh_pillar) to refresh the data file to solve the data.p "expiration" The problem.
  • the relationship established by the monitoring center from minion to syndic or master can also be mapping the IP address of minion or other information that can identify minion to the network address of syndic or master or other according to a preset algorithm. Can identify syndic or master information.
  • the relative address calculated according to the same algorithm is displayed in the table, and the specific address is not limited.
  • the monitor can use the netapi module in the salt instead of creating a data interface on each management node.
  • the netapi module contains rest_cherrypy, rest_tornado, and rest_uwsgi, and provides a rest interface for operating salt.
  • This interface is equivalent to the data interface deployed by the above monitor on the management node, covering common salt operations.
  • FIG. 7 is a schematic flowchart of a method for establishing an execution node and a management node in a monitoring center according to an embodiment of the application. The following describes the overall implementation process of the monitoring center dynamically establishing the relationship between the execution node and the management node in the embodiment of the present invention with reference to FIG. 7.
  • Step 701 The monitoring center receives an update message sent by the second management node.
  • the update message is used to instruct to update the execution node under the second management node
  • the second management node is the second agent node or the second control node
  • the second management node is any one of the management nodes.
  • the first execution node determines that the first management node is abnormal, and the first execution node selects the second management node from the management nodes corresponding to the first execution node and Establish a connection with the second management node.
  • Step 702 The monitoring center updates the comparison relationship between the execution node and the management node according to the update message.
  • minion All available masters can be connected at the same time, and multiple masters can be pointed to in the minion configuration file
  • all masters are available, when the master_type is failover (failover is actually a backup operation mode), minion only It will connect to one of the masters.
  • minion will choose to connect to the next master based on the set of all masters that this minion can connect to in the salt system itself.
  • minion will configure master_type as str
  • minion will configure master_type as failover, because if it is configured as str, a command issued on the master will be executed multiple times, as shown in Figure 2.
  • Master1 controls syndic1 and syndic2, syndic1 controls minion1, minion2, minion3 and minion4; syndic2 controls minion1, minion2, minion3 and minion4; when a command is sent on master1, the command is sent to minion1 through syndic1, and the command is sent to minion1 through syndic2 As a result, the command was executed twice on minion1, which is unacceptable.
  • the minion of the salt three-tier structure when configured with master_type as failover, the minion may be switched among multiple masters or syndics. Therefore, the connection relationship between the minion and the master or syndic may change dynamically. If the monitor wants to direct the command Sending to syndic requires maintaining a relationship from minion to syndic. Before issuing a command, find out the syndic corresponding to the execution object (minion) from the corresponding relationship established, and then call the agent on the syndic to issue the command.
  • the minion selects the next master or syndic to connect. After the connection is successful, the agent on the master or syndic obtains the data of the minion and reports it to the monitor, so that the monitor can change the control relationship.
  • the minion when the master or syndic connected to the minion is abnormal, the minion selects the next master or syndic to connect, and the comparison relationship between the minion and the master or syndic changes, and the monitor obtains the change information through the agent deployed to update the existing comparison relationship
  • the table realizes that the system supports the dynamic establishment of the relationship between minion and maste or syndic, so that commands can be executed quickly.
  • FIG. 8 exemplarily shows the structure of a task execution device provided by an embodiment of the present invention, and the device can execute the flow of the task execution method.
  • the device is suitable for a remote execution system including a monitoring center, a control node, an agent node, and an execution node; wherein the agent node and the control node are the management nodes of the execution node; the control node is also used to manage the agent node; include:
  • the obtaining module 801 is configured to obtain a first command to be executed, where the first command includes an identifier of a first execution node; the first execution node is one of the execution nodes;
  • the processing module 802 is configured to determine the first management node corresponding to the first execution node through the comparison relationship between the execution node and the management node according to the identification of the first execution node, and the first management node is a first agent Node or first control node; the first management node is one of the management nodes; the monitoring center sends the command to be executed to the first management node; the monitoring center receives the command from the first management node A management node obtains an execution result; the execution result is returned to the first management node after the first execution node executes the first command.
  • processing module 802 is further configured to:
  • the monitoring center receives an update message sent by a second management node, where the update message is used to instruct to update an execution node under the second management node;
  • the second management node is a second agent node or a second control node;
  • the second management node is any one of the management nodes;
  • the monitoring center updates the comparison relationship between the execution node and the management node according to the update message.
  • processing module 802 is further configured to:
  • the first execution node determines that the first management node is abnormal
  • the first execution node selects the second management node from the management nodes corresponding to the first execution node and establishes a connection with the second management node.
  • processing module 802 is specifically configured to obtain the comparison relationship between the execution node and the management node in the following manner:
  • the management node runs a second command, the second command is used to instruct to create a data file of the second execution node; the second execution node is that the management node does not obtain data from the cache The execution node of the file; the management node runs a third command after executing the second command, and the third command is used to instruct to determine each execution node with data files from the cache; the management node will Each execution node with a data file reports to the monitoring center;
  • the monitoring center establishes a comparison relationship between the execution node and the management node according to each execution node with data files reported by each management node.
  • processing module 802 is further configured to:
  • the management node After the management node reports each execution node with data files to the monitoring center, the management node receives the abnormal alarm information of the fourth execution node; the abnormal alarm information is due to the data of the fourth execution node Caused by outdated documents;
  • the management node runs a fourth command, and the fourth command is used to refresh the data file of the fourth execution node;
  • the management node After determining that the fourth execution node has not been reported to the monitoring center, the management node reports the fourth execution node to the monitoring center, so that the monitoring center updates the comparison between the execution node and the management node relationship.
  • processing module 802 is specifically configured to:
  • the following methods are used to determine the execution node for which the management node has not obtained the data file from the cache, including:
  • the management node sends a fifth command to each execution node under the management node; the fifth command is used to obtain the execution status of the execution node, and the execution status includes connected, connection refused, and waiting for commands;
  • the management node obtains the execution node of the existing data file by traversing the file;
  • the management node determines the execution node that has not obtained the data file from the cache according to the execution status of each execution node and the execution node that already has the data file.
  • an embodiment of the present invention also provides a computing controlled device, including:
  • Memory used to store program instructions
  • the processor is configured to call the program instructions stored in the memory, and execute the method for executing the above-mentioned tasks according to the obtained program.
  • embodiments of the present invention also provide a computer-readable non-volatile storage medium, including computer-readable instructions, which when the computer reads and executes the computer-readable instructions, cause the computer to perform the above-mentioned tasks Method of execution.
  • the embodiments of the present invention can be provided as a method, a system, or a computer program product. Therefore, the present invention may adopt the form of a complete hardware embodiment, a complete software embodiment, or an embodiment combining software and hardware. Moreover, the present invention may take the form of a computer program product implemented on one or more computer-usable storage media (including but not limited to disk storage, optical storage, etc.) containing computer-usable program codes.
  • These computer program instructions can also be stored in a computer readable memory that can guide a computer or other programmable data processing controlled equipment to work in a specific manner, so that the instructions stored in the computer readable memory produce a manufactured product including the instruction device,
  • the instruction device realizes the functions specified in one process or multiple processes in the flowchart and/or one block or multiple blocks in the block diagram.

Landscapes

  • Engineering & Computer Science (AREA)
  • Theoretical Computer Science (AREA)
  • Physics & Mathematics (AREA)
  • Computing Systems (AREA)
  • Quality & Reliability (AREA)
  • General Engineering & Computer Science (AREA)
  • General Physics & Mathematics (AREA)
  • Mathematical Physics (AREA)
  • Hardware Redundancy (AREA)
  • Computer And Data Communications (AREA)

Abstract

一种任务执行的方法及装置,适用于包括监控中心、控制节点、代理节点和执行节点的远程执行系统;方法包括:监控中心获取待执行的第一命令,通过执行节点与管理节点的对照关系,确定第一命令的第一执行节点对应的第一管理节点,将待执行的命令发送给第一管理节点,以从第一管理节点获取执行结果。监控中心接收上层服务发送的命令后直接发送至第一管理节点,提高了任务执行的效率以及系统的可靠性,并对外提供了执行命令的接口,上层服务无需关心将命令交给哪个管理节点执行,只用调用监控中心的接口由监控中心来决定怎么执行,使得系统支持salt二层和三层多环境混合部署,也避免了三层架构中执行结果返回时发生错误。

Description

一种任务执行的方法及装置
相关申请的交叉引用
本申请要求在2019年12月20日提交中国专利局、申请号为201911329738.1、申请名称为“一种任务执行的方法及装置”的中国专利申请的优先权,其全部内容通过引用结合在本申请中。
技术领域
本发明涉及计算机领域,尤其涉及一种任务执行的方法及装置。
背景技术
早期运维人员会根据自己的生产环境来写特定脚本完成大量重复性工作,这些脚本复杂且难以维护。系统管理员面临的问题中有一个不容忽视就是远程执行命令,因此诞生了saltstack、ansible等系统。
目前,较为主流的远程执行系统为saltstack(简称salt),首先,对salt系统中的部分用语进行解释说明,以便使本领域技术人员理解。
master:中心管理系统节点,运行salt-master守护进程,用于发送命令和配置到minion。
minion:管理系统(托管系统)节点,运行salt-minion守护进程,用于接收master发送的命令和配置。
syndic:(区域)管理系统节点,运行salt-syndic和salt-master两个守护进程,salt-syndic进程是一种特殊的salt-minion进程,它主要负责接收上层(master节点)的salt-master(又称为master of master)下发的命令并通过本地的salt-master二次下发到连接该salt-master(运行在syndic上的salt-master)的minions上。所以syndic节点上的salt-master是管理区域的minions(区域自治),master节点上的salt-master可以管理所有的minions。
也就是说,master和syndic均可作为管理节点。下面将结合附图对现有技术作进一步地详细描述。
图1为现有技术中采用master-minion两层结构进行任务执行的示例图。如图1所示,当管理的执行节点数量不大时(不过万),可以采用简单的master-minion两层结构,由master(控制节点)来管理所有的minion(执行节点)。
上述两层结构只适用于执行节点数量不大时,当执行节点数量达到一定规模后(过万),简单的两层结构可能会使master的负载过大,这时会采用master-syndic-minion三层结构(如图2所示),通过增加syndic节点(代理节点)来分解master的压力。当然不排除在某些必要的情况下(二层架构升级三层架构的过渡期),存在二层和三层共存的混合结构。
具体的,salt系统是通过在master或syndic使用命令行或调用api(Application Programming Interface,应用程序编程接口)的方式来下发命令到指定minion,不管是二层还是三层的salt结构,最上层的任一台master都可以控制所有的minion,三层的syndic可以控制局部的属于该syndic管控的minion。
从上述可以看出,由于任一台master都可以控制所有的minion,直接从master上下发命令是比较合理的,但是在三层的master上直接下发命令时会存在问题,就是在三层结构 的master上下发命令后有时无法正常返回结果,比如:返回一个报错“Minion did not return.[Not connected](执行节点无返回值,未连接上)”,而实际上minion是正常的且在syndic上是可以查询到结果的,但是在master上却不能得到正常的返回结果。
这是由于syndic采用区域自治,minion只会向连接的syndic发起认证,使得master并不知道syndic下面连接有多少minion,也不知道某个minion属于哪个syndic,所以在master上执行salt命令时,salt并不知道要多久才能等到所有minion返回的结果,甚至有的minion没有返回结果,它也是不知道的,一种可能的解决办法是加大等待时长,但这并不是根治的办法。
因此一方面,在三层架构所有任务都是通过master下发经过syndic最终到达minion执行,在二层架构中任务都是通过master下发到达minion执行,也就是说无论是在二层结构还是三层结构中,任务的最终执行是在minion,可是即便三层架构中与minion直接连接的是syndic,任务仍要经过master,由此可以看出这个效率是降低了的。
另一方面,当salt系统中二层和三层结构并存的时候,三层架构中minion将执行结果回复给master时会产生返回的执行结果错误的问题。
发明内容
本发明实施例提供一种任务执行的方法及装置,用于解决如何高效执行任务的问题。
第一方面,本发明实施例提供一种任务执行的方法,适用于包括监控中心monitor、控制节点master、代理节点syndic和执行节点minion的远程执行系统;其中,代理节点和控制节点为执行节点的管理节点;控制节点还用于管理代理节点;包括:
所述监控中心获取待执行的第一命令,所述第一命令包括第一执行节点的标识;所述第一执行节点为所述执行节点中的一个;
所述监控中心根据所述第一执行节点的标识,通过执行节点与管理节点的对照关系,确定所述第一执行节点对应的第一管理节点,所述第一管理节点为第一代理节点或第一控制节点;所述第一管理节点为所述管理节点中的一个;
所述监控中心将所述待执行的命令发送给所述第一管理节点;
所述监控中心从所述第一管理节点获取执行结果;所述执行结果是由所述第一执行节点执行所述第一命令后返回给所述第一管理节点的。
上述方案,监控中心接收上层服务发送的命令后直接将命令发送至第一管理节点,从而提高了任务执行的效率以及系统的可靠性,监控中心对外提供了执行命令的接口,上层服务(service)不需要关心应该将命令交给哪个管理节点执行,只用调用监控中心的接口,由监控中心来决定应该怎么执行,从而使得系统支持salt二层和三层多环境混合部署,同时三层架构中,任务直接由监控中心下发至第一管理节点,避免了三层架构中执行结果返回时发生错误的问题。
可选的,所述方法还包括:
所述监控中心接收第二管理节点发送的更新消息,所述更新消息用于指示更新所述第二管理节点下的执行节点;所述第二管理节点为第二代理节点或第二控制节点;所述第二管理节点为所述管理节点中的任一个;
所述监控中心根据所述更新消息,更新所述执行节点与管理节点的对照关系。
上述方案,执行节点或管理节点发生更新时,执行节点选择下一个管理节点进行连接, 执行节点到管理节点的对照关系发生了改变,监控中心通过其部署的在各管理节点上的接口获取变更信息更新已有的对照关系表,实现了系统支持动态建立执行节点与管理节点的关系,从而命令得以快速执行。
可选的,在所述监控中心接收第二管理节点发送的更新消息之前,还包括:
所述第一执行节点确定所述第一管理节点异常;
所述第一执行节点从所述第一执行节点对应的管理节点中选取所述第二管理节点并与所述第二管理节点建立连接。
需要说明的是,当执行节点连接的管理节点异常时,执行节点选择下一个管理节点进行连接,连接成功后,管理节点上的数据接口获取该执行节点的数据并将其上报给监控中心,以使监控中心更改对照关系。
可选的,所述执行节点与管理节点的对照关系通过如下方式获得:
针对任一管理节点,所述管理节点运行第二命令,所述第二命令用于指示创建第二执行节点的数据文件;所述第二执行节点为所述管理节点从缓存中未获取到数据文件的执行节点;所述管理节点执行完所述第二命令后,运行第三命令,所述第三命令用于指示从所述缓存中确定具有数据文件的各执行节点;所述管理节点将具有数据文件的各执行节点上报至所述监控中心;
所述监控中心根据各管理节点上报的各自的具有数据文件的各执行节点,建立所述执行节点与管理节点的对照关系。
上述方案,通过在管理节点运行第二命令(在salt系统中比如salt-run manage.present方式)在由于数据文件不存在从而无法在缓存中被获取的执行节点上创建数据文件,使得数据接口直接读取管理节点的本地缓存即可获取到所有正常的执行节点。从而为监控中心建立执行节点到管理节点的关系打下了坚实的基础。提高任务执行效率的同时提高了系统的可靠性。
可选的,在所述管理节点将具有数据文件的各执行节点上报至所述监控中心之后,所述方法还包括:
所述管理节点接收第四执行节点的异常报警信息;所述异常报警信息是由于所述第四执行节点的数据文件过期造成的;
所述管理节点运行第四命令,所述第四命令用于刷新所述第四执行节点的数据文件;
所述管理节点确定所述第四执行节点未上报至所述监控中心后,将所述第四执行节点上报至所述监控中心,以使所述监控中心更新所述执行节点与管理节点的对照关系。
需要说明的是,上述为设定于任务执行过程中出现异常的场景,这是由于salt系统中除了部分执行节点由于不存在数据文件而无法正常被数据接口获取,还存在极少数执行节点存在数据文件,但数据文件过期了,数据接口依然无法正常获取。因此这些数据文件过期的执行节点会在任务执行过程中暴露出来,本申请实施例中通过管理节点执行第四命令(比如在salt系统中执行salt“xxx”saltutil.refresh_pillar)来刷新数据文件从而解决数据文件“过期”的问题。
可选的,通过如下方式确定所述管理节点从缓存中未获取到数据文件的执行节点,包括:
所述管理节点向所述管理节点下的各执行节点发送第五命令;所述第五命令用于获取执行节点的执行状态,所述执行状态包括已经连接、拒绝连接、等待命令;
所述管理节点通过遍历文件获取已经存在数据文件的执行节点;
所述管理节点根据各执行节点的执行状态和已经存在数据文件的执行节点,确定从缓存中未获取到数据文件的执行节点。
上述方案,部署在管理节点上的数据接口已经提供了执行第五命令的所有接口,监控中心可以通过这些接口定时的获取每个管理节点上执行节点的状态,定时的创建数据文件,由于获取执行节点状态是通过读取本地缓存方式,所以效率会很高,而且不会给系统带来太多压力。
第二方面,本发明实施例提供一种任务执行的装置,适用于包括监控中心、控制节点、代理节点和执行节点的远程执行系统;其中,代理节点和控制节点为执行节点的管理节点;控制节点还用于管理代理节点;包括:
获取模块,用于获取待执行的第一命令,所述第一命令包括第一执行节点的标识;所述第一执行节点为所述执行节点中的一个;
处理模块,用于根据所述第一执行节点的标识,通过执行节点与管理节点的对照关系,确定所述第一执行节点对应的第一管理节点,所述第一管理节点为第一代理节点或第一控制节点;所述第一管理节点为所述管理节点中的一个;
将所述待执行的命令发送给所述第一管理节点;
从所述第一管理节点获取执行结果;所述执行结果是由所述第一执行节点执行所述第一命令后返回给所述第一管理节点的。
可选的,所述处理模块还用于:
接收第二管理节点发送的更新消息,所述更新消息用于指示更新所述第二管理节点下的执行节点;所述第二管理节点为第二代理节点或第二控制节点;所述第二管理节点为所述管理节点中的任一个;
根据所述更新消息,更新所述执行节点与管理节点的对照关系。
可选的,所述处理模块还用于:
在所述监控中心接收第二管理节点发送的更新消息之前,确定所述第一管理节点异常;
从所述第一执行节点对应的管理节点中选取所述第二管理节点并与所述第二管理节点建立连接。
可选的,所述处理模块具体用于:所述执行节点与管理节点的对照关系通过如下方式获得:
针对任一管理节点,运行第二命令,所述第二命令用于指示创建第二执行节点的数据文件;为所述管理节点从缓存中未获取到数据文件的执行节点;所述管理节点执行完所述第二命令后,运行第三命令,所述第三命令用于指示从所述缓存中确定具有数据文件的各执行节点;将具有数据文件的各执行节点上报至所述监控中心;
根据各管理节点上报的各自的具有数据文件的各执行节点,建立所述执行节点与管理节点的对照关系。
可选的,所述处理模块还用于:
在所述管理节点将具有数据文件的各执行节点上报至所述监控中心之后,接收第四执行节点的异常报警信息;所述异常报警信息是由于所述第四执行节点的数据文件过期造成的;
运行第四命令,所述第四命令用于刷新所述第四执行节点的数据文件;
确定所述第四执行节点未上报至所述监控中心后,将所述第四执行节点上报至所述监控中心,以使所述监控中心更新所述执行节点与管理节点的对照关系。
可选的,所述处理模块具体用于:
通过如下方式确定所述管理节点从缓存中未获取到数据文件的执行节点,包括:
向所述管理节点下的各执行节点发送第五命令;所述第五命令用于获取执行节点的执行状态,所述执行状态包括已经连接、拒绝连接、等待命令;
通过遍历文件获取已经存在数据文件的执行节点;
根据各执行节点的执行状态和已经存在数据文件的执行节点,确定从缓存中未获取到数据文件的执行节点。
第三方面,本发明实施例提供一种计算机被控设备,包括:
存储器,用于存储程序指令;
处理器,用于调用所述存储器中存储的程序指令,按照获得的程序执行上述第一方面所述的方法。
第四方面,本发明实施例提供一种计算机可读非易失性存储介质,包括计算机可读指令,当计算机读取并执行所述计算机可读指令时,使得计算机执行上述第一方面所述的方法。
附图说明
为了更清楚地说明本发明实施例中的技术方案,下面将对实施例描述中所需要使用的附图作简要介绍,显而易见地,下面描述中的附图仅仅是本发明的一些实施例,对于本领域的普通技术人员来讲,在不付出创造性劳动性的前提下,还可以根据这些附图获得其他的附图。
图1为现有技术提供的master-minion两层结构进行任务执行的示意图;
图2为现有技术提供的master-syndic-minion三层结构进行任务执行的示意图;
图3为本发明实施例提供的一种系统架构的示意图;
图4为本发明实施例提供的一种系统架构的示意图;
图5为本发明实施例提供的一种系统架构的示意图;
图6为本发明实施例提供的一种任务执行方法的流程示意图;
图7为本发明实施例提供的一种建立对照关系的流程示意图;
图8为本发明实施例提供的一种任务执行装置的结构示意图。
具体实施方式
为了更好的理解上述技术方案,下面将结合说明书附图及具体的实施方式对上述技术方案进行详细的说明,应当理解本发明实施例以及实施例中的具体特征是对本发明技术方案的详细的说明,而不是对本发明技术方案的限定,在不冲突的情况下,本发明实施例以及实施例中的技术特征可以相互结合。
为解决现有技术的问题,本发明实施例提供一种解决方案,具体如下:
如图3所示,通过使用缓存来保存结果的方式,可解决salt三层结构中在master上直接下发命令无法正常获取结果的问题。一般的,salt系统在master上会部署一个分配模块来接收和执行命令,这里称这个分配模块为worker,当worker接收到上层服务service 传过来的任务task时,salt系统执行以下步骤:
步骤1:worker通过命令行方式或者调用api方式在master上下发相应的命令。
步骤2:master立即返回给worker一个任务标识jid。
步骤3:命令经过master-syndic-minion执行成功后,syndic会将结果写入数据库(如redis,remote dictionary server,远程字典服务)中,其中会标明结果对应的jid。
步骤4:上层服务service根据jid去数据库(如redis)查询结果。具体的,在master上下发相应的命令时,在命令执行过程中会产生jid,每个jid对应一个任务,minion并不会保存,minion执行完任务将结果返回给salt-master,salt-master会将这个结果和jid对应起来并保存在本地或其他存储介质,比如redis中。
进一步的,为了实现系统的易扩展性和分布式部署,可以在上层服务service与worker之间增加一个任务队列MQ,service不直接将任务下发给worker而是将任务先下发到MQ,然后各master上的worker去MQ中获取任务。
进一步的,图4为加入队列后系统架构的示意图。如图4所示,service将多个任务先下发到MQ(比如任务1、任务2、…、任务10),然后各master上的worker去MQ中获取任务。比如,master1上的worker1去MQ中获取任务1,…,master10上的worker10去MQ中获取任务10(需要说明的是worker与任务可以不是一一对应的,比如上述举例中新来一个任务11时,master1可从MQ中继续获取任务11)。
然而,上述方案中所有任务都是通过master下发经过syndic最终到达minion执行,上层服务service异步的去redis查询结果,也就是说无论是在二层结构还是三层结构中,任务的最终执行是在minion,而二层结构中任务由master下发到minion,三层结构中任务由master下发经过syndic到达minion,由此可以看出这个效率是降低了的,同时当salt系统中二层和三层结构并存的时候,需要上层服务service维护一个minion到某个具体salt环境的关系,也就是说,二层结构中的minion和三层结构中的minion不能相提并论,这就给架构的扩展带来不便。进一步的,上述方案无法建立minion到master或syndic的动态连接关系,也就是说,当minion连接的master或syndic异常时,上层服务无法感知minion到某个具体salt环境的变化。
基于此,本发明实施例提供一种任务执行的方法,用于解决避免执行结果返回出现异常同时高效的执行任务的问题。
本发明实施例提供的任务执行方法,可以适用于如图5所示的salt系统架构中,该salt系统架构包括监控中心monitor、第一管理节点(master或syndic)、第一执行节点minion。
监控中心monitor用于获取第一执行节点minion的状态,建立第一执行节点minion与第一管理节点的关系,并将待执行的命令发送至与建立第一执行节点minion对应的第一管理节点。简而言之,监控中心monitor对外提供统一执行命令的接口。
举个例子,monitor建立的执行节点与管理节点的对照关系如表一所示,其中,salt_type指出第一执行节点对应的第一管理节点的类型,第一管理节点为第一代理节点syndic或第一控制节点master。minion_list为第一执行节点的标识的集合,一般为minion的IP地址(Internet Protocol,网络之间互联的协议),第一执行节点的标识被包含在第一命令中。agent_url为部署在第一执行节点对应的第一管理节点上的agent服务地址。具体的,当monitor接受上层服务service发送的命令时,获取命令中第一执行节点的标识为"10.255.34.135",根据表一的对照关系可确定第一执行节点对应的第一管理节点为第一 代理节点,其网络地址为{https://10.255.36.10:9443/s26},monitor直接将第一命令发送至第一代理节点上,第一代理节点再将第一命令发送给第一执行节点,执行完毕后第一代理节点将第一执行节点返回的结果发送至monitor。
表一
Figure PCTCN2020134356-appb-000001
其中,salt_type指出第一执行节点对应的第一管理节点的类型,第一管理节点为第一代理节点syndic或第一控制节点master。minion_list为第一执行节点的标识的集合,一般为minion的IP地址(Internet Protocol,网络之间互联的协议),第一执行节点的标识被包含在第一命令中。agent_url为部署在第一执行节点对应的第一管理节点上的agent服务地址。具体的,当monitor接受上层服务service发送的命令时,获取命令中第一执行节点的标识为"10.255.34.135",根据表一的对照关系可确定第一执行节点对应的第一管理节点为第一代理节点,其网络地址为{https://10.255.36.10:9443/s26},monitor直接将第一命令发送至第一代理节点上,第一代理节点再将第一命令发送给第一执行节点,执行完毕后第一代理节点将第一执行节点返回的结果发送至monitor。
具体的,如图5所示,监控中心monitor通过第一管理节点上的agent(相当于一个对外的数据接口)获取第一执行节点minion的状态。即本申请实施例中可以在master和syndic上都部署agent,通过agent实现与monitor的交互。
第一管理节点包括第一控制节点master和第一代理节点syndic,用于接收监控中心monitor下发的任务,并将任务发送给相应的第一执行节点minion。
基于图5所示意的系统架构,图6为本发明实施例提供的一种任务执行方法所对应的流程示意图,如图6所示,该方法包括:
步骤601,监控中心获取待执行的第一命令。
需要说明的是,第一命令包括第一执行节点的标识,第一执行节点为执行节点中的一个。
具体的,由于监控中心monitor通过在第一代理节点syndic以及第一控制节点master上部署了数据接口(即agent),使得monitor能够快速高效的获取所有第一执行节点minion的数据,从而monitor对外提供了同一执行命令的接口。当上层服务service下发了一个任务时,service无需确定salt系统的内部结构,也即monitor的引入使得系统支持salt两层和三层多环境混合部署。
步骤602,监控中心根据第一执行节点的标识,通过执行节点与管理节点的对照关系,确定第一执行节点对应的第一管理节点。
需要说明的是,第一管理节点为第一代理节点syndic或第一控制节点master,第一管理节点为管理节点中的一个。
步骤603,监控中心将待执行的命令发送给第一管理节点。
需要说明的是,由于monitor在上述过程中通过agent获取minion的状态,从而建立从minion到管理节点的关系,当monitor接受上层服务service发送的命令时,monitor可快速查询执行节点与管理节点的对照关系,确定第一执行节点对应的第一管理节点。
步骤604,监控中心从第一管理节点获取执行结果。
需要说明的是,执行结果是由第一执行节点执行第一命令后返回给第一管理节点的。本申请实施例中,有了上述表一所示的执行节点与管理节点的对照关系后(管理节点到执行节点的关系)即可得到其反向关系(执行节点到管理节点的关系),如表二所示:
表二
minion agent_url_list
10.255.36.27 ["master_https://10.255.36.10:9443/m131"]
10.255.36.31 ["syndic_https://10.255.36.10:9443/s26"]
10.255.34.58 ["syndic_https://10.255.36.10:9443/s12"]
10.255.36.17 ["syndic_https://10.255.36.10:9443/s30"]
10.255.34.137 ["syndic_https://10.255.36.10:9443/s26"]
从上述内容可以看出,有了上面的对应关系后,monitor就可以将要执行的命令下发到指定的syndic或master了,对于三层架构,命令直接下发到syndic执行效率会快一些。
根据上述内容可知,监控中心monitor首先确定哪些第一执行节点minion需要创建数据文件。monitor在创建数据文件完成后从缓存中获取正常的minion的数据,使得系统支持快速高效获取所有minion的状态,然后建立minion到第一管理节点(syndic或master)的关系,使得monitor接受上层服务service发送的命令后直接将命令发送至第一管理节点,从而提高了任务执行的效率以及系统的可靠性,同时由于monitor建立的关系不依赖minion本身所属的具体的环境(minion是在两层结构中还是在三层结构中),只用在所有master和syndic上部署数据接口,monitor通过这些数据接口可以收集到syndic和master各自控制的minion,然后建立起一个minion与syndic/master的对应关系,monitor对外提供了执行命令的接口,上层服务service不需要关心应该将命令交给哪个master或syndic执行,只用调用monitor接口,由monitor来决定应该怎么执行,从而使得系统支持salt二层和三层多环境混合部署。
基于上述内容,进一步的,执行节点与管理节点的对照关系通过如下方式获得:
针对任一管理节点,管理节点运行第二命令,第二命令用于指示创建第二执行节点的数据文件;第二执行节点为管理节点从缓存中未获取到数据文件的执行节点;管理节点执行完第二命令后,运行第三命令,第三命令用于指示从缓存中确定具有数据文件的各执行节点;管理节点将具有数据文件的各执行节点上报至监控中心;
监控中心根据各管理节点上报的各自的具有数据文件的各执行节点,建立执行节点与管理节点的对照关系。
此处,需要说明的是,现有方案中使用salt“xxx”test.ping的方式来检测所有minion的状态,这种方式需要在master上下发命令到minion。本申请实施例中使用salt-run manage.present的方式来获取minion状态,这种方式直接读取master或syndic本地缓存, 无需在master上下发命令到minion,提高效率的同时不会给master或syndic造成很大的压力。
然而,简单的使用salt-run manage.present方式是不可靠的,这种方式获取状态正常的minion的数量可能会少于实际正常的数量。经过分析发现造成这个现象的原因跟master/syndic管理的minion的数据文件具体为{cachedir}/{minionid}/data.p文件有关(需要说明的是,minionid为minion标识,一般用ip表示;这里意为cachedir目录下具体某一个minion的data.p文件),即使在minion正常的情况下,如果data.p不存在,agent依然不能从缓存中获取这个minion。本申请实施例中,通过执行salt“xxx”pillar.items解决minion正常但是对应的data.p不存在的问题。进一步的,在解决data.p不存在的问题后可以通过manage.present方式获取到所有正常的minion了。
通过上述内容可知,通过在管理节点(master或syndic)运行第二命令(salt-run manage.present方式)在由于数据文件(data.p)不存在从而无法在缓存中被获取的minion上创建数据文件(data.p),使得agent直接读取管理节点(master或syndic)的本地缓存即可获取到所有正常的minion。从而为monitor建立minion到管理节点(master或syndic)的关系打下了坚实的基础。提高任务执行效率的同时提高了系统的可靠性。
具体的,通过如下方式确定管理节点从缓存中未获取到数据文件的执行节点:
首先,管理节点向管理节点下的各执行节点发送第五命令。需要说明的是,第五命令用于获取执行节点的执行状态,执行状态包括已经连接、拒绝连接、等待命令。接着,管理节点通过遍历文件获取已经存在数据文件的执行节点。然后,管理节点根据各执行节点的执行状态和已经存在数据文件的执行节点,确定从缓存中未获取到数据文件的执行节点。
通过上述内容可知,有部分minion由于不存在数据文件而无法通过读取缓存获取,我们知道了如何创建数据文件以解决数据文件不存在的问题,但是,另一个问题也不容忽视,我们不可能在所有minion对应的syndic或master上创建数据文件以解决部分minion对应的syndic或master不存在数据文件的问题,这样反而舍本逐末。那么如何定位到应该创建数据文件的minion上就成为了解决问题的关键。本申请实施例确定了下面的计算方法:
need_to_create_datap_keys=accepted_keys–denied_keys–unaccepted_keys-rejected_keys–conn_keys–already_has_datap_keys
其中:accepted_keys,denied_keys,unaccepted_keys,rejected_keys为管理节点执行salt-key命令后返回的结果。
需要说明的是,salt系统中minion在启动时会向master发起认证请求,并将自己的公钥发给master,master认证后会保存并将收到的公钥加密AES密钥并返回给minion,minion使用私钥解密。在管理节点上执行salt-key命令用于管理minion秘钥。比如执行salt-key-L命令来查询,返回结果为:
{Accepted Keys:slave1
Denied Keys:slave2,
Unaccepted Keys:slave3
Rejected Keys:slave4}
上述内容说明,此时slave1是已经与管理节点建立连接的minion,slave3已经出现在unaccepted keys中,说明slave3对应的minion已经和管理节点联系,并且管理节点已 经获取了minion的公钥,等待下一步指令。slave2和slave4都是已经被管理节点拒绝的minion。其中,slave2是由于ID重复或者minion中新的秘钥生成但之前的秘钥没有删除而被管理节点自动拒绝,slave4是管理节点通过执行salt-key拒绝。
此外,本申请实施例中,conn_keys为正常的minionid即直接使用第二命令从缓存中获取的正常的minion,already_has_datap_keys为已经存在data.p的minionid,这是通过遍历文件获取到的。
进一步的,部署在master或syndic上的agent已经提供了上面操作的所有接口,monitor可以通过这些接口定时的获取每个master或syndic上minion的状态,定时的创建数据文件,由于获取minion状态是通过读取本地缓存方式,所以效率会很高,而且不会给系统带来太多压力。
为了更好的实现本方案实施例的效果,在管理节点将具有数据文件的各执行节点上报至监控中心之后,管理节点接收第四执行节点的异常报警信息。
需要说明的是,异常报警信息是由于第四执行节点的数据文件过期造成的。
接着,管理节点运行第四命令。需要说明的是,第四命令用于刷新所述第四执行节点的数据文件。
最后,管理节点确定第四执行节点未上报至监控中心后,将第四执行节点上报至监控中心,以使监控中心更新执行节点与管理节点的对照关系。
上述内容设定于任务执行过程中出现异常的场景,这是由于salt系统中除了部分minion由于不存在数据文件而无法正常被数据接口获取,还存在极少数minion存在数据文件,但数据文件过期了,数据接口依然无法正常获取。因此这些数据文件过期的minion会在任务执行过程中暴露出来,本申请实施例中通过管理节点执行第四命令(执行salt“xxx”saltutil.refresh_pillar)来刷新数据文件从而解决data.p“过期”的问题。
在其它可能的实现方式中,监控中心建立的从minion到syndic或master的关系还可以为将minion的IP地址或其他可以标识minion的信息根据预设的算法映射到syndic或master的网络地址或其他可以标识syndic或master的信息中。表格中显示根据同一算法计算的相对地址,具体不做限定。
在一种可能的方案中,如果没有特殊定制的需求,monitor可以不在各个管理节点上创建数据接口,而是用salt中的netapi模块。这是由于netapi模块里面包含了rest_cherrypy、rest_tornado以及rest_uwsgi,提供了操作salt的rest接口,这个接口相当于上述monitor在管理节点上部署的数据接口,覆盖了常用的salt操作。
基于上文的介绍,图7为本申请实施例提供的监控中心建立执行节点与管理节点方法的流程示意图。下面结合图7对本发明实施例监控中心动态建立执行节点与管理节点关系的整体实现过程进行描述。
如图7所示:
步骤701,监控中心接收第二管理节点发送的更新消息。
需要说明的是,更新消息用于指示更新第二管理节点下的执行节点,第二管理节点为第二代理节点或第二控制节点,第二管理节点为管理节点中的任一个。
具体的,在监控中心接收第二管理节点发送的更新消息之前,第一执行节点确定所述第一管理节点异常,第一执行节点从第一执行节点对应的管理节点中选取第二管理节点并与第二管理节点建立连接。
步骤702,监控中心根据更新消息,更新执行节点与管理节点的对照关系。
本申请实施例中,由于minion可以配置多master,当配置文件里的master_type为str
(可同时连接所有可用master,在minion的配置文件里可以指向多个master)时,所有master都是可用的,当master_type为failover(失效转移,实际上是一种备份操作模式)时,minion只会连接其中的一台master,当这台master异常后,minion会根据salt系统自身所带有的这台minion可以连接的所有master的集合中选择连接下一台master。一般在二层salt架构时,minion会配置master_type为str,但是三层salt架构时,minion会配置master_type为failover,因为如果配置成str,在master上下发一条命令会被执行多次,比如图2中master1控制syndic1和syndic2,syndic1控制minion1,minion2,minion3和minion4;syndic2控制minion1,minion2,minion3和minion4;当在master1上下发一条命令时,命令通过syndic1发送至minion1,命令又通过syndic2发送至minion1,这样一来minion1上执行了该命令两次,这个是不能接受的。
进一步的,当salt三层结构的minion配置master_type为failover时,minion可能会在多个master或syndic中发生切换,因此minion到master或syndic的连接关系可能是动态变化的,monitor要想将命令直接下发到syndic就需要维护一个从minion到syndic的关系,在下发命令前先从建立的对应的关系中查出执行对象(minion)对应的syndic,然后调用该syndic上的agent来下发命令。
进一步的,当minion连接的master或syndic异常时,minion选择下一个master或syndic进行连接,连接成功后,master或syndic上的agent获取该minion的数据并将其上报给monitor,以使monitor更改对照关系。
上述方案,当minion连接的master或syndic异常时,minion选择下一个master或syndic进行连接,minion到master或syndic的对照关系发生了改变,monitor通过其部署的agent获取变更信息更新已有的对照关系表,实现了系统支持动态建立minion与maste或syndic的关系,从而命令得以快速执行。
基于相同的技术构思,图8示例性的示出了本发明实施例提供任务执行的装置的结构,该装置可以执行任务执行的方法的流程。
如图8所示,该装置适用于包括监控中心、控制节点、代理节点和执行节点的远程执行系统;其中,代理节点和控制节点为执行节点的管理节点;控制节点还用于管理代理节点;包括:
获取模块801,用于获取待执行的第一命令,所述第一命令包括第一执行节点的标识;所述第一执行节点为所述执行节点中的一个;
处理模块802,用于根据所述第一执行节点的标识,通过执行节点与管理节点的对照关系,确定所述第一执行节点对应的第一管理节点,所述第一管理节点为第一代理节点或第一控制节点;所述第一管理节点为所述管理节点中的一个;所述监控中心将所述待执行的命令发送给所述第一管理节点;所述监控中心从所述第一管理节点获取执行结果;所述执行结果是由所述第一执行节点执行所述第一命令后返回给所述第一管理节点的。
可选的,所述处理模块802还用于:
所述监控中心接收第二管理节点发送的更新消息,所述更新消息用于指示更新所述第二管理节点下的执行节点;所述第二管理节点为第二代理节点或第二控制节点;所述第二管理节点为所述管理节点中的任一个;
所述监控中心根据所述更新消息,更新所述执行节点与管理节点的对照关系。
可选的,所述处理模块802还用于:
在所述监控中心接收第二管理节点发送的更新消息之前,所述第一执行节点确定所述第一管理节点异常;
所述第一执行节点从所述第一执行节点对应的管理节点中选取所述第二管理节点并与所述第二管理节点建立连接。
可选的,所述处理模块802具体用于:所述执行节点与管理节点的对照关系通过如下方式获得:
针对任一管理节点,所述管理节点运行第二命令,所述第二命令用于指示创建第二执行节点的数据文件;所述第二执行节点为所述管理节点从缓存中未获取到数据文件的执行节点;所述管理节点执行完所述第二命令后,运行第三命令,所述第三命令用于指示从所述缓存中确定具有数据文件的各执行节点;所述管理节点将具有数据文件的各执行节点上报至所述监控中心;
所述监控中心根据各管理节点上报的各自的具有数据文件的各执行节点,建立所述执行节点与管理节点的对照关系。
可选的,所述处理模块802还用于:
在所述管理节点将具有数据文件的各执行节点上报至所述监控中心之后,所述管理节点接收第四执行节点的异常报警信息;所述异常报警信息是由于所述第四执行节点的数据文件过期造成的;
所述管理节点运行第四命令,所述第四命令用于刷新所述第四执行节点的数据文件;
所述管理节点确定所述第四执行节点未上报至所述监控中心后,将所述第四执行节点上报至所述监控中心,以使所述监控中心更新所述执行节点与管理节点的对照关系。
可选的,所述处理模块802具体用于:
通过如下方式确定所述管理节点从缓存中未获取到数据文件的执行节点,包括:
所述管理节点向所述管理节点下的各执行节点发送第五命令;所述第五命令用于获取执行节点的执行状态,所述执行状态包括已经连接、拒绝连接、等待命令;
所述管理节点通过遍历文件获取已经存在数据文件的执行节点;
所述管理节点根据各执行节点的执行状态和已经存在数据文件的执行节点,确定从缓存中未获取到数据文件的执行节点。
基于相同的技术构思,本发明实施例还提供了一种计算被控设备,包括:
存储器,用于存储程序指令;
处理器,用于调用所述存储器中存储的程序指令,按照获得的程序执行上述任务执行的方法。
基于相同的技术构思,本发明实施例还提供了一种计算机可读非易失性存储介质,包括计算机可读指令,当计算机读取并执行所述计算机可读指令时,使得计算机执行上述任务执行的方法。
最后应说明的是:本领域内的技术人员应明白,本发明的实施例可提供为方法、系统、或计算机程序产品。因此,本发明可采用完全硬件实施例、完全软件实施例、或结合软件和硬件方面的实施例的形式。而且,本发明可采用在一个或多个其中包含有计算机可用程序代码的计算机可用存储介质(包括但不限于磁盘存储器、光学存储器等)上实施的计算 机程序产品的形式。
本发明是参照根据本发明的方法、被控设备(系统)、和计算机程序产品的流程图和/或方框图来描述的。应理解可由计算机程序指令实现流程图和/或方框图中的每一流程和/或方框、以及流程图和/或方框图中的流程和/或方框的结合。可提供这些计算机程序指令到通用计算机、专用计算机、嵌入式处理机或其他可编程数据处理被控设备的处理器以产生一个机器,使得通过计算机或其他可编程数据处理被控设备的处理器执行的指令产生用于实现在流程图一个流程或多个和/或方框图一个方框或多个方框中指定的功能的装置。
这些计算机程序指令也可存储在能引导计算机或其他可编程数据处理被控设备以特定方式工作的计算机可读存储器中,使得存储在该计算机可读存储器中的指令产生包括指令装置的制造品,该指令装置实现在流程图一个流程或多个流程和/或方框图一个方框或多个方框中指定的功能。
显然,本领域的技术人员可以对本发明进行各种改动和变型而不脱离本发明的范围。这样,倘若本发明的这些修改和变型属于本发明权利要求及其等同技术的范围之内,则本发明也意图包含这些改动和变型在内。

Claims (10)

  1. 一种任务执行的方法,其特征在于,适用于包括监控中心、控制节点、代理节点和执行节点的远程执行系统;其中,代理节点和控制节点为执行节点的管理节点;控制节点还用于管理代理节点;所述方法包括:
    所述监控中心获取待执行的第一命令,所述第一命令包括第一执行节点的标识;所述第一执行节点为所述执行节点中的一个;
    所述监控中心根据所述第一执行节点的标识,通过执行节点与管理节点的对照关系,确定所述第一执行节点对应的第一管理节点,所述第一管理节点为第一代理节点或第一控制节点;所述第一管理节点为所述管理节点中的一个;
    所述监控中心将所述待执行的命令发送给所述第一管理节点;
    所述监控中心从所述第一管理节点获取执行结果;所述执行结果是由所述第一执行节点执行所述第一命令后返回给所述第一管理节点的。
  2. 根据权利要求1所述的方法,其特征在于,所述方法还包括:
    所述监控中心接收第二管理节点发送的更新消息,所述更新消息用于指示更新所述第二管理节点下的执行节点;所述第二管理节点为第二代理节点或第二控制节点;所述第二管理节点为所述管理节点中的任一个;
    所述监控中心根据所述更新消息,更新所述执行节点与管理节点的对照关系。
  3. 根据权利要求2所述的方法,其特征在于,在所述监控中心接收第二管理节点发送的更新消息之前,还包括:
    所述第一执行节点确定所述第一管理节点异常;
    所述第一执行节点从所述第一执行节点对应的管理节点中选取所述第二管理节点并与所述第二管理节点建立连接。
  4. 根据权利要求1-3任一项所述的方法,其特征在于,所述执行节点与管理节点的对照关系通过如下方式获得:
    针对任一管理节点,所述管理节点运行第二命令,所述第二命令用于指示创建第二执行节点的数据文件;所述第二执行节点为所述管理节点从缓存中未获取到数据文件的执行节点;所述管理节点执行完所述第二命令后,运行第三命令,所述第三命令用于指示从所述缓存中确定具有数据文件的各执行节点;所述管理节点将具有数据文件的各执行节点上报至所述监控中心;
    所述监控中心根据各管理节点上报的各自的具有数据文件的各执行节点,建立所述执行节点与管理节点的对照关系。
  5. 根据权利要求4所述的方法,其特征在于,在所述管理节点将具有数据文件的各执行节点上报至所述监控中心之后,所述方法还包括:
    所述管理节点接收第四执行节点的异常报警信息;所述异常报警信息是由于所述第四执行节点的数据文件过期造成的;
    所述管理节点运行第四命令,所述第四命令用于刷新所述第四执行节点的数据文件;
    所述管理节点确定所述第四执行节点未上报至所述监控中心后,将所述第四执行节点上报至所述监控中心,以使所述监控中心更新所述执行节点与管理节点的对照关系。
  6. 根据权利要求4所述的方法,其特征在于,通过如下方式确定所述管理节点从缓 存中未获取到数据文件的执行节点,包括:
    所述管理节点向所述管理节点下的各执行节点发送第五命令;所述第五命令用于获取执行节点的执行状态,所述执行状态包括已经连接、拒绝连接、等待命令;
    所述管理节点通过遍历文件获取已经存在数据文件的执行节点;
    所述管理节点根据各执行节点的执行状态和已经存在数据文件的执行节点,确定从缓存中未获取到数据文件的执行节点。
  7. 一种任务执行的装置,其特征在于,所述装置包括:
    获取模块,用于获取待执行的第一命令,所述第一命令包括第一执行节点的标识;所述第一执行节点为所述执行节点中的一个;
    处理模块,用于根据所述第一执行节点的标识,通过执行节点与管理节点的对照关系,确定所述第一执行节点对应的第一管理节点,所述第一管理节点为第一代理节点或第一控制节点;所述第一管理节点为所述管理节点中的一个;
    发送模块,用于将所述待执行的命令发送给所述第一管理节点;
    所述获取模块,还用于从所述第一管理节点获取执行结果;所述执行结果是由所述第一执行节点执行所述第一命令后返回给所述第一管理节点的。
  8. 根据权利要求7所述的装置,其特征在于,所述处理模块还用于:
    接收第二管理节点发送的更新消息,所述更新消息用于指示更新所述第二管理节点下的执行节点;所述第二管理节点为第二代理节点或第二控制节点;所述第二管理节点为所述管理节点中的任一个;
    根据所述更新消息,更新所述执行节点与管理节点的对照关系。
  9. 一种计算设备,其特征在于,包括:
    存储器,用于存储程序指令;
    处理器,用于调用所述存储器中存储的程序指令,按照获得的程序执行权利要求1至6任一项所述的方法。
  10. 一种计算机可读非易失性存储介质,其特征在于,包括计算机可读指令,当计算机读取并执行所述计算机可读指令时,使得计算机执行如权利要求1至6任一项所述的方法。
PCT/CN2020/134356 2019-12-20 2020-12-07 一种任务执行的方法及装置 WO2021121067A1 (zh)

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
CN201911329738.1A CN111158980A (zh) 2019-12-20 2019-12-20 一种任务执行的方法及装置
CN201911329738.1 2019-12-20

Publications (1)

Publication Number Publication Date
WO2021121067A1 true WO2021121067A1 (zh) 2021-06-24

Family

ID=70557741

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/CN2020/134356 WO2021121067A1 (zh) 2019-12-20 2020-12-07 一种任务执行的方法及装置

Country Status (2)

Country Link
CN (1) CN111158980A (zh)
WO (1) WO2021121067A1 (zh)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN111158980A (zh) * 2019-12-20 2020-05-15 深圳前海微众银行股份有限公司 一种任务执行的方法及装置
CN114691241B (zh) * 2022-04-19 2024-01-19 中煤航测遥感集团有限公司 任务执行方法、装置、电子设备及存储介质

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102033777A (zh) * 2010-09-17 2011-04-27 中国资源卫星应用中心 基于ice的分布式作业调度引擎
US20150263900A1 (en) * 2014-03-11 2015-09-17 Schlumberger Technology Corporation High performance distributed computing environment particularly suited for reservoir modeling and simulation
CN106254471A (zh) * 2016-08-09 2016-12-21 华为技术有限公司 一种异构云环境下资源统一调度方法及系统
CN111158980A (zh) * 2019-12-20 2020-05-15 深圳前海微众银行股份有限公司 一种任务执行的方法及装置

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN102033777A (zh) * 2010-09-17 2011-04-27 中国资源卫星应用中心 基于ice的分布式作业调度引擎
US20150263900A1 (en) * 2014-03-11 2015-09-17 Schlumberger Technology Corporation High performance distributed computing environment particularly suited for reservoir modeling and simulation
CN106254471A (zh) * 2016-08-09 2016-12-21 华为技术有限公司 一种异构云环境下资源统一调度方法及系统
CN111158980A (zh) * 2019-12-20 2020-05-15 深圳前海微众银行股份有限公司 一种任务执行的方法及装置

Also Published As

Publication number Publication date
CN111158980A (zh) 2020-05-15

Similar Documents

Publication Publication Date Title
CN102640108B (zh) 已复制数据的监控
US8862928B2 (en) Techniques for achieving high availability with multi-tenant storage when a partial fault occurs or when more than two complete faults occur
CN102656565B (zh) 已复制数据的故障切换和恢复的方法和系统
CN108632067B (zh) 容灾部署方法、装置及系统
WO2020062131A1 (zh) 一种基于区块链技术的容器云管理系统
US7716373B2 (en) Method, apparatus, and computer product for updating software
CA2467813C (en) Real composite objects for providing high availability of resources on networked systems
TWI344090B (en) Management of a scalable computer system
WO2019210580A1 (zh) 访问请求处理方法、装置、计算机设备和存储介质
WO2021121067A1 (zh) 一种任务执行的方法及装置
WO2020248507A1 (zh) 基于容器云的系统资源监控方法及相关设备
JP2012507075A (ja) 分散データシステムにおける構成管理
CN113515499B (zh) 一种数据库服务方法及系统
CN106911648B (zh) 一种环境隔离方法及设备
WO2016074167A1 (zh) 分布式系统中锁服务器故障的处理方法及其系统
CN110971702A (zh) 服务调用方法、装置、计算机设备及存储介质
JP2021051532A (ja) 計算機システム
CN107992491A (zh) 一种分布式文件系统、数据访问和数据存储的方法及装置
CN111339139A (zh) 数据处理方法、装置、设备和存储介质
CN113505027B (zh) 业务系统备份方法、装置、设备及存储介质
CA3138764A1 (en) Data processing method, device, computer equipment and storage medium
CN112214377B (zh) 一种设备管理方法及系统
CN112035062B (zh) 云计算的本地存储的迁移方法、计算机设备及存储介质
WO1997049034A1 (fr) Systeme de prise en charge de taches
US11153173B1 (en) Dynamically updating compute node location information in a distributed computing environment

Legal Events

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

Ref document number: 20902482

Country of ref document: EP

Kind code of ref document: A1

NENP Non-entry into the national phase

Ref country code: DE

32PN Ep: public notification in the ep bulletin as address of the adressee cannot be established

Free format text: NOTING OF LOSS OF RIGHTS PURSUANT TO RULE 112(1) EPC (EPO FORM 1205 DATED 14/10/2022)

122 Ep: pct application non-entry in european phase

Ref document number: 20902482

Country of ref document: EP

Kind code of ref document: A1