CN111274033B - Resource deployment method, device, server and storage medium - Google Patents
Resource deployment method, device, server and storage medium Download PDFInfo
- Publication number
- CN111274033B CN111274033B CN202010060020.3A CN202010060020A CN111274033B CN 111274033 B CN111274033 B CN 111274033B CN 202010060020 A CN202010060020 A CN 202010060020A CN 111274033 B CN111274033 B CN 111274033B
- Authority
- CN
- China
- Prior art keywords
- physical machine
- service
- resource pool
- resource
- physical
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Active
Links
- 238000000034 method Methods 0.000 title claims abstract description 87
- 230000008569 process Effects 0.000 claims abstract description 22
- 238000012544 monitoring process Methods 0.000 claims abstract description 15
- 235000010425 Sorbus domestica Nutrition 0.000 claims description 26
- 240000005332 Sorbus domestica Species 0.000 claims description 26
- 230000005012 migration Effects 0.000 claims description 13
- 238000013508 migration Methods 0.000 claims description 13
- 230000015654 memory Effects 0.000 claims description 9
- 230000004048 modification Effects 0.000 claims description 8
- 238000012986 modification Methods 0.000 claims description 8
- 238000010586 diagram Methods 0.000 description 19
- 230000006870 function Effects 0.000 description 15
- 238000002955 isolation Methods 0.000 description 14
- 230000004044 response Effects 0.000 description 9
- 239000002699 waste material Substances 0.000 description 8
- 239000000463 material Substances 0.000 description 2
- 238000012545 processing Methods 0.000 description 2
- 230000009467 reduction Effects 0.000 description 2
- 230000005856 abnormality Effects 0.000 description 1
- 230000006978 adaptation Effects 0.000 description 1
- 238000004590 computer program Methods 0.000 description 1
- 238000010276 construction Methods 0.000 description 1
- 238000013461 design Methods 0.000 description 1
- 238000005516 engineering process Methods 0.000 description 1
- 238000012216 screening Methods 0.000 description 1
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F9/00—Arrangements for program control, e.g. control units
- G06F9/06—Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
- G06F9/46—Multiprogramming arrangements
- G06F9/50—Allocation of resources, e.g. of the central processing unit [CPU]
- G06F9/5083—Techniques for rebalancing the load in a distributed system
Landscapes
- Engineering & Computer Science (AREA)
- Software Systems (AREA)
- Theoretical Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Data Exchanges In Wide-Area Networks (AREA)
- Mobile Radio Communication Systems (AREA)
Abstract
The embodiment of the application discloses a resource deployment method, a device, a server and a storage medium, relates to the technical field of networks, and solves the problem that a large amount of resources are wasted in the process of running service lines. The specific scheme is as follows: the first resource pool is deployed for the first service line, wherein the first resource pool comprises a plurality of physical machines configured with first tags, and the physical machines configured with the first tags are deployed to run services of the first service line. And monitoring the resource utilization rate of the first resource pool in the process of running the service of the first service line on the physical machine included in the first resource pool. And when the resource utilization rate of the first resource pool is smaller than a first threshold value, migrating the running service to the second physical machine. The first physical machine is a physical machine whose resource utilization rate in the first resource pool is smaller than a second threshold, the second physical machine is a physical machine capable of providing resources required to operate a service operated in the first physical machine, and the second physical machine is a physical machine in the first resource pool and is different from the first physical machine.
Description
Technical Field
The disclosure relates to the field of network technologies, and in particular, to a resource deployment method, a device, a server and a storage medium.
Background
At present, the physical machine cluster capable of providing resources such as a processor, a memory and the like is built by self, so that the flexibility of supporting service line operation is poor, and higher cost investment is brought, so that resource sharing has become a popular choice. In addition, the isolation of resources is also a necessary requirement for the construction of the basic resource system of the internet company at present.
For example, when a business party needs to run multiple business lines on a cluster of physical machines, the deployment party may be purchased or leased with the right to use the physical machines for the operation of the business lines. And the deployment party can build different physical machine clusters for different service lines so as to realize resource isolation and ensure the relative independent operation of the different service lines. For example, consider a business party that needs to run 2 business lines (e.g., business line 1 and business line 2). As shown in fig. 1, the deployment party can determine that 3 physical machines are needed for the service line 1 and 4 physical machines are needed for the service line 2 according to the resources needed for the service line 1 and the service line 2 to operate, and select 3 physical machine building clusters 1 from available clusters for the service line 1 to operate, and select 4 physical machine building clusters 2 for the service line 2 to operate. When the service line runs, the situation of insufficient resources may occur, and the deployment party may allocate the available physical machines from the available clusters and add the available physical machines to the corresponding physical machine clusters so as to meet the requirement of the service line on the resources.
It can be seen that the physical machine clusters are individually set up for different service lines, so that isolation of corresponding resources of different service lines can be realized. However, because the isolated physical machine resources cannot be used by other service lines, when the resource utilization rate of the physical machine cluster built by the service line pair is low, the physical machines in the physical machine cluster cannot provide resources for the operation of other service lines, but are always at a level with low resource utilization rate, so that a great deal of waste of the physical machine resources is caused.
Disclosure of Invention
The disclosure provides a resource deployment method, device and system, which can stably and conveniently adjust the number of resources in a resource pool for providing resources for a service line so as to reduce the waste of the resources. The technical scheme of the present disclosure is as follows:
in a first aspect of embodiments of the present disclosure, a resource deployment method is provided, which may include: a first resource pool is deployed for the first service line, wherein the first resource pool comprises a plurality of physical machines configured with first tags, and the physical machines configured with the first tags are deployed to run services of the first service line. And monitoring the resource utilization rate of the first resource pool in the process of running the service of the first service line on the physical machine included in the first resource pool. And when the resource utilization rate of the first resource pool is smaller than a first threshold value, migrating the service running in the first physical machine to the second physical machine. The first physical machine is a physical machine whose resource utilization rate in the first resource pool is smaller than a second threshold, the second physical machine is a physical machine capable of providing resources required to operate a service operated in the first physical machine, the second physical machine is a physical machine in the first resource pool, and the second physical machine is different from the first physical machine.
Based on the method, the labels are configured for the physical machines deployed for the service lines so as to realize the isolation of the resources of different service lines, and when the resources deployed for a certain service line are required to be compressed, the resources provided by the physical machines can be quickly and safely removed from the deployed resource pool by modifying the labels of the physical machines, so that the waste of the resources is reduced.
Optionally, the physical machines that are not deployed outside the first resource pool are configured with a second tag, and after migrating the service running in the first physical machine to the second physical machine, the method further includes: the first label of the first physical machine is modified to a second label. Based on the method, the removed physical machine can be classified into the physical machine which is not deployed, so that the idle physical machine can be used when a resource pool is deployed for other services, and the utilization rate of the physical machine resources is improved.
Optionally, the modifying the first tag of the first physical machine to a second tag includes: before starting to migrate a service running in a first physical machine to a second physical machine, the first label of the first physical machine is modified to a third label, and the physical machine configured with the third label is a physical machine that does not run any service. And after the service running in the first physical machine is migrated to the second physical machine, modifying the third label of the first physical machine into the second label. Based on the method, the label of the first physical machine is modified to be a third label, so that the first physical machine can not bear the running task of new service any more, and the label of the first physical machine is modified to be a second label, so that the first physical machine is classified into undeployed physical machines and can be deployed to other service lines.
Optionally, the migration of the service running in the first physical machine to the second physical machine includes: and when the service running in the first physical machine is allowed to be migrated, migrating the service running in the first physical machine to the second physical machine. Based on the method, the service in the first physical machine is determined to be migrated, and the service is migrated, so that no service is operated in the first physical machine, and therefore, in the process of removing the first physical machine from the first resource pool, no influence is caused on the operation of the first service line.
Optionally, the deploying a first resource pool for the first service line includes: and receiving the resource requirement of the first service line. The first tag is configured for each of a plurality of physical machines according to the resource requirement. The resource provided by the plurality of physical machines meets the resource requirement, and the plurality of physical machines configured as the first tag form the first resource pool. Based on the method, the method is realized by configuring the labels for the physical machines so that the resources of the physical machines with the same labels can form a resource pool corresponding to the service lines, and the isolation of the resources of different service lines is realized on the premise of not independently constructing the clusters.
Optionally, after the deploying the first resource pool for the first service line, the method further includes: binding the first resource pool with the service tree node where the first service line is located, and selecting the first resource pool corresponding to the first service line by a user when the service of the first service line needs to be operated. Based on the method, the distributed resource pool is bound with the service tree node where the service line is located, so that the service of the service line can not be wrongly operated in other resource pools, and the isolation of resources is ensured.
Optionally, the method further comprises: and receiving the service of the first service line and an instruction of selecting the first resource pool by a user. In response to the instruction, the service of the first service line is run on a physical machine included in the first resource pool. Based on the method, after the first resource pool is deployed for the first service line, physical machines running the services of the first service line can be determined according to the received operation of selecting the first resource pool so as to run the services of the first service line on the physical machines.
In a second aspect of the embodiments of the present disclosure, there is provided a resource deployment apparatus including: the deployment module is configured to deploy a first resource pool for a first service line, wherein the first resource pool comprises a plurality of physical machines configured with first tags, and the physical machines configured with the first tags are deployed to run services of the first service line. And the monitoring module is configured to monitor the resource utilization rate of the first resource pool in the process of running the service of the first business line on the physical machine included in the first resource pool. And the migration module is configured to migrate the service running in the first physical machine to the second physical machine when the resource utilization rate of the first resource pool is smaller than a first threshold value. The first physical machine is a physical machine whose resource utilization rate in the first resource pool is smaller than a second threshold, the second physical machine is a physical machine capable of providing resources required to operate a service operated in the first physical machine, the second physical machine is a physical machine in the first resource pool, and the second physical machine is different from the first physical machine.
Optionally, the physical machine not deployed outside the first resource pool is configured with a second tag, and the apparatus further includes a modification module. The modification module is configured to modify the first tag of the first physical machine to the second tag after the migration of the service running in the first physical machine to the second physical machine.
Optionally, the modifying module is configured to modify the first tag of the first physical machine to be a third tag when starting to migrate the service running in the first physical machine to a second physical machine, and the physical machine configured with the third tag is a physical machine that does not run any service. The modification module is configured to modify the third tag of the first physical machine to the second tag after completing migration of the service running in the first physical machine to a second physical machine.
Optionally, the migration module is configured to migrate the service running in the first physical machine to the second physical machine when the service running in the first physical machine is allowed to be migrated.
Optionally, the deployment module is configured to receive a resource requirement of the first service line. The deployment module is configured to configure the first tag for each of a plurality of physical machines according to the resource requirement. The resource provided by the plurality of physical machines meets the resource requirement, and the plurality of physical machines configured as the first tag form the first resource pool.
Optionally, the deployment module is configured to bind the first resource pool with a service tree node where the first service line is located, and is configured to select, by a user, the first resource pool corresponding to the first service line when the service of the first service line needs to be operated.
Optionally, the resource deployment device further includes: a receiving module and an operating module. The receiving module is configured to receive the service of the first service line and an instruction of selecting the first resource pool by a user. The execution module is configured to execute the service of the first service line on a physical machine included in the first resource pool in response to the instruction.
In a third aspect of embodiments of the present disclosure, there is provided a server comprising: a processor. A memory for storing processor-executable instructions. Wherein the processor is configured to: a first resource pool is deployed for a first service line, wherein the first resource pool comprises a plurality of physical machines configured with first tags, and the physical machines configured with the first tags are deployed to run services of the first service line. And monitoring the resource utilization rate of the first resource pool in the process of running the service of the first service line on the physical machine included in the first resource pool. And when the resource utilization rate of the first resource pool is smaller than a first threshold value, migrating the service running in the first physical machine to the second physical machine. The first physical machine is a physical machine whose resource utilization rate in the first resource pool is smaller than a second threshold, the second physical machine is a physical machine capable of providing resources required to operate a service operated in the first physical machine, the second physical machine is a physical machine in the first resource pool, and the second physical machine is different from the first physical machine.
A fourth aspect of the disclosed embodiments provides a computer readable storage medium having instructions stored thereon, wherein the instructions when executed by a processor implement: a first resource pool is deployed for a first service line, wherein the first resource pool comprises a plurality of physical machines configured with first tags, and the physical machines configured with the first tags are deployed to run services of the first service line. And monitoring the resource utilization rate of the first resource pool in the process of running the service of the first service line on the physical machine included in the first resource pool. And when the resource utilization rate of the first resource pool is smaller than a first threshold value, migrating the service running in the first physical machine to the second physical machine. The first physical machine is a physical machine whose resource utilization rate in the first resource pool is smaller than a second threshold, the second physical machine is a physical machine capable of providing resources required to operate a service operated in the first physical machine, the second physical machine is a physical machine in the first resource pool, and the second physical machine is different from the first physical machine.
It will be appreciated that the resource deployment apparatus of the second aspect, the server of the third aspect and the computer readable storage medium of the fourth aspect provided above are all configured to perform the corresponding methods provided above, and therefore, the advantages achieved by the apparatus may refer to the advantages in the corresponding methods provided above, and are not described herein.
Drawings
The accompanying drawings, which are incorporated in and constitute a part of this specification, illustrate embodiments consistent with the disclosure and together with the description, serve to explain the principles of the disclosure and do not constitute an undue limitation on the disclosure.
FIG. 1 is a schematic diagram of a method for setting up different clusters of physical machines for different service lines;
FIG. 2 is a schematic diagram illustrating resource utilization in a different physical machine cluster;
FIG. 3 is a schematic diagram of an implementation environment provided by an embodiment of the present disclosure;
fig. 4 is a schematic diagram of a server according to an embodiment of the disclosure;
FIG. 5 is a schematic logic diagram of a resource deployment method according to an embodiment of the present disclosure;
fig. 6 is a schematic diagram illustrating an implementation of a deployment procedure in a resource deployment method according to an embodiment of the present disclosure;
fig. 7 is a schematic diagram of resource deployment for a plurality of service lines according to an embodiment of the present disclosure;
FIG. 8 is a schematic diagram of binding a resource pool with a service tree node according to an embodiment of the present disclosure;
fig. 9 is a schematic diagram illustrating execution of a management procedure in a resource deployment method according to an embodiment of the present disclosure;
fig. 10 is a schematic diagram of a resource deployment device according to an embodiment of the disclosure;
FIG. 11 is a schematic diagram of a further resource deployment device according to an embodiment of the present disclosure;
FIG. 12 is a schematic diagram of a further resource deployment device provided in an embodiment of the present disclosure;
fig. 13 is a schematic diagram of a server according to an embodiment of the disclosure.
Detailed Description
When the resource sharing is needed, different physical machine clusters can be built aiming at different service lines in consideration of the resource isolation, so that the isolation of the resources corresponding to the different service lines is realized while the resource requirements required by the service operation of the different service lines are met. In the disclosed embodiments, isolating the resources may also be referred to as containerizing the resources. The party for building and maintaining the cluster may be called a deployment party, and the party for proposing the service line resource requirement may be called a service party.
Illustratively, after receiving the resource requirement of the service line proposed by the service party, the deployment party can implement the containerization of the resource through Kubernetes (K8 s), wherein the physical machine cluster built through K8s can also be called as a K8s cluster. After the K8s cluster is built, the deployment party can also use K8s to maintain the cluster.
However, since the demand of the service line for the resources is not constant, a problem of low resource utilization may occur. Illustratively, the K8s cluster built for the service line 1 according to the resource requirement of the service line 1 is illustrated as including 4 physical machines. When the service line 1 runs, if the resource required by the service line 1 is not changed, as shown in (a) in fig. 2, all 4 physical machines in the K8s cluster can be in a working state (or called an occupied state), and at this time, the resource utilization rate of the K8s cluster is higher. However, if the resources required during the operation of the service line 1 are reduced, for example, only 2 physical machines are required for operating the service line 1, as shown in (b) of fig. 2, only 2 physical machines may be in an operating state in 4 physical machines in the K8s cluster, so that the resource utilization of the K8s cluster is reduced. Thereby causing resource waste in the K8s cluster. If the 2 physical machines in the idle state are to be stripped from the K8s cluster, a very complicated operation is required, for example, the K8s cluster is built again for the service line 1, which may not only affect the normal operation of the service line 1, but also pay a large cost investment of manpower and material resources.
In order to solve the above-mentioned problems, an embodiment of the present disclosure provides a resource deployment method, which configures tags for physical machines deployed for service lines to form resource pools with different tags for different service lines. The isolation granularity of the resources is reduced from the cluster to the physical machine, so that when the physical machine needs to be released from the deployed resource pool, the resource can be stably and conveniently redistributed, the waste of the resources is reduced, and the utilization rate of the resources is improved.
In order to enable those skilled in the art to better understand the technical solutions of the present disclosure, the technical solutions of the embodiments of the present disclosure will be clearly and completely described below with reference to the accompanying drawings.
It should be noted that the terms "first," "second," and the like in the description and claims of the present disclosure and in the foregoing figures are used for distinguishing between similar objects and not necessarily for describing a particular sequential or chronological order. It is to be understood that the data so used may be interchanged where appropriate such that the embodiments of the disclosure described herein may be capable of operation in sequences other than those illustrated or described herein. The implementations described in the following exemplary examples are not representative of all implementations consistent with the present disclosure. Rather, they are merely examples of apparatus and methods consistent with some aspects of the present disclosure as detailed in the accompanying claims.
Referring to fig. 3, a schematic diagram of an implementation environment provided by an embodiment of the disclosure, the above resource deployment method may be applied in the implementation environment.
As shown in fig. 3, in this implementation environment, a service side device 210, a deployment side device 220, and a server 230 including M physical machines may be included, where M is an integer greater than 1. The business side device 210, the deployment side device 220, and the server 230 may each be connected via a wired or wireless network such that the business side device 210, the deployment side device 220, and the server 230 communicate via the wired or wireless network.
The server 230 including M physical machines is mainly used for providing resources such as a processor and a memory. The business side may apply for deployment resources to the deployment side device 220 through the business side device 210 for operation of the business line service. Correspondingly, the deployment party can process the application for the resource through the deployment party device 220, such as deploying the corresponding resource.
Illustratively, the business side device 210 may receive an operation of a business side applying for a resource required to run one or more business lines and send the resource requirement to the deployment side device 220. The service side device 210 may also provide a control platform (e.g., a devots platform) to the service side to receive an operation input by the service side to run the service line on the deployed resource, and interact with the server 230 in response to the operation, to implement the operation of the service line on the deployed resource. The business side device 210 may be a mobile phone, a tablet computer, a notebook computer, a desktop computer, a portable computer, etc., and embodiments of the present disclosure are not limited herein.
The deployment device 220 may be configured to receive a resource requirement for running one or more service lines sent by the service device 210, where the deployment device 220 may further deploy, under control of the deployment device, a corresponding resource for a service line corresponding to the resource requirement through the server 230 according to the received resource requirement. Similar to the business side device 210, the deployment side device 220 may be a cell phone, tablet, notebook, desktop, portable, etc., embodiments of the present disclosure are not limited herein.
As shown in fig. 4, the server 230 may include a resource physical machine 231 and a management physical machine 232. The resource physical machine 231 may be N physical machines for providing resources from M physical machines, and the management physical machine 232 may be P physical machines for managing resources from M physical machines. N and P are both positive integers less than M. The resource physical machine 231 and the management physical machine 232 may also be connected through a wired or wireless network so that the management physical machine 232 manages the resource physical machine 231. In some embodiments, the management physical machine 232 may have a K8s system running therein to manage the resources provided by the resource physical machine 231 under the control of the deployer device 220. It should be noted that, in the embodiment of the present disclosure, the management physical machine 232 may also provide the remaining resources in the physical machine to the service line, in addition to the resources for management, so as to realize the optimal utilization of the physical machine resources.
For example, when the deployment side device 220 deploys resources for a service line under the control of the deployment side, the received resource requirements may be sent to the management physical machine 232, so that one or more physical machines capable of meeting the resource requirements are selected from the resource physical machines 231 through the K8s system running on the management physical machine 232, and the labels of the physical machines are configured so that the physical machines with the same label can form a resource pool corresponding to the service line. In this way, the deployment device 220 may provide the resource pool to the service device 210, so that when the service is to run the service, the service device 210 may input a related operation on the service device 210, and in response to the operation, the service device 210 may control the service corresponding to the service to run in the physical machine included in the resource pool.
In the embodiment of the present disclosure, after the deployment of the resource pool is completed, the management physical machine 232 may also provide a function of managing the deployed resource, and a specific implementation method of the management function will be described in the following embodiment, which is not repeated here.
It should be noted that the K8s system running in the management physical machine 232 may also run in the deployment side device 220. When the K8s system is running in the deployment side device 220, M physical machines in the server 230 may all be used as resource physical machines.
In order to more clearly describe the resource deployment method provided by the embodiment of the present disclosure, the following description will take an example in which a K8s system for deploying and managing resources is operated in a management physical machine of a server.
Referring to fig. 5, a schematic diagram of a resource deployment method provided by an embodiment of the present disclosure is shown. As shown in fig. 5, the method may include S501-S503.
S501, the server deploys a first resource pool for a first service line.
The first resource pool comprises a plurality of physical machines configured with first labels, and the first labels are used for indicating that the physical machines are deployed as services for running a first business line.
When the service side needs resources to support the operation of the service line (such as the first service line), a corresponding operation (such as a first operation) may be input to the service side device, and in response to the first operation, the service side device may send a resource case required for operating the first service line (i.e., a resource requirement of the first service line) to the deployment side device. After receiving the resource requirement of the first service line, the deployment device may send the resource requirement to the server. The management physical machine in the server can deploy a plurality of physical machines for the service line according to the requirement of the service side through the K8s system under the control of the deployment side, and configures labels corresponding to the first service line, such as a first label, for the physical machines. The management physical machine may provide the first resource pool formed by the physical machine with the first label to the business party. So that the service party inputs a corresponding operation (such as a second operation) to the service party device when running the first service line, and in response to the second operation, the service party device can select the first resource pool and send related information (such as the operation of selecting the first resource pool and the information of the service code of the first service line to be run, etc.) to the management physical machine, so that the management physical machine runs the service on the physical machine configured with the first tag and included in the first resource pool according to the information.
It should be noted that, in the embodiment of the present disclosure, one resource pool corresponds to one service line, and the resources of the resource pool are a set of resources provided by physical machines having the same label. The resources in the resource pool may belong to the same physical machine cluster, or may belong to a plurality of physical machine clusters. Meanwhile, one physical machine cluster can comprise one resource pool or a plurality of resource pools. The embodiments of the present disclosure are not limited herein.
S502, monitoring the resource utilization rate of the first resource pool by the server in the process of running the service of the first service line on the physical machine included in the first resource pool.
The operation of the service line may include operation of one or more services. For example, the operation of the first service line includes operating one or more services included in the first service line.
In the embodiment of the disclosure, in a process of running a service of a first service line on a physical machine included in a first resource pool, a management physical machine of a server may monitor a resource utilization rate of the first resource pool, so that when the resource utilization rate of the first resource pool is low, appropriate measures are taken to reduce waste of resources. When the resource utilization rate of the first resource pool is low, the first resource pool may be referred to as a capacity reduction target.
It should be noted that, the monitoring of the resource utilization rate of the first resource pool may be real-time monitoring started when the first service line starts to run, or monitoring started in a preset time period, which is not limited in the embodiments of the present disclosure.
S503, when the resource utilization rate of the first resource pool is smaller than a first threshold value, the server migrates the service running in the first physical machine to the second physical machine.
The first physical machine is a physical machine with the resource utilization rate in the first resource pool smaller than a second threshold value, and the second physical machine is a physical machine capable of providing resources required for running services running in the first physical machine. Meanwhile, the second physical machine is a physical machine different from the first physical machine in the first resource pool.
When the resource utilization rate of the first resource pool is smaller than the first threshold value, the server can determine that the resources in the first resource pool are wasted greatly at the current moment, and proper measures need to be taken for the resources. In the implementation of the present disclosure, the server may release a part of the physical machines with low utilization rate in the first resource pool from the first resource pool, so as to improve the utilization rate of the first resource pool.
For example, the management physical machine of the server may select, under the control of the deployment party, a physical machine with a resource utilization rate smaller than the second threshold value as a physical machine (such as a first physical machine) to be released, and if a service (such as a first service) running in the first physical machine exists in the first physical machine, migrate the first service from the first physical machine to other physical machines (such as second physical machines) in the first resource pool to run. The second physical machine may be any physical machine in the first resource pool that is capable of providing resources required for running the first service.
The migration of the service may be implemented by restarting the service on the second physical machine and stopping the service from running on the first physical machine. It should be noted that, the process of restarting the service and stopping the service may be performed simultaneously or in a time-sharing manner, which is not limited in the embodiments of the present disclosure.
In some implementations of the embodiments of the present disclosure, the first physical machine may be further processed correspondingly, so that the resources of the first physical machine can be reused, for example, configured into a resource pool of other services.
For example, the server may modify a first label of the first physical machine to a second label that indicates that the first physical machine is not deployed. After ensuring that there is no service running on the first physical machine, the management physical machine may modify the first label of the first physical machine to a second label under the control of the deployment party. According to the description in S501, the physical machine with the first label may be used to run the service of the first service line, and after the first label of the first physical machine is modified to the second label, it indicates that the first physical machine is no longer included in the first resource pool, but is in an undeployed state. So that the first physical machine can be redeployed into other resource pools when there are other traffic lines for which resources need to be deployed.
Based on the above-mentioned resource deployment method of S501-S503, when the number of resources required by the service line is reduced, a part of physical machines with labels corresponding to the resource pool are modified to other labels, so that the physical machines can be released. The number of physical machines in the resource pool is compressed while service operation of the service line is not affected, so that waste of resources is reduced.
In the embodiment of the disclosure, the resource deployment method can be further divided into a deployment process and a management process.
Referring to fig. 6, a flowchart of one method of a deployment procedure in a resource deployment method provided by an embodiment of the present disclosure is shown. As shown in fig. 6, the method may include S601-S603. The service line to be operated by the service party is taken as a first service line for illustration.
S601, a server receives the resource requirement of the first service line.
The resource requirement of the first service line may be that the service side device sends to the deployment side device, and then the deployment side device sends to the management physical machine of the server. By way of example, the resource requirements may include hardware requirements required to run the first line of business, e.g., the resource requirements may include a processors and B Megabytes (MB) of memory.
S602, the server configures a first label for each physical machine in the plurality of physical machines according to the resource requirement.
The resources provided by the plurality of physical machines can meet the resource requirement of the first service line, and the plurality of physical machines configured as the first tag can be configured into a first resource pool corresponding to the first service line.
According to the received resource demand, the management physical machine of the server may select the plurality of physical machines from the undeployed physical machines under the control of the deployment party, and configure tags (e.g., first tags) for the physical machines. The resource provided by the physical machine including the first tag may form a first resource pool corresponding to the first service line.
Illustratively, taking the example of a D MB memory, each physical machine can provide C processors. When the resource requirement of the first service line is A processors and B MB memory, by comparisonAnd +.>The larger value of the two is taken, and the number of the physical machines to be selected can be determined, that is, the resources provided by the physical machines can meet the resource requirement of running the first service line.
After determining the number of physical machines capable of providing the resource required by the service line, the management physical machine can select a corresponding number of physical machines from undeployed physical machines as the physical machines for running the service line. The administrative physical machine may also configure tags for the physical machines to identify that the physical machines have been deployed to provide resources to corresponding traffic lines.
Illustratively, taking the example that the first service line requires E physical machines to provide resources. The deployment party can select E physical machines from undeployed physical machines and respectively configure first labels for the E physical machines. The first tag may be an electronic tag configured for the E physical machines by the K8s system under control of the deployment party by the management physical machine. Thus, the resources provided by the E physical machines configured with the first tag constitute a first resource pool providing resources for the operation of the first service line.
Similarly, when a plurality of different service lines of one or more service parties need to run, the deployment party may execute S601-S602 described above for each of the plurality of different service lines, so as to implement the purpose of deploying resources for different service lines respectively to support the running of the service lines.
Referring to fig. 7, a schematic diagram of deploying resources for a plurality of service lines is shown.
As shown in fig. 7, 1K 8s cluster is built in the server through the K8s system, and includes physical machine a, physical machine B, physical machine C, physical machine D, physical machine E, and physical machine F that can provide resources, and other physical machines (not shown in fig. 7), and a plurality of different service lines including 3 service lines, such as service line 1, service line 2, and service line 3 are illustrated as an example.
In order to facilitate management of multiple physical machines, the server may build all physical machines included in the server into one K8s cluster through a K8s system running therein under the control of a deployment party.
After receiving the resource requirements of service line 1, service line 2 and service line 3, the server can deploy 2 physical machines for service line 1 requiring the resources of 2 physical machines through the K8s system. Such as allocating physical machine B and physical machine C for service line 1 and configuring tag 1 for physical machine B and physical machine C. The resource pool formed by the resources provided by the physical machine B and the physical machine C with the tag 1 may be the resource pool 1 deployed for the service line 1.
Similarly, the server may deploy 1 physical machine for the service line 2 that requires the resources of 1 physical machine through the K8s system. Such as assigning a physical machine D to the service line 2 and configuring a tag 2 for the physical machine D. The resource pool formed by the resources provided by the physical machine D with the tag 2 may be the resource pool 2 deployed for the service line 2.
The server may deploy 2 physical machines for the service line 3, which requires resources of 2 physical machines, through the K8s system. E.g. for the service line 3 part, the physical machine E and the physical machine F, and for the physical machine E and the physical machine F, the tag 3 is configured. The resource pool formed by the resources provided by the physical machines E and F with the labels 3 may be the resource pool 3 deployed for the service line 3.
In the embodiment of the disclosure, the server may also deploy a physical machine for a service of a service line that does not need resource isolation through the K8s system. Such as physical machine a in fig. 7, for services that do not require resource isolation, in order to provide the resources of physical machine a to these services that do not require resource isolation. Thus, the additional deployment investment caused by the resource isolation is reduced, and the resources of the physical machine running the service of the business line without the resource isolation are utilized to the maximum extent.
And S603, binding the first resource pool with the service tree node where the first service line is located by the server, and selecting the first resource pool corresponding to the first service line by a user when the service of the first service line needs to be operated.
After the deployment of the first resource pool corresponding to the first service line is completed, the service side device can run the service of the first service line on the first resource pool under the control of the user (i.e. the service side). Since the server may include a plurality of different resource pools deployed for different service lines at the same time, in order to avoid that the server erroneously schedules the service of the first service line to another resource pool other than the first resource pool when running the service of the first service line, in the embodiment of the present disclosure, after completing the deployment of the resource, the server may bind the first resource pool with the service tree node where the first service line is located, so that when the service party wants to run the service of the first service line, the service party may input an operation (such as a third operation) of selecting the first resource pool to the service party device, and in response to the third operation, the service party device may send the operation of selecting the first resource pool to the server, so that the server may schedule the service of the first service line to a physical machine included in the first resource pool for running.
Exemplary, as illustrated in fig. 8, a schematic diagram of binding a resource pool to a service tree node is provided. As shown in fig. 8, the management physical machine of the server deploys a resource pool a for a service line a, deploys a resource pool B for a service line B, deploys a resource pool A1 for a sub-service line A1 of the service line a, deploys a resource pool A2 for a sub-service line A2 of the service line a, and deploys a resource pool B1 for a sub-service line B1 of the service line B. When the resource is deployed, the management physical machine can bind the resource pool a to the service tree node where the service line a is located, bind the resource pool B to the service tree node where the service line B is located, bind the resource pool A1 to the service tree node where the service line A1 is located, bind the resource pool A2 to the service tree node where the service line A2 is located, and bind the resource pool B1 to the service tree node where the service line B1 is located.
In this way, in an operation platform (such as a devots platform) provided by the service side device for controlling the service line to run, only the resource pool a bound with the service tree node where the service line a is located is displayed on the service tree node corresponding to the service line a for selection. Similarly, on the service tree node corresponding to the service line B, only the resource pool B bound to the service tree node where the service line B is located is displayed for selection. On the service tree node corresponding to the service line A1, only the resource pool A1 bound to the service tree node where the service line B is located is displayed for selection. On the service tree node corresponding to the service line A2, only the resource pool A2 bound to the service tree node where the service line B is located is displayed for selection. On the service tree node corresponding to the service line B1, only the resource pool B2 bound to the service tree node where the service line B is located is displayed for selection.
Through the method of S601-S603, the server completes the deployment of the corresponding resource pool for the service line according to the resource requirement of the service line proposed by the service party. After the deployment is completed, the deployment party may provide the service party with the resource pool name corresponding to the service line through the server or the deployment party device, so that when the service party wants to run the service corresponding to the service line on the physical machine included in the deployed resource pool, the method may be performed as shown in the following S604-S605.
S604, receiving the service of the first service line and an instruction of selecting a first resource pool by a user.
Illustratively, after the deployment of the first resource pool is completed, the resource pool may be bound to the service tree node where the service line is located. When a user (such as a business party) wants to run the service of the first business line, the management physical machine of the K8s cluster can receive an instruction of selecting the first resource pool, which is input by the business party through an operation platform (such as a devops platform) provided by business party equipment. The service instruction input by the service party through the devots platform can also be received, for example, the service instruction can be a computer code for realizing the corresponding function of the service.
S605, in response to the instruction, running the service of the first service line on the physical machine included in the first resource pool.
After receiving the instruction sent by the service side equipment, the management physical machine of the K8s cluster can run the corresponding service on the corresponding physical machine.
When receiving an instruction that a service party selects a first resource pool through a devots platform, the management physical machine of the K8s cluster can determine a first label according to the name of the first resource pool, and screen out the physical machines with the first label from the physical machines of the K8s cluster by taking the first label as a screening condition, so that the physical machines in the first resource pool are determined. According to the received service instruction sent by the service party, the management physical machine can send the computer code included in the service instruction to the physical machine in the first resource pool so as to run the code on the physical machine in the first resource pool, thereby realizing the function of the service corresponding to the code.
Referring to fig. 9, a method for implementing a management procedure in a resource deployment method according to an embodiment of the present disclosure is shown. As shown in fig. 9, the method may include S901-S905.
And S901, monitoring the resource utilization rate of the first resource pool by the server in the process of running the service of the first service line on the physical machine included in the first resource pool.
The method is similar to S502 shown in fig. 5, and will not be described here.
S902, after determining that the first resource pool is a capacity reduction target, the server determines that services running in the first physical machine are allowed to be migrated.
The first physical machine may be a physical machine with a smaller resource utilization rate in the first resource pool. The first physical machine may also be referred to as a release target.
In general, a plurality of physical machines may be included in the first resource pool in order to provide sufficient resources to run the services of the first traffic line. When the overall resource utilization rate of the first resource pool is low, it can be determined that services running in the first physical machine are allowed to be migrated according to preset conditions, so that the services can be migrated from the first physical machine.
For example, according to the preset condition, it is determined that the service running in the first physical machine is allowed to be migrated, which may specifically include the following implementation manners:
when the priority of the service operated by the first physical machine is low, it may be determined that the service is allowed to be migrated. For example, services included in a service line may be classified into a high priority service, a medium priority service, and a low priority service according to functions corresponding to the services. When the service running in the first physical machine is a low priority service, it means that the operation of migrating the service to other physical machines (such as the second physical machine) does not have a great influence on the running of the service line. Therefore, when the priority of the service operated in the first physical machine is low, it can be determined that the service operated in the first physical machine can be migrated.
When the service operated by the first physical machine is a stateless service, it may be determined that the service is allowed to be migrated. For example, during the operation of a service in a physical machine, it may be necessary to rely on other services in the physical machine to operate properly, which may be referred to as a stateful service. There are also services that can run independently without relying on other services, which may be referred to as stateless services. In the embodiment of the disclosure, if the service running in the first physical machine is a stateless service, the service is indicated to run in other physical machines smoothly. That is, migrating the service does not have an impact on the operation of the service. Thus, when a service run by the first physical machine is a stateless service, it may be determined that the service is allowed to be migrated.
When the number of service instances of the service operated by the first physical machine is large, it may be determined that the service is allowed to be migrated. By way of example, the corresponding functionality of a service may be implemented by one or more service instances. In general, in order to avoid the loss of functions corresponding to a service caused by an abnormality of a certain service instance, multiple service instances corresponding to the service may be initiated in different physical machines when the service is run. In the embodiment of the disclosure, when the service running in the first physical machine has a plurality of service instances, it is indicated that the migration of the service can be implemented only by restarting one service instance on another physical machine (such as the second physical machine). That is, stopping the service from running on the first physical machine does not affect the functionality of the service provision. Therefore, when the number of service instances of the service operated by the first physical machine is large, it can be determined that the service is allowed to be migrated.
It should be noted that, in the specific implementation process, it may be determined that the service of the first physical machine may be migrated according to any one of the methods in the foregoing several exemplary descriptions, or may be determined that the service of the first physical machine may be migrated in combination with two or more methods in the foregoing several exemplary descriptions. The embodiments of the present disclosure are not limited herein.
S903, the server modifies the first label of the first physical machine into a third label, wherein the third label is used for indicating that the first physical machine cannot be deployed.
Since new services may be scheduled to run on the first physical machine at any time during the service line running process. Thus, after determining that a service of a first physical machine may be migrated, to avoid having a new service running on the first physical machine, the first tag of the first physical machine may be modified to a third tag indicating that it cannot be deployed.
S904, the server migrates the service running in the first physical machine to the second physical machine.
As illustrated in S503, migration of a service may be accomplished by restarting the service on a second physical machine and stopping the service from running on a first physical machine. The process of restarting the service and stopping the service may be performed simultaneously or in a time-sharing manner, which is not limited in this embodiment of the disclosure.
S905, the server modifies the third label of the first physical machine into a second label.
After the steps S901-S905, there is no service running in the first physical machine, at this time, the server may modify the third tag of the first physical machine to the second tag, to indicate that the first physical machine is not deployed. So that the first physical machine can be redeployed into other resource pools when there are other traffic lines for which resources need to be deployed.
It should be noted that, the resource deployment method provided in S901-S905 is described by taking releasing one physical machine (such as the first physical machine) in the first resource pool as an example. When the resource utilization rate of the first resource pool is still low after the first physical machine is released, the above steps S901-S905 may be repeatedly performed, so as to further reduce the waste of resources.
Based on the resource deployment method, according to the resource requirement of the first service line, a plurality of physical machines configured with the first label are deployed for the first service line, and when the first service is operated on the physical machines, the total amount of resources of the first resource pool is reduced by migrating the service and modifying the label, and the released resources of the first physical machines can be deployed to other service lines to be utilized, so that the utilization rate of the resources is improved.
Further, when the resources are deployed for the first service line, the resources of different service lines are isolated by a method of configuring labels for the physical machine, so that a cluster is not required to be built for each service line independently, and a large amount of manpower and material resource investment is saved. In addition, a resource pool formed by the resources of the physical machines with the same label is provided for the business party, and the name of the resource pool can be set according to the business line, so that the business party can clearly know the name of the resources deployed for the business line without knowing concepts such as labels in the bottom layer, and the user experience is remarkably improved.
The foregoing description has mainly described the solutions provided by the embodiments of the present disclosure from the perspective of managing physical machines. It will be appreciated that, in order to implement the above-mentioned functions, the management physical machine includes hardware structures and/or software modules that perform respective functions, and these hardware structures and/or software modules that perform respective functions may constitute one management physical machine. Those of skill in the art will readily appreciate that the algorithm steps of the examples described in connection with the embodiments disclosed herein may be implemented as hardware or a combination of hardware and computer software. Whether a function is implemented as hardware or computer software driven hardware depends upon the particular application and design constraints imposed on the solution. Skilled artisans may implement the described functionality in varying ways for each particular application, but such implementation decisions should not be interpreted as causing a departure from the scope of the present disclosure.
The embodiment of the disclosure may divide the functional modules of the management physical machine according to the above method example, for example, the management physical machine may include a resource deployment device, where the resource deployment device may divide each functional module corresponding to each function, or may integrate two or more functions into one processing module. The integrated modules may be implemented in hardware or in software functional modules. It should be noted that, in the embodiment of the present disclosure, the division of the modules is merely a logic function division, and other division manners may be implemented in actual practice.
In the case of dividing the respective functional modules with the respective functions, fig. 10 shows a schematic diagram of one possible composition of the resource deployment apparatus involved in the above-described embodiment, as shown in fig. 10, the resource deployment apparatus may include:
the deployment module 1001 is configured to deploy a first resource pool for a first service line, where the first resource pool includes a plurality of physical machines configured with a first tag, and the physical machines configured with the first tag are deployed to run services of the first service line.
The monitoring module 1002 is configured to monitor a resource utilization of the first resource pool during a process of running a service of the first service line on a physical machine included in the first resource pool.
The migration module 1003 is configured to migrate a service running in the first physical machine onto the second physical machine when the resource utilization of the first resource pool is less than a first threshold. The first physical machine is a physical machine with the resource utilization rate in the first resource pool smaller than a second threshold value, and the second physical machine is a physical machine capable of providing resources required for running services running in the first physical machine. The second physical machine is a physical machine in the first resource pool that is different from the first physical machine.
Optionally, referring to fig. 11, the apparatus further includes: the modification module 1004 is configured to modify a first tag of the first physical machine to a second tag after migrating a service running in the first physical machine to the second physical machine. It should be noted that, in the embodiment of the present disclosure, the physical machines that are not deployed outside the first resource pool are configured with the second label.
Optionally, the modifying module 1004 is configured to modify the first tag of the first physical machine into a third tag before migrating the service running in the first physical machine to the second physical machine, and the physical machine configured with the third tag is a physical machine that does not run any service.
The modifying module 1004 is configured to modify a third tag of the first physical machine to a second tag after migrating the service running in the first physical machine to the second physical machine.
Optionally, the migration module 1003 is configured to migrate the service running in the first physical machine to the second physical machine when the service running in the first physical machine is allowed to be migrated.
Optionally, the deployment module 1001 is configured to receive a resource requirement of the first service line.
The deployment module 1001 is configured to configure a first tag for each of a plurality of physical machines according to a resource requirement. The resource provided by the plurality of physical machines meets the resource requirement, and the plurality of physical machines configured as the first label form a first resource pool.
Optionally, the deployment module 1001 is configured to bind the first resource pool with a service tree node where the first service line is located, and is configured to select, when a service of the first service line needs to be run, the first resource pool corresponding to the first service line by a user.
Optionally, as shown in fig. 12, the resource deployment apparatus further includes: a receiving module 1005 and a running module 1006.
A receiving module 1005 configured to receive a service of a first service line and an instruction from a user to select a first resource pool.
An operation module 1006 is configured to operate the services of the first service line on the physical machines included in the first resource pool in response to the instruction.
The specific manner in which the various modules perform the operations in the apparatus of the above embodiments have been described in detail in connection with the embodiments of the method, and will not be described in detail herein.
Fig. 13 is a schematic structural diagram of a server 1300 according to an embodiment of the present invention, where the server 1300 may have a relatively large difference due to different configurations or performances, and may include one or more processors (central processing units, CPU) 1301 and one or more memories 1302, where at least one instruction is stored in the memories 1302, and the at least one instruction is loaded and executed by the processors 1301 to implement the resource deployment method provided in the foregoing method embodiments. The server 1300 may be, for example, the administrative physical machine 232 of fig. 4.
Of course, the server 1300 may also have a wired or wireless network interface, a keyboard, an input/output interface, etc. for performing input/output, and the server 1300 may also include other components for implementing the functions of the device, which are not described herein.
The disclosed embodiments also provide a computer-readable storage medium having instructions stored thereon that, when executed by a processor of a computer device, enable the computer to perform the resource deployment method provided by the above-described illustrated embodiments.
The disclosed embodiments also provide a computer program product containing instructions that, when run on a computer, cause the computer device to perform the resource deployment method provided by the above-described illustrated embodiments.
Other embodiments of the present application will be apparent to those skilled in the art from consideration of the specification and practice of the invention disclosed herein. This application is intended to cover any variations, uses, or adaptations of the application following, in general, the principles of the application and including such departures from the present disclosure as come within known or customary practice within the art to which the application pertains. It is intended that the specification and examples be considered as exemplary only, with a true scope and spirit of the application being indicated by the following claims. It is to be understood that the present application is not limited to the precise arrangements and instrumentalities shown in the drawings, which have been described above, and that various modifications and changes may be effected without departing from the scope thereof. The scope of the application is limited only by the appended claims.
Claims (14)
1. A method of resource deployment, the method comprising:
deploying a first resource pool for a first service line, wherein the first resource pool comprises a plurality of physical machines configured with first tags, and the physical machines configured with the first tags are deployed to run services of the first service line; the undeployed physical machines outside the first resource pool are configured with second labels, wherein one resource pool corresponds to one service line, and the resources of the same resource pool are a set of resources provided by the physical machines with the same labels;
Monitoring the resource utilization rate of the first resource pool in the process of running the service of the first service line on a physical machine included in the first resource pool; when the resource utilization rate of the first resource pool is smaller than a first threshold value, migrating the service running in the first physical machine to a second physical machine; the first physical machine is a physical machine with the resource utilization rate in the first resource pool smaller than a second threshold value;
the second physical machine is a physical machine capable of providing resources required for running a service running in the first physical machine, the second physical machine is a physical machine in the first resource pool, and the second physical machine is different from the first physical machine;
modifying the first tag of the first physical machine to a second tag.
2. The method of claim 1, wherein the modifying the first tag of the first physical machine to a second tag comprises:
when starting to migrate the service running in the first physical machine to a second physical machine, modifying the first label of the first physical machine into a third label, wherein the physical machine configured with the third label is a physical machine which does not run any service; and after the service running in the first physical machine is migrated to a second physical machine, modifying the third tag of the first physical machine into the second tag.
3. The method of any of claims 1-2, wherein migrating services running in a first physical machine to a second physical machine comprises: and when the service running in the first physical machine is allowed to be migrated, migrating the service running in the first physical machine to the second physical machine.
4. The method according to any of claims 1-2, wherein said deploying a first resource pool for a first traffic line comprises:
receiving the resource requirement of the first service line; configuring the first label for each physical machine in a plurality of physical machines according to the resource demand; the resource provided by the plurality of physical machines meets the resource requirement, and the plurality of physical machines configured as the first tag form the first resource pool.
5. The method of claim 4, wherein after said deploying the first pool of resources for the first line of traffic, the method further comprises: binding the first resource pool with a service tree node where the first service line is located, and selecting the first resource pool corresponding to the first service line by a user when the service of the first service line needs to be operated.
6. The method of claim 5, wherein the method further comprises: receiving the service of the first service line and an instruction of selecting the first resource pool by a user; and responding to the instruction, and running the service of the first service line on a physical machine included in the first resource pool.
7. A resource deployment apparatus, the resource deployment apparatus comprising:
the deployment module is configured to deploy a first resource pool for a first service line, wherein the first resource pool comprises a plurality of physical machines configured with first tags, and the physical machines configured with the first tags are deployed to run services of the first service line; the undeployed physical machines outside the first resource pool are configured with second labels, wherein one resource pool corresponds to one service line, and the resources of the same resource pool are a set of resources provided by the physical machines with the same labels;
the monitoring module is configured to monitor the resource utilization rate of the first resource pool in the process of running the service of the first business line on a physical machine included in the first resource pool;
a migration module configured to migrate a service running in a first physical machine onto a second physical machine when a resource utilization of the first resource pool is less than a first threshold; the first physical machine is a physical machine with a resource utilization rate smaller than a second threshold value in the first resource pool, the second physical machine is a physical machine capable of providing resources required for running services running in the first physical machine, the second physical machine is a physical machine in the first resource pool, and the second physical machine is different from the first physical machine;
And the modification module is configured to modify the first label of the first physical machine into the second label after the service running in the first physical machine is migrated to the second physical machine.
8. The apparatus of claim 7, wherein the device comprises a plurality of sensors,
the modification module is configured to modify the first label of the first physical machine into a third label when starting to migrate the service running in the first physical machine to a second physical machine, wherein the physical machine configured with the third label is a physical machine which does not run any service;
the modification module is configured to modify the third tag of the first physical machine to the second tag after migration of a service running in the first physical machine to a second physical machine is completed.
9. The device according to any one of claims 7 to 8, wherein,
the migration module is configured to migrate the service running in the first physical machine to the second physical machine when the service running in the first physical machine is allowed to be migrated.
10. The device according to any one of claims 7 to 8, wherein,
The deployment module is configured to configure the first tag for each physical machine of a plurality of physical machines according to resource requirements; the resource provided by the plurality of physical machines meets the resource requirement, and the plurality of physical machines configured as the first tag form the first resource pool; the undeployed physical machines outside the first resource pool are configured with second labels, wherein one resource pool corresponds to one service line, and the resources of the same resource pool are the set of the resources provided by the physical machines with the same labels.
11. The apparatus of claim 10, wherein the device comprises a plurality of sensors,
the deployment module is configured to bind the first resource pool with a service tree node where the first service line is located after the first resource pool is deployed for the first service line, and is used for selecting the first resource pool corresponding to the first service line by a user when the service of the first service line needs to be operated.
12. The apparatus of claim 11, further comprising a receiving module and an operating module;
the receiving module is configured to receive the service of the first service line and an instruction of selecting the first resource pool by a user;
The operation module is configured to respond to the instruction and operate the service of the first service line on the physical machine included in the first resource pool.
13. A server, the server comprising:
a processor;
a memory for storing processor-executable instructions;
wherein the processor is configured to: deploying a first resource pool for a first service line, wherein the first resource pool comprises a plurality of physical machines configured with first tags, and the physical machines configured with the first tags are deployed to run services of the first service line; the undeployed physical machines outside the first resource pool are configured with second labels, wherein one resource pool corresponds to one service line, and the resources of the same resource pool are a set of resources provided by the physical machines with the same labels;
monitoring the resource utilization rate of the first resource pool in the process of running the service of the first service line on a physical machine included in the first resource pool;
when the resource utilization rate of the first resource pool is smaller than a first threshold value, migrating the service running in the first physical machine to a second physical machine; the first physical machine is a physical machine with a resource utilization rate smaller than a second threshold value in the first resource pool, the second physical machine is a physical machine capable of providing resources required for running services running in the first physical machine, the second physical machine is a physical machine in the first resource pool, and the second physical machine is different from the first physical machine; modifying the first tag of the first physical machine to a second tag.
14. A computer-readable storage medium having instructions stored thereon, characterized in that,
the instructions, when executed by the processor, implement:
deploying a first resource pool for a first service line, wherein the first resource pool comprises a plurality of physical machines configured with first tags, and the physical machines configured with the first tags are deployed to run services of the first service line; the undeployed physical machines outside the first resource pool are configured with second labels, wherein one resource pool corresponds to one service line, and the resources of the same resource pool are a set of resources provided by the physical machines with the same labels;
monitoring the resource utilization rate of the first resource pool in the process of running the service of the first service line on a physical machine included in the first resource pool; when the resource utilization rate of the first resource pool is smaller than a first threshold value, migrating the service running in the first physical machine to a second physical machine; the first physical machine is a physical machine with a resource utilization rate smaller than a second threshold value in the first resource pool, the second physical machine is a physical machine capable of providing resources required for running services running in the first physical machine, the second physical machine is a physical machine in the first resource pool, and the second physical machine is different from the first physical machine; modifying the first tag of the first physical machine to a second tag.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202010060020.3A CN111274033B (en) | 2020-01-19 | 2020-01-19 | Resource deployment method, device, server and storage medium |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN202010060020.3A CN111274033B (en) | 2020-01-19 | 2020-01-19 | Resource deployment method, device, server and storage medium |
Publications (2)
Publication Number | Publication Date |
---|---|
CN111274033A CN111274033A (en) | 2020-06-12 |
CN111274033B true CN111274033B (en) | 2024-02-13 |
Family
ID=71002040
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN202010060020.3A Active CN111274033B (en) | 2020-01-19 | 2020-01-19 | Resource deployment method, device, server and storage medium |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN111274033B (en) |
Families Citing this family (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN111858037B (en) * | 2020-06-30 | 2023-07-14 | 苏州浪潮智能科技有限公司 | Service arrangement method, device and equipment of physical machine and storage medium |
CN111880914A (en) * | 2020-07-20 | 2020-11-03 | 北京百度网讯科技有限公司 | Resource scheduling method, resource scheduling apparatus, electronic device, and storage medium |
CN112799854B (en) * | 2021-04-15 | 2021-07-13 | 腾讯科技(深圳)有限公司 | Task processing method and device, electronic equipment and readable storage medium |
CN115378839B (en) * | 2022-08-26 | 2023-12-12 | 北京百度网讯科技有限公司 | Deployment method of acquisition task and related equipment |
CN115756823B (en) * | 2022-10-20 | 2024-04-16 | 广州汽车集团股份有限公司 | Service issuing method, device, vehicle and storage medium |
Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104484220A (en) * | 2014-11-28 | 2015-04-01 | 杭州华为数字技术有限公司 | Method and device for dispatching dynamic resources of virtual cluster |
CN109271257A (en) * | 2018-10-11 | 2019-01-25 | 郑州云海信息技术有限公司 | A kind of method and apparatus of virtual machine (vm) migration deployment |
CN109840139A (en) * | 2017-11-29 | 2019-06-04 | 北京金山云网络技术有限公司 | Method, apparatus, electronic equipment and the storage medium of resource management |
CN109992350A (en) * | 2017-12-29 | 2019-07-09 | 北京华胜天成科技股份有限公司 | The moving method and device of virtual machine in the resource pool of cloud computing system |
CN110633152A (en) * | 2019-09-20 | 2019-12-31 | 苏州浪潮智能科技有限公司 | Method and device for realizing horizontal scaling of service cluster |
Family Cites Families (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US10671379B2 (en) * | 2018-03-27 | 2020-06-02 | International Business Machines Corporation | Software globalization management |
US20190347313A1 (en) * | 2018-05-08 | 2019-11-14 | Noted Analytics, Inc. | Methods and systems for enriching text information for application data entry and viewing |
-
2020
- 2020-01-19 CN CN202010060020.3A patent/CN111274033B/en active Active
Patent Citations (5)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN104484220A (en) * | 2014-11-28 | 2015-04-01 | 杭州华为数字技术有限公司 | Method and device for dispatching dynamic resources of virtual cluster |
CN109840139A (en) * | 2017-11-29 | 2019-06-04 | 北京金山云网络技术有限公司 | Method, apparatus, electronic equipment and the storage medium of resource management |
CN109992350A (en) * | 2017-12-29 | 2019-07-09 | 北京华胜天成科技股份有限公司 | The moving method and device of virtual machine in the resource pool of cloud computing system |
CN109271257A (en) * | 2018-10-11 | 2019-01-25 | 郑州云海信息技术有限公司 | A kind of method and apparatus of virtual machine (vm) migration deployment |
CN110633152A (en) * | 2019-09-20 | 2019-12-31 | 苏州浪潮智能科技有限公司 | Method and device for realizing horizontal scaling of service cluster |
Also Published As
Publication number | Publication date |
---|---|
CN111274033A (en) | 2020-06-12 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN111274033B (en) | Resource deployment method, device, server and storage medium | |
CN108337109B (en) | Resource allocation method and device and resource allocation system | |
CN105207798B (en) | Service arrangement method and device in software defined network | |
CN115328663B (en) | Method, device, equipment and storage medium for scheduling resources based on PaaS platform | |
CN106575247B (en) | Fault-tolerant federation of computing clusters | |
CN108400945B (en) | Arranging management system and network slice processing method | |
CN112445575B (en) | Multi-cluster resource scheduling method, device and system | |
CN106790092B (en) | Remote procedure call server control system and method | |
CN111966500A (en) | Resource scheduling method and device, electronic equipment and storage medium | |
CN106201661A (en) | Method and apparatus for elastic telescopic cluster virtual machine | |
CN111880936A (en) | Resource scheduling method and device, container cluster, computer equipment and storage medium | |
US11909603B2 (en) | Priority based resource management in a network functions virtualization (NFV) environment | |
CN112463535A (en) | Multi-cluster exception handling method and device | |
CN112905338B (en) | Automatic computing resource allocation method and device | |
CN111988160B (en) | Method and device for deploying virtualized network function | |
CN115048216B (en) | Resource management scheduling method, device and equipment of artificial intelligent cluster | |
CN115965517B (en) | Graphics processor resource management method and device, electronic equipment and storage medium | |
CN114244717A (en) | Configuration method and device of virtual network card resources, computer equipment and medium | |
CN115858083A (en) | Container CPU resource scheduling and isolating method and device, storage medium and electronic equipment | |
CN111399968B (en) | Virtual resource management method, device and system based on container | |
CN110908774A (en) | Resource scheduling method, device, system and storage medium | |
CN113382077A (en) | Micro-service scheduling method and device, computer equipment and storage medium | |
CN112910937A (en) | Object scheduling method and device in container cluster, server and container cluster | |
CN112261125B (en) | Centralized unit cloud deployment method, device and system | |
CN105933136A (en) | Resource scheduling method and system |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |