CN109857521B - Host computer relocation method and device - Google Patents

Host computer relocation method and device Download PDF

Info

Publication number
CN109857521B
CN109857521B CN201910065533.0A CN201910065533A CN109857521B CN 109857521 B CN109857521 B CN 109857521B CN 201910065533 A CN201910065533 A CN 201910065533A CN 109857521 B CN109857521 B CN 109857521B
Authority
CN
China
Prior art keywords
host
hardware specification
service
source end
resource consumption
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Active
Application number
CN201910065533.0A
Other languages
Chinese (zh)
Other versions
CN109857521A (en
Inventor
张�杰
代杰
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Huawei Technical Service Co Ltd
Original Assignee
Huawei Technical Service Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Huawei Technical Service Co Ltd filed Critical Huawei Technical Service Co Ltd
Priority to CN201910065533.0A priority Critical patent/CN109857521B/en
Publication of CN109857521A publication Critical patent/CN109857521A/en
Application granted granted Critical
Publication of CN109857521B publication Critical patent/CN109857521B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Abstract

The embodiment of the application provides a host relocation method and device, relates to the technical field of computers, and realizes efficient host relocation. The method specifically comprises the following steps: determining the hardware specification of the destination host according to the performance parameters of the source host, such as the hardware specification of the source host and the target load of the destination host; sending the determined hardware specification of the destination host to a destination platform where the destination host is located, so that the destination platform creates the destination host according to the hardware specification; and sending a migration instruction to the source end host to enable the source end host to migrate the data to the destination end host.

Description

Host computer relocation method and device
Technical Field
The present application relates to the field of computer technologies, and in particular, to a method and an apparatus for host relocation.
Background
Cloud computing refers to a novel computing mode for sharing IT resources in a virtualization mode based on networks such as the Internet. Currently, cloud computing technology is rapidly developed, and technologies such as public cloud and private cloud are widely applied. A large amount of host relocation requirements exist between virtual hosts deployed in cloud computing and between cloud computing and a data center server.
When the host is moved, the target host is created according to a fixed host specification (pre-configured or obtained by customer input or other modes), and then the data of the source host is transmitted to the target host. After the data of the source host computer is transmitted to the target host computer, the specification of the target host computer is adjusted through a plurality of calculation and trial modes, so that the system performance meets the requirements of customers. Therefore, the current relocation mode is time-consuming and labor-consuming, the relocation efficiency is low, and meanwhile, the requirement on the skill of the personnel is high.
Disclosure of Invention
The embodiment of the application provides a host relocation method and device, and efficient host relocation is achieved.
In order to achieve the above purpose, the embodiment of the present application adopts the following technical solutions:
in a first aspect, a host relocation method is provided, and the method may include: collecting performance parameters of a source end host, wherein the performance parameters can comprise hardware specifications of the source end host; the performance parameter is used for representing the performance of the host; determining a hardware specification required by a destination end host under the service scene according to the performance parameters, the service scene of the source end host and the target load of the destination end host; sending the determined hardware specification required by the destination host to a destination platform where the destination host is located, so that the destination platform creates the destination host according to the hardware specification; and sending a migration instruction to the source end host, wherein the migration instruction is used for indicating the source end host to migrate the data of the source end host to the destination end host.
According to the host relocation method, the target load of the target end host is used as the target, the host specification meeting the target load is determined, the target end host is created to carry out host relocation, the whole process is automatically realized without manual participation, the problem that the specification of the target end host is adjusted through multiple calculation attempts after the existing relocation is replaced, and the relocation efficiency is high.
With reference to the first aspect, in a possible implementation manner, the performance parameters may further include resource consumption parameters of N service scenarios; the resource consumption parameter is used for representing resources consumed by the source end host under the service scene; n is greater than or equal to 1.
Specifically, the resource consumption parameter of a service scenario is used to indicate the resource consumed by the source host in the service input stage of the service scenario. Or, the resource consumption parameter of a service scenario is used to indicate the resource consumed by the source host in the service processing stage of the service scenario. Or, the resource consumption parameter of a service scenario is used to indicate the resource consumed by the source host in the service output stage of the service scenario. Or, the resource consumption parameter of a service scenario is used to represent the total resource consumed by the source host in the service input, processing and output stages of the service scenario.
With reference to the first aspect or any one of the foregoing possible implementation manners, in another possible implementation manner, the resource consumption parameter may include one or more of the following: resource consumption rate, resource consumption amount.
With reference to the first aspect or any one of the foregoing possible implementation manners, in another possible implementation manner, the resource consumption parameter may include a resource consumption indication value, where the resource consumption indication value is a reference value representing resource consumption, and a calculation expression that the resource consumption indication value is a dynamic parameter of the collectable host runtime may be predefined.
It should be noted that the service scenario may be a preset operation scenario of some services, or the service scenario may also be a scenario when resource consumption peaks in a preset acquisition period, and the specific content of the service scenario is not limited in the present application. Of course, the content of the service scenario may also be configured according to actual requirements.
With reference to the first aspect or any one of the foregoing possible implementation manners, in another possible implementation manner, the performance parameter may further include source host loads in N service scenarios.
With reference to the first aspect or any one of the foregoing possible implementation manners, in another possible implementation manner, the M service scenarios are service scenarios in which a load of the source end host is greater than or equal to a preset load threshold among the N service scenarios.
With reference to the first aspect, in a possible implementation manner, determining a hardware specification of the destination host according to a performance parameter of the source host and a target load of the destination host may specifically be implemented as: modifying parameters of the hardware specification of the source end host to obtain an optional hardware specification; judging whether the optional hardware specification meets the requirement of the target load or not according to resource consumption parameters of the source end host under M service scenes in the N service scenes and parameters of the optional hardware specification; m is less than or equal to N; and if the selectable hardware specification meets the requirement of the target load, taking the selectable hardware specification as the hardware specification of the destination host.
Wherein modifying the parameters of the hardware specification of the source host may include increasing a numerical value of one or more of the hardware specifications of the source host by a predetermined step. The modified object and the value of the predetermined step may be configured according to actual requirements, and the present application is not particularly limited.
With reference to the first aspect or any one of the foregoing possible implementation manners, in another possible implementation manner, determining whether the optional hardware specification meets a requirement of a target load according to a resource consumption parameter of a source host in M service scenarios in N service scenarios and a parameter of the optional hardware specification includes: respectively calculating a performance evaluation value of a hardware specification of a source end host and a performance evaluation value of an optional hardware specification under each service scene in the M service scenes; for any service scene in the M service scenes, calculating the performance evaluation value of the hardware specification of the source end host according to the resource consumption parameter in the service scene and the evaluation value of the hardware specification of the source end host; the performance evaluation value of the selectable hardware specification is calculated according to the resource consumption parameter under the service scene and the evaluation value of the selectable hardware specification; respectively calculating a first reference value under each service scene in the M service scenes, wherein for any one service scene in the M service scenes, the first reference value is obtained by calculation according to a performance evaluation value of the selectable hardware specification under the service scene and a performance evaluation value of the source end host specification under the service scene; specifically, the first reference value may be obtained by subtracting the performance evaluation value of the source end host specification in the service scenario from the performance evaluation value of the selectable hardware specification in the service scenario, and then dividing the performance evaluation value by the performance evaluation value of the selectable hardware specification in the service scenario. If the first reference value in the preset proportion of the M service scenes is greater than or equal to the threshold, the selectable hardware specification meets the requirement of the target load, the threshold may be calculated according to a difference between the load of the source-end host and the target load, and specifically, the threshold may be calculated according to a difference between the load of the source-end host and the target load.
The performance evaluation value of the hardware specification of one host under one service scene is calculated by a preset expression of the resource consumption parameter of the host under the service scene and the evaluation value of the hardware specification of the host; the grade value of the hardware specification of one host is calculated by a preset expression of the basic grade value of each hardware unit of the host; the basic score value of a hardware unit of a host is the score value corresponding to the specification of the hardware unit in the score corresponding relation of the hardware unit; the scoring corresponding relation is configured in advance.
With reference to the first aspect or any one of the foregoing possible implementation manners, in another possible implementation manner, determining whether the optional hardware specification meets a requirement of a target load according to a resource consumption parameter of a source host in M service scenarios in N service scenarios and a parameter of the optional hardware specification includes: respectively calculating the resource consumption of the source end host in each service scene in the M service scenes according to the resource consumption parameters of the source end host in the M service scenes; respectively calculating a second reference value under each service scene in the M service scenes, wherein for any service scene in the M service scenes, the second reference value is calculated according to the source consumption of the source end host machine under the service scene and the parameter of the optional hardware specification, and specifically, the second reference value can be a value obtained by dividing the source consumption of the source end host machine under the service scene by the parameter of the optional hardware specification; and if the second reference value in the service scene with the preset proportion in the M service scenes is less than or equal to the load, the selectable hardware specification meets the requirement of the target load.
With reference to the first aspect or any one of the foregoing possible implementation manners, in another possible implementation manner, the host relocation method provided by the present application may further include: if the selectable hardware specification does not meet the requirement of the target load, modifying the parameter of the selectable hardware specification, judging whether the selectable hardware specification meets the requirement of the target load according to the resource consumption parameter of the source end host under M service scenes in the N service scenes and the parameter of the selectable hardware specification until the selectable hardware specification meets the requirement of the target load, and determining the hardware specification of the target end host.
With reference to the first aspect or any one of the foregoing possible implementation manners, in another possible implementation manner, the hardware specification may include one or more of the following parameters of one or more hardware units in the host: type, number, size. Of course, the hardware specification may also include other parameters of one or more hardware units in the host, which is not specifically limited in this application.
With reference to the first aspect or any one of the foregoing possible implementations, in another possible implementation, the hardware unit may include one or more of the following hardware: a Central Processing Unit (CPU), a memory, and a hard disk.
In a second aspect, the present application provides an electronic device, where the electronic device may implement the functions in the above method examples, and the functions may be implemented by hardware or by hardware executing corresponding software. The hardware or software comprises one or more modules corresponding to the functions. The electronic device may be in the form of a chip product.
With reference to the second aspect, in a possible implementation manner, the electronic device includes a processor and a transceiver in a structure, and the processor is configured to support the electronic device to perform corresponding functions in the foregoing method. The transceiver is used to support communication between the electronic device and other devices. The electronic device may also include a memory, coupled to the processor, that retains program instructions and data necessary for the electronic device.
In a third aspect, a computer-readable storage medium is provided, which includes instructions, when executed on a computer, cause the computer to perform the host relocation method provided in any one of the above aspects or any one of the possible implementations.
In a fourth aspect, a computer program product containing instructions is provided, which when run on a computer, causes the computer to execute the host relocation method provided in any one of the above aspects or any one of the possible implementations.
It should be noted that, all possible implementation manners of any one of the above aspects may be combined without departing from the scope of the claims.
Drawings
FIG. 1 is a schematic diagram of a host relocation system according to the prior art;
fig. 2 is a schematic architecture diagram of a cloud data center provided in the prior art;
FIG. 3 is a schematic diagram of a server architecture provided in the prior art;
fig. 4 is a schematic structural diagram of a host relocation apparatus according to an embodiment of the present disclosure;
fig. 5 is a schematic flowchart of a host relocation method according to an embodiment of the present disclosure;
fig. 6 is a flowchart illustrating a method for determining a specification of a destination host according to an embodiment of the present disclosure;
FIG. 7 is a schematic structural diagram of another host relocation apparatus according to an embodiment of the present disclosure;
fig. 8 is a schematic structural diagram of another host relocation apparatus according to an embodiment of the present application.
Detailed Description
The terms "first," "second," "third," and "fourth," etc. in the description and claims of this application and the above-described drawings are used for distinguishing between different objects and not for limiting a particular order.
In the embodiments of the present application, words such as "exemplary" or "for example" are used to mean serving as an example, instance, or illustration. Any embodiment or design described herein as "exemplary" or "e.g.," is not necessarily to be construed as preferred or advantageous over other embodiments or designs. Rather, use of the word "exemplary" or "such as" is intended to present concepts related in a concrete fashion.
A, B, C, described in embodiments herein, is intended to represent the following concepts: a, or B, or C, or a and B, or a and C, or B and C, or A, B and C.
The application provides a host relocation method, which is efficient in host relocation and has the following basic principle: the method comprises the steps of collecting performance parameters of a source end host, obtaining a hardware specification of a target end host in combination with a target load to be achieved by the target end host, and then creating the target end host to carry out host relocation. Therefore, manual parameters are not needed for automatically configuring the host specification when the host is moved, and the host specification is not needed to be modified after the host is moved, so that the technical requirements of personnel are reduced, and the moving efficiency is improved.
The host relocation method provided by the present application is applied to the host relocation system 10 shown in fig. 1. As shown in fig. 1, the host relocation system 10 includes: a source host 101, a destination host 102, a platform 103, and a migration device 104.
The platform 103 may include a data center with multiple hosts and provide an interface to the outside so that a user or other unit can access the data center.
The platform 103 may include a source end platform for providing an interface to the outside and accessing and controlling the source end host 101, and a destination end platform for providing an interface to the outside and accessing and controlling the destination end host 102, which are not illustrated in detail in fig. 1 and are collectively referred to as the platform 103. The platform 103 may be a platform of a virtual host (referred to as a cloud platform) or a platform of an actual physical host (referred to as a physical platform) according to the type of the host, which is not specifically limited in this embodiment of the present invention. The platform 103 may be deployed in a server, and the server where the platform 103 is deployed and a host controlled by the server may be in the same server or in different servers. When the source host 101 and the destination host 102 belong to the same data center, the source platform and the destination platform may be one platform.
The migration device 104 may be a functional unit that performs host migration, and the migration device 104 may be deployed in a server. The moving device 104 may be deployed on the same server as any one of the platform 103, the source host 101, and the destination host 102, or may be deployed on a server independently, which is not specifically limited in this embodiment of the present application.
A specific host relocation process includes: when host relocation is performed, the relocation device 104 accesses the platform 103 to establish the destination host 102 and a network tunnel between the source host 101 and the destination host 102, the relocation device 104 obtains that the platform 103 sends a migration instruction to the source host 101, the migration instruction includes an identifier of the destination host 102, and the migration instruction is used for instructing the source host 101 to transmit its own data (including an operating system and service data) to the destination host 102, thereby completing host relocation.
Another specific host relocation process includes: the source end host 101 and the destination end host 102 are not networked, when host relocation is performed, the relocation device 104 accesses the platform 103 to establish the destination end host 102 and a network tunnel between the source end host 101 and the destination end host 102, the relocation device 104 acquires that the platform 103 sends a relocation instruction to the source end host 101, the relocation instruction is used for instructing the source end host 101 to transmit data (including an operating system and service data) of the source end host 101 to the removable storage unit, and then the removable storage unit is manually connected to the destination end host 102, so that host relocation is completed.
In one possible implementation, the relocation apparatus 104 may be deployed independently in a server, as shown in fig. 1. The other units of the relocation apparatus 104 that access the host relocation system 10 are all remote accesses.
In another possible implementation, the relocation apparatus 104 may be deployed on a server where the source host 101 is located. The source host 101 in the relocation device 104 accessing the host relocation system 10 is local access, and the other accessing units are remote access.
In yet another possible implementation, the relocation apparatus 104 may be deployed in a server where the destination host 102 is located. The destination host 102 in the relocation apparatus 104 accessing the host relocation system 10 is a local access, and the other units are remote accesses.
In yet another possible implementation, the relocation apparatus 104 may be deployed in a server where the platform 103 is located. The platform 103 in the host relocation system 10 accessed by the relocation apparatus 104 is accessed locally, and the other units accessed remotely.
It should be noted that the host described in this application may be a physical host in a data center, or may also be a virtual host, and this embodiment of this application does not specifically limit the actual form of the host. The host migration described in the present application may be migration from a server-type host to a virtual host, migration from a virtual host to a server-type host, or other migration.
The host relocation system 10 may be a part of the architecture of a data center when hosts are relocated, and the present application specifically defines the scale and form of the host relocation system 10.
Specifically, the host relocation system 10 illustrated in fig. 1 may be a part of a data center, where the data center may be a cloud data center including a plurality of virtual hosts, may also be a physical data center including a plurality of physical hosts, and may also be a hybrid data center including virtual hosts and physical hosts, and the type of the data center is not specifically limited in the present application. The following description is made with reference to the architecture of the cloud data center of fig. 2 to clarify the concept of the virtual host; the architecture of the server is described in conjunction with fig. 3 to clarify the concept of physical hosts. The following description of the architecture of the cloud data center and the server is only by way of example and is not particularly limited.
Fig. 2 illustrates an internal architecture diagram of a cloud data center 20. As shown in fig. 2, the cloud data center 20 includes an infrastructure layer 201, a virtualization layer 202, and at least one virtual machine.
The infrastructure layer 201 includes hardware facilities, such as computing devices, storage devices, and physical switching devices, which constitute the cloud data center 20, and these hardware facilities may be a single type of dedicated device or an integrated device integrating computing, storage, and switching. The physical switching devices in the infrastructure layer 201 construct a network according to a specific architecture to form a network core area, a virtual switch can be virtualized on the network core area, the virtual switch forms a network edge area outside the network core area, and the core and edge area switching devices are interconnected and intercommunicated to form an infrastructure network together. The resources in the infrastructure layer 201 may derive Virtual Machines (VMs), also referred to as virtual hosts, after being virtualized by the virtualization layer 202. The virtual machine accesses the virtual switch to access the network. As shown in fig. 1, the virtual machines 61 and 62 are virtual machines, and the edge switches 51, 52, and 53 are virtual switches. The user may access the virtual machine through an external network. The virtual machine may be the source host 101 or the destination host 102 in the host relocation system 10 shown in fig. 1.
Fig. 3 illustrates an internal structure of a server 30, and the server 30 may also be referred to as a physical host in the form of a physical server. As shown in fig. 3, the server 30 may include a memory 301, a memory controller 302, a processor 305, a Basic Input Output System (BIOS) 304, and a hard disk (not shown in fig. 3). The memory 301 includes at least one memory card, and in fig. 3, 3 memory cards are taken as an example, and the memory cards 301-a, 301-B, and 301-C. Memory controller 302 is configured to control memory 301, and may configure corresponding memory controller 302 for each memory card of memory 301, for example, memory controller 302-a of memory card 301-a, memory controller 302-B of memory card 301-B, and memory controller 302-C of memory card 301-C. The memory card in this embodiment may specifically be any storage medium that can be used as a memory, such as a memory board or a memory bank, where one memory card may refer to one memory bank or one memory board, and may also refer to a set of multiple memory banks or a set of multiple memory boards. Each memory card is configured with a corresponding memory controller, and the correspondence between the memory card and the memory controller may be one-to-one, or one-to-many or many-to-one, and fig. 3 is only one of the implementation examples of the present invention.
The memory 301 may be a volatile memory (volatile memory), such as a random-access memory (RAM); or a non-volatile memory (non-volatile memory), such as a read-only memory (ROM), a flash memory (flash memory), a Hard Disk Drive (HDD) or a solid-state drive (SSD); or a combination of the above types of memories, for storing program code, and configuration files, which implement the methods of the present application.
Processor 305 is the control center of server 30, and may be a CPU, an Application Specific Integrated Circuit (ASIC), or one or more integrated circuits configured to implement the embodiments of the present application, such as: one or more microprocessors (digital signal processors, DSPs), or one or more Field Programmable Gate Arrays (FPGAs).
After the server 30 is powered on, the memory 301 may load the instruction in the BIOS 304 and the instruction of the Operating System (OS) 303 of the computer stored in the hard disk when the server 30 is powered on and started, and the processor 305 may execute the instruction of the BIOS 304 or the instruction of the OS 303 of the server 30, for example, the processor 305 may execute the instruction of the BIOS 304 to initialize a device in the server 30 and execute the instruction of the OS 303 to perform a read/write operation on a memory card, where the processor 305 may refer to a Central Processing Unit (CPU) core portion, which may be one CPU core or a set of a plurality of CPU cores, and in the embodiment of the present invention, the processor 305 is a set of a plurality of CPU cores. BIOS 304 may be a processing chip within which processing instructions are configured that processor 305 may execute.
Embodiments of the present application will be described in detail below with reference to the accompanying drawings.
In one aspect, the present embodiment provides an electronic device 40, alternatively referred to as a host relocation device 40, where the host relocation device 40 may be a relocation device 104 in the host relocation system 10 shown in fig. 1. Fig. 4 illustrates a host relocation apparatus 40 according to various embodiments of the present application. As shown in fig. 4, the host relocation apparatus 40 may include: a processor 401, a memory 402, a transceiver 403.
The following specifically describes each component of the host relocation apparatus 40 with reference to fig. 4:
a memory 402, which may be a volatile memory (RAM); or a non-volatile memory such as a read-only memory (ROM), a flash memory (HDD), or an SSD; or a combination of the above types of memories, for storing program code, and configuration files, which implement the methods of the present application.
The processor 401 is a control center of the host relocation apparatus 40, and may be a CPU, an ASIC, or one or more integrated circuits configured to implement the embodiments of the present application, for example: one or more DSPs, or one or more FPGAs. Processor 401 may perform various functions of host relocation apparatus 40 by running or executing software programs and/or modules stored in memory 402 and by invoking data stored in memory 402.
The transceiver 403 is used for the host relocation apparatus 40 to interact with other units. Illustratively, the transceiver 403 may be a transceiver port of the host relocation apparatus 40.
Specifically, the processor 401 executes or executes software programs and/or modules stored in the memory 402 and calls data stored in the memory 402 to perform the following functions:
collecting performance parameters of a source end host, wherein the performance parameters can comprise hardware specifications of the source end host; the performance parameter is used for representing the performance of the host; determining the hardware specification of the destination end host according to the performance parameters and the target load of the destination end host; sending the determined hardware specification of the destination host to a destination platform where the destination host is located, so that the destination platform creates the destination host according to the hardware specification; and sending a migration instruction to the source end host, wherein the migration instruction is used for indicating the source end host to migrate the data of the source end host to the destination end host.
In another aspect, an embodiment of the present application provides a host relocation method, as shown in fig. 5, the method may include:
s501, connecting the host relocation device with the source host.
Specifically, when a user requests host relocation, the host relocation device is provided with an identifier of the source host, and the host relocation device can uniquely determine the source host according to the identifier and is connected with the source host through an interface provided by a platform where the source host is located. When the host relocation apparatus and the source host belong to the same physical server in terms of hardware, the host relocation apparatus can also access and operate the host through the platform, and thus the host relocation apparatus can connect the source host in S501. When the host relocation device is connected to the source host, the host relocation device is authorized by the source host, and operations such as reading configuration and acquisition parameters of the source host are allowed.
S502, the host relocation device collects performance parameters of the source host.
In particular, the performance parameter may be used to indicate the performance of the host. Optionally, the performance parameters may include static hardware specifications and may also include dynamic operating parameters. The dynamic operation parameters refer to parameters that change continuously during the operation of the host, and the operation parameters are used for reflecting the operation capability of the host.
The performance parameter may include a hardware specification of the source host.
In one possible implementation, the hardware specification may include one or more of the following parameters for one or more hardware units in the host: type, number, size. Of course, the hardware specification may also include other parameters, and the description herein does not limit the content of the hardware specification.
It should be noted that different hardware units may have different parameters, and therefore, different hardware units may include different parameters in the hardware specification. For example, the hardware specifications of a hard disk may include model, quantity, size, and bandwidth. The bandwidth of the hard disk refers to the speed of data stream when the hard disk transmits data, and is used for reflecting the throughput rate of the magnetic disk.
The model may be a model defined by a manufacturer of the hardware unit, or may be a functional model corresponding to the performance of the hardware unit, which is not specifically limited in this embodiment of the present application. The size may be the capacity of a hardware unit, e.g. the size of a memory refers to the storage capacity of the memory.
Specifically, the host relocation apparatus may obtain the hardware specification of the host by reading the host configuration information, and the host relocation apparatus may also receive the hardware specification fed back by the host through the response signaling by sending the request signaling to the host, and of course, may also have other acquisition modes to acquire the hardware specification of the host, which is not specifically limited in the embodiment of the present application.
In one possible implementation, the hardware units may include one or more of the following hardware: CPU, internal memory, hard disk. Of course, the hardware unit may also include other units in other hosts, and the description herein of the embodiments of the present application does not limit the content of the hardware unit.
It should be noted that parameters of the hardware unit included in the hardware specification may be configured according to actual requirements, and this is not specifically limited in this embodiment of the application.
In another possible implementation, on the basis that the performance parameter includes a hardware specification of the source host, the performance parameter may further include one or more of the following: resource consumption parameters under N service scenes and source end host loads under N service scenes. The resource consumption parameter in a service scene is used for expressing the consumption of resources of at least one stage of the operation service of the host in the service scene; the stages described herein may include one or more of a full stage, an input stage, a processing stage, or an output stage. N is greater than or equal to 1.
The N service scenarios may be operation scenarios in which the peak of resource consumption in the N acquisition periods is located. Alternatively, the N service scenarios may be N predefined preset service scenarios. This is not particularly limited in the embodiments of the present application.
It should be noted that any one of the hardware specifications of the host belongs to the resources of the host, and therefore, the "resource" referred to in the contents of resource consumption, resource occupation, and the like described herein refers to the capability provided by the hardware specification of the host, and the host consumes or occupies the resource when running a service.
It should be noted that the acquisition cycle may be a preset time or a time point of a periodic time, or may be a time period lasting for a certain duration, which is not specifically limited in this embodiment of the application. The specific value of N may be configured according to actual requirements, which is not specifically limited in this embodiment of the present application.
Illustratively, N is configured to be 50, and 50 acquisition cycles are acquired at equal intervals over 7 days.
In one possible implementation, peak data may be collected as performance parameters are collected over a collection period to achieve optimal host migration. The peak data may be a true peak after being judged, rather than a false peak in an emergency. The process of determining the true and false peaks is not specifically limited in the embodiments of the present application.
Optionally, the resource consumption parameter may include one or more of the following: resource consumption rate, or resource consumption amount. Both describe resource occupancy from different dimensions.
In one possible implementation, the resource consumption parameter may include a resource consumption indication value. Wherein the resource consumption indication value is a reference value representing resource consumption. A computational expression may be predefined in which the resource consumption indication value is a dynamic parameter of the host runtime that is collectable.
In one possible implementation, the resource consumption parameters may be obtained using scoring software.
In another possible implementation, the operating parameters related to the resource consumption parameters may be preconfigured, and the calculation expressions of the resource consumption parameters related to the related operating parameters may be preconfigured, and the host relocation apparatus may collect the operating parameters related to the resource consumption parameters, substitute the operating parameters into the preconfigured calculation expressions, and then calculate and obtain the resource consumption parameters. The operation parameters related to the resource consumption parameters are dynamic parameters which affect the resource consumption parameters and can be directly acquired.
For example, the configured operating parameters associated with the resource consumption parameters during the service input phase may include: input resource, percent1, cpu1, mem1, io1, net in1, net out 1. And configuring a calculation expression of the resource consumption parameters when the service is input, and calculating a weighted sum of the related operation parameters according to a preset weight value. The host relocation device acquires the resource consumption during service input by acquiring input resource, percentage 1, cpu1, mem1, io1, net in1 and net out1 during service input and calculating the weighted sum according to the preset weight. Wherein, input resource represents the percentage of resources that must be consumed by service startup; percentage 1 indicates the percentage of traffic consumed during the start phase; cpu1 indicates the cpu size consumed by the service during the input phase; mem1 represents the memory size consumed by the service during the input phase; io1 represents that the business consumes the input-output read-write efficiency in the input stage; net in1 represents the resources consumed by a service consuming into the network during the input phase; net out1 represents the percentage of the network consumed by traffic in the incoming phase.
For example, the configured operating parameters associated with the resource consumption parameters during the business process stage may include: deal resource, percent2, cpu2, mem2, io2, net in2, net out 2. And configuring a calculation expression of the resource consumption parameters during service processing, and calculating a weighted sum of the related operation parameters according to a preset weight value. The host relocation device acquires the resource consumption during service processing by acquiring the default resource, percentage 2, cpu2, mem2, io2, net in2 and net out2 during service processing and calculating the weighted sum according to the pre-configured weight. Wherein, the real resource represents the resource percentage that the service processing must consume; percentage 2 represents the percentage consumed during the traffic processing phase; cpu2 represents the cpu size consumed during the business process phase; mem2 represents the size of memory consumed during the business process phase; io2 represents the consumption of input/output read-write efficiency during the service processing stage; net in2 represents the resources consumed by the network during the traffic processing phase; net out2 represents the percentage of resources consumed by the network during the traffic processing phase.
For example, the configured operation parameters of the service output stage and the resource consumption parameters can include: out resource, percent3, cpu3, mem3, io3, net in3, net out 3. And configuring a calculation expression of the resource consumption parameters during service output, and calculating a weighted sum of the related operation parameters according to a preset weight value. The host relocation device acquires the resource consumption during service output by collecting out resource, percent3, cpu3, mem3, io3, net in3 and net out3 during service output and calculating the weighted sum according to the preset weight. Out resource represents the percentage of resources that the traffic output must consume; percentage 3 represents the percentage consumed during the service output phase; cpu3 represents the consumption cpu size during the service output phase; mem3 represents the size of memory consumed during the service output phase; io3 represents the consumption of input/output read-write efficiency in the service output stage; net in3 represents the resources consumed by the network during the service export phase; net out3 represents the percentage of resources consumed by the network during the traffic egress phase.
It should be noted that, the above example only illustrates the process of acquiring the resource consumption parameters by way of example, and is not a limitation to the process of acquiring the resource consumption parameters.
In one possible implementation, load is an indicator used to evaluate host performance, and load may be replaced with resource usage. The load and resource consumption parameters describe the service of the host performance from different angles, the load describes from a relative value angle, and the resource consumption parameter describes from an absolute value. For example, when the load is 60%, the resource consumption parameter corresponds to a resource of 60% of the total capacity of the host.
For example, assume that the hardware specification of the source host collected in S502 is:
CPU specification: the model A; the number of CPUs: 2;
memory specification: type B, memory size 16 × 16G;
and (3) specification of a magnetic disk: type C, disk size 4 x 1 Terabyte (TB), disk bandwidth: 80 megabits per second (MB/S);
assume a resource consumption parameter is a resource consumption indicator, and assume that in a sampling period (referred to as a traffic scenario 1), an acquired peak resource consumption parameter (an exemplary resource consumption parameter is a resource consumption indicator) is: 13000 for input stage resources, 15800 for processing stage resources, and 19600 for output stage resources. In the service scenario 1, the CPU load is 89%, and the memory load is 81%.
Assume that in another sampling period (referred to as a traffic scenario 2), the collected peak resource consumption reference values are: input stage resource consumption 12000, processing stage resource consumption 13800, and output stage resource consumption 16600. In the service scenario 2, the CPU load is 85% and the memory load is 80%.
Similarly, taking data from multiple acquisition cycles to obtain data for at least 7 days, one can obtain: the performance parameters of the source host in multiple service scenarios are shown in table 1.
TABLE 1
Figure BDA0001955063300000091
S503, the host relocation device determines the hardware specification required by the destination host in the service scene according to the performance parameters of the source host, the service scene of the source host and the target load of the destination host.
Wherein, the performance parameter of the source host is acquired in S502. The target load of the destination host may be specified by the user in the host relocation device through an input manner, and may also be an industry standard value, or may also be a value obtained in another manner, which is not specifically limited in this embodiment of the application. For source end hosts under different service scenes, the hardware specification required by the destination end host can be determined according to the performance parameters of the source end host, the service scenes and the target load of the destination end host. For example, a source host is often in a service scenario with low resource consumption, and if the configured hardware specification of a destination host is too large, the resource utilization rate is reduced; for a source host that is often in a service scenario with high resource consumption, if the configured hardware specification of a destination host is too small, the load of the destination host is too large.
Specifically, in S503, determining the hardware specification of the destination host according to the performance parameter of the source host, the service scenario of the source host, and the target load of the destination host all belong to the protection scope of the present application, and the specific scheme determined by the present application is not limited.
The present application provides two possible implementations (a first possible implementation and a second possible implementation described below) for determining the hardware specification parameters of the destination end host in S503, but the present application is not limited to the specific implementation of S503. The purpose of S503 is to determine the hardware specification of the destination host, so that the load of the destination host meets the requirement of the target load.
A first possible implementation: in a first possible implementation, in S502, the hardware specification of the destination host is determined according to the performance parameter of the source host and the target load of the destination host, and a specific implementation is as shown in fig. 6, and specifically may include the following steps:
s601, modifying the parameters of the current optional hardware specification to update the optional hardware specification.
It should be noted that, if the process illustrated in fig. 6 is executed for the first time in S503, the current optional hardware specification is the hardware specification of the source host.
In one possible implementation, modifying the parameters of a certain specification may be increasing the values of one or more of the parameters of a certain hardware specification by a preset step value. The value of the preset step can be configured according to actual requirements, and the preset steps of different hardware units can be different.
It should be noted that the parameter object modified in S601 may be configured according to actual requirements, and this is not specifically limited in this embodiment of the application. The parameter objects that are modified each time S601 is executed may be the same or different.
S602, judging whether the selectable hardware specification meets the requirement of the target load according to the resource consumption parameters in the M service scenes in the N service scenes and the parameters of the selectable hardware specification.
Wherein M is less than or equal to N.
In one possible implementation, M is equal to N, and M service scenarios are all service scenarios in the N service scenarios.
In another possible implementation, the M service scenarios are service scenarios in which the load of the source host is greater than or equal to the preset load threshold among the N service scenarios. The preset load threshold may be configured according to actual requirements, which is not specifically limited in the embodiment of the present application.
For example, the predetermined load threshold may be a load threshold that is considered to be busy or not. Alternatively, the preset load threshold may be a target load.
Specifically, it can be understood that, if a host is established in the current selectable hardware specification to run the service of the source end host, the load of the host when running the service of the source end host can meet the requirement of the target load. In S602, the specific determination may be realized by a simple calculation.
Specifically, S602 may have multiple implementations, and the embodiment of the present application is not limited to a specific implementation. Two specific implementations of S602 are illustrated below, including implementation a and implementation B, but not limiting the process of S602 specifically.
The implementation a and the implementation S602 by the intermediate quantity specifically include the following steps.
Step 1, respectively calculating a performance evaluation value of a hardware specification of a source end host and a performance evaluation value of an optional hardware specification under each service scene in M service scenes.
Specifically, the performance evaluation value of the hardware specification of the source end host is calculated according to the resource consumption parameter in each service scene and the rating value of the hardware specification of the source end host; and the performance evaluation value of the selectable hardware specification is calculated according to the resource consumption parameter under each service scene and the evaluation value of the selectable hardware specification.
In one possible implementation, the performance evaluation value of the hardware specification of a host in a service scenario is calculated by a first preset expression of the resource consumption parameter of the host in the service scenario and the rating value of the hardware specification of the host. The value of the credit of the hardware specification of a host is calculated for a second predetermined expression of the value of the base credit for each hardware unit of the host. The basic score value of a hardware unit of a host is the score value corresponding to the specification of the hardware unit in the score corresponding relation of the hardware unit. The scoring corresponding relation is configured in advance.
The performance evaluation value is a reference value used for evaluating the performance of the host, and the performance evaluation value under a service scene can be obtained by presetting the content of a first preset expression and substituting the resource consumption parameter under the service scene and the rating value of the hardware specification of the host into the first preset expression.
Specifically, experience value scoring may be performed on hardware units of the service mainstream in advance, and a scoring corresponding relationship of the hardware units is constructed, where the scoring corresponding relationship of the hardware units includes specifications of different hardware units and respective corresponding experience score values. For a hardware unit, when the hardware specification is obtained, the grading corresponding relation of the hardware unit is inquired, and the corresponding experience grading value is obtained and is used as the basic grading value of the hardware unit.
For example, assume that the resource consumption parameters (resource consumption indication values) in the service scenario a are resource consumption S1 in the service input phase, resource consumption S2 in the service processing phase, and resource consumption S3 in the service output phase, and the score value defining the hardware specification of the source host is S4. Then, the hardware specification of the source host has a performance evaluation value TF ═ f in the traffic scenario a (S1, S2, S3, S4). Where f () is a first preset expression.
Where, S4 may be defined as y (MARK C, MARK M, MARK D), y () is a second preset expression, MARK C is a base score of the CPU of the source host, MARK M is a base score of the memory of the source host, and MARK D is a base score of the hard disk of the source host.
In a possible implementation, the first preset expression or the second preset expression may be a weighted sum, or the like, and this is not specifically limited in this embodiment of the present application. When the first preset expression or the second preset expression is a weighted sum, the weight may be configured in advance, which is not specifically limited in this application.
Illustratively, based on the example in S502, the specific operations in S601 may include:
assuming that the base score of the CPU is 10000, the base score of the memory is 2000, and the base score of the disk is 3000 in the hardware specification of the source host, the score value S4 of the source host is 10000+2000+3000, which is 15000.
From the performance parameters of the source host illustrated in table 1, 2 service scenarios with a load greater than 80% are selected (a first row in table 2 is referred to as a service scenario 1, and a second row is referred to as a service scenario 2).
Suppose the performance evaluation value of the hardware specification of a host in a service scenario is a weighted sum of the resource consumption parameter of the host in the service scenario and the rating value of the hardware specification of the host, and the weighting coefficients are both 1.
The performance evaluation value of the source host in the service scenario 1 is calculated as TF1 ═ 13000+15800+19600+15000 ═ 63400, and the performance evaluation value of the source host in the service scenario 2 is calculated as TF2 ═ 12000+13800+16600+15000 ═ 57400.
And calculating the performance evaluation value TF1 of the optional hardware specification under the service scene A as f (S1, S2, S3 and S4'). Wherein, S4 ═ y (MARK C ', MARK M', MARK D '), MARK C' is the base score value of the CPU of the selectable hardware specification, MARK M 'is the base score value of the memory of the selectable hardware specification, and MARK D' is the base score value of the hard disk of the selectable hardware specification.
For example, suppose that resources are added to the hardware specification of the source host to obtain a CPU with a hardware specification of 28 model a +256G memories (unchanged) +5T model C disks.
Assuming that the CPU base score 12000, the memory base score 2000, and the disk base score 4000 are included in the optional hardware specification, the score value S4 of the optional hardware specification is 12000+2000+4000 and 18000.
The performance evaluation value of the optional hardware specification in the service scenario 1 is calculated as TF1 '═ 13000+15800+19600+18000 ═ 66400, and the performance evaluation value of the optional hardware specification in the service scenario 2 is calculated as TF 2' ═ 12000+13800+16600+18000 ═ 60400.
And 2, respectively calculating a first reference value in each of the M service scenes.
The first reference value in a service scenario is obtained by subtracting the performance evaluation value of the source end host specification in the service scenario from the performance evaluation value of the selectable hardware specification in the service scenario, and then dividing the performance evaluation value by the performance evaluation value of the selectable hardware specification in the service scenario.
Illustratively, based on the example in step 1, in the traffic scenario 1, the difference between the performance evaluation values of the hardware specification of the source host and the optional hardware specification (66400-. In the service scenario 2, the difference (60400-.
And 3, if the first reference value under the service scene with the preset proportion in the M service scenes is greater than or equal to the difference value between the load of the source end host and the target load, the optional hardware specification meets the requirement of the target load.
And if the first reference value in a service scene is greater than or equal to the difference between the load of the source end host and the target load in the service scene, the optional hardware specification in the service scene can meet the performance requirement. When the selectable hardware specification can meet the performance requirement under the service scene with the preset proportion, the selectable hardware specification meets the requirement of the target load.
Illustratively, based on the example in step 2, the first reference value 4.51% in the traffic scenario 1 is less than 10% of the difference between 89% of the load of the source host and 79% of the target load in the traffic scenario 1.
The first reference value 4.97% in the service scenario 2 is less than 10% of the difference between 89% of the load of the source host and 79% of the target load in the service scenario 2.
Assuming that the preset proportion is 100%, the current optional hardware specification does not meet the requirement of the target load. At this time, S601 is executed again, the current selectable hardware specification is 28 models a of CPU +256GB memory (unchanged) +5TB model C of disk, and the numerical value is increased to obtain 48 models a of CPU +256GB memory (unchanged) +6TB model C of disk.
Assuming that the CPU basic score 25000, the memory basic score 2000 and the disk basic score 10000 in the latest optional hardware specification, the score value S4 of the optional hardware specification is 25000+2000+10000 is 37000.
Re-executing step 1 in S602 to calculate the performance evaluation value of the optional hardware specification in service scenario 1 as TF1 '═ 13000+15800+19600+37000 ═ 85400, and the performance evaluation value of the optional hardware specification in service scenario 2 as TF 2' ═ 12000+13800+16600+37000 ═ 79400.
Re-executing step 2 in S602, in the service scenario 1, the difference between the performance evaluation values of the hardware specification of the source host and the optional hardware specification (85400-. The first evaluation value in the service scenario 1 is greater than 10% of the difference between 89% of the load of the source end host and 79% of the target load in the service scenario 1.
In the service scenario 2, the difference between the performance evaluation values of the hardware specification of the source host and the optional hardware specification (79400-. The first evaluation value in the service scenario 2 is greater than 10% of the difference between 89% of the load of the source end host and 79% of the target load in the service scenario 2.
Thus, the current optional hardware specification meets the requirements of the target load.
And the implementation B is realized by specifically acquiring the load of the optional hardware specification under each service scene S602, and specifically comprises the following steps a to c.
Step a, respectively calculating the resource consumption of the source end host in each service scene in the M service scenes according to the resource consumption parameters of the source end host in the M service scenes.
In a possible implementation, when the resource consumption parameter is a resource consumption rate, the resource consumption of the source end host in each of the M service scenarios is a product of a hardware specification of the source end host and the resource consumption rate of the source end host in each of the M service scenarios.
In another possible implementation, when the resource consumption parameter is resource consumption, the resource consumption of the source end host in each of the M service scenarios is the resource consumption parameter of the source end host in each of the M service scenarios.
And b, respectively calculating a second reference value in each of the M service scenes.
The second reference value in a service scenario is a parameter obtained by dividing the resource consumption of the source end host in the service scenario by the specification of the selectable hardware.
For example, assuming that the CPU of the source host is 16 Gigabytes (GB), in the service scenario B, the total resource consumption of the source host in the full stage of the service processing is 90%, and then the resource consumption of the source host in the service scenario is (16 × 90%) GB. Assuming that the optional hardware specification is 16.5GB, then the second reference value of the optional hardware specification under the service scenario B is 16.5GB by 100%/(16 by 90%) GB. Wherein, is multiplication.
And c, if the second reference value in the service scene with the preset proportion in the M service scenes is less than or equal to the target load, the optional hardware specification meets the requirement of the target load.
Specifically, in S602, if the load with the optional hardware specification meets the requirement of the target load, S603 is executed. And if the load of the selectable hardware specification does not meet the requirement of the target load, re-executing the step S601 until the selectable hardware specification meets the requirement of the target load, and determining the hardware specification parameters of the host of the destination end.
S603, taking the selectable hardware specification as the hardware specification of the destination host.
Illustratively, based on the examples of step 1 to step 3 in S602, in S603, 48 model a CPUs +256GB memory (unchanged) +6TB model C disks may be used as the hardware specification of the destination host.
A second possible implementation: in S502, the hardware specification of the destination host is determined according to the performance parameter of the source host and the target load of the destination host, which may specifically be implemented as follows: and taking the host specification corresponding to the performance parameters of the source end host and the target load in the preset corresponding relation as the hardware specification of the target end host.
The preset corresponding relationship includes different performance parameters and host hardware specifications corresponding to different target loads. The preset corresponding relation may be a database configured according to actual experience or historical sampling data.
For example, table 2 illustrates the content of a preset correspondence, but the content and the form of the preset correspondence are not specifically limited.
TABLE 2
Target load 1 Target load 2 ……
Performance parameter A Host specification a Host specification b ……
Performance parameter B Specification of host computer c Specification d of the host ……
Performance parameter C Host specification e Host specification f ……
…… …… …… ……
It should be noted that table 2 is only an example, and the performance parameter and the target load in table 2 may be specific values or may be an interval range, which is not specifically limited in the embodiment of the present application.
Taking the preset corresponding relation shown in table 2 as an example, assuming the performance parameter C of the source host collected in S502, the obtained target load of the destination host is the target load 2, and the look-up table 2 can determine that the hardware specification of the destination host is the host specification f.
When the preset corresponding relationship is queried, the content may be completely the same as the content in table 2, or may belong to the range represented by the content in table 2, which is not specifically limited in this embodiment of the application.
It should be noted that table 2 is only an example to describe the form and content of the preset correspondence relationship, and is not a specific limitation to the form and content of the preset correspondence relationship.
S504, the host relocation device sends the hardware specification required by the destination host to the destination platform where the destination host is located, so that the destination platform creates the destination host according to the hardware specification required by the destination host.
Specifically, the process of creating the host by the destination platform is not described in detail in the present application.
S505, the host relocation apparatus sends a migration instruction to the source host, wherein the migration instruction is used for indicating the source host to migrate data of the source host to the destination host.
It should be noted that, the process of instructing, by the host relocation apparatus, the source host to migrate the data of the source host to the destination host through the migration instruction is already described in the foregoing, and is not described herein again.
The host computer relocation is completed through the processes from S501 to S505, and after the relocation is completed, the destination host computer can normally operate after being restarted, so that the host computer meeting the target load is provided for the user.
According to the host relocation method, the specification of the target host is determined first, and then the host is relocated, so that efficient host relocation is realized.
Further, as shown in fig. 5, the host relocation method provided in the embodiment of the present application may further include S506.
S506, the host relocation device uploads the additional program to the destination host and adds the additional program to the operating system starting program of the destination host.
Wherein the additional program comprises a network policy and/or a security policy, and the additional program automatically configures the network policy and/or the security policy when executed. Optionally, the network policy and/or security policy included in the additional program may be a collected network policy and/or security policy of the remote host, or a network policy and/or security policy provided by the user, which is not specifically limited in this embodiment of the present application.
Because the additional program is added into the operating system starting program of the destination end host, when the destination end host is restarted, the additional program is started to be executed, and the network policy and/or the security policy are automatically configured.
The above-mentioned scheme provided by the embodiment of the present application is introduced mainly from the perspective of interaction between network elements. It is to be understood that the host relocation apparatus includes hardware structures and/or software modules for performing the functions. Those of skill in the art would readily appreciate that the various illustrative elements and algorithm steps described in connection with the embodiments disclosed herein may be implemented as hardware or combinations of hardware and computer software. Whether a function is performed as hardware or computer software drives 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 application.
In the embodiment of the present application, the host relocation apparatus may be divided into the functional modules according to the method example, for example, each functional module may be divided corresponding to each function, or two or more functions may be integrated into one processing module. The integrated module can be realized in a hardware mode, and can also be realized in a software functional module mode. It should be noted that, in the embodiment of the present application, the division of the module is schematic, and is only one logic function division, and there may be another division manner in actual implementation.
Fig. 7 shows a schematic diagram of a possible structure of the host relocation apparatus 70 according to the above embodiment, in a case where each functional module is divided for each function. As shown in fig. 7, the host relocation apparatus 70 may include: an acquisition unit 701, a determination unit 702, and a sending unit 703. The acquisition unit 701 is configured to execute the process S502 in fig. 5; the determination unit 702 is configured to execute the process S503 in fig. 5; the sending module 703 is configured to execute the processes S504 and S505 in fig. 5. All relevant contents of each step related to the above method embodiment may be referred to the functional description of the corresponding functional module, and are not described herein again.
In the case of an integrated unit, fig. 8 shows a schematic view of a possible structure of the host relocation apparatus 80 according to the above embodiment. The host relocation apparatus 80 may include: a processing module 801 and a communication module 802. The processing module 801 is used to control and manage the operation of the host relocation apparatus 80. For example, the processing module 801 is configured to execute the processes S501, S502, S503 in fig. 5; the communication module 802 is configured to perform the processes S504 and S505 in fig. 5. The host relocation device 80 may further include a storage module 803 for storing program codes and data of the host relocation device 80.
The processing module 801 may be the processor 401 in the physical structure of the host relocation apparatus 40 shown in fig. 4, and may be a processor or a controller. For example, it may be a CPU, general purpose processor, DSP, ASIC, FPGA or other programmable logic device, transistor logic device, hardware component, or any combination thereof. Which may implement or perform the various illustrative logical blocks, modules, and circuits described in connection with the disclosure. The processor 801 may also be a combination of computing functions, e.g., comprising one or more microprocessors, a combination of a DSP and a microprocessor, or the like. The communication module 802 may be the transceiver 403 in the physical structure of the host relocation apparatus 40 shown in fig. 4, and the communication module 802 may be a communication port, or may be a transceiver, a transceiver circuit, a communication interface, or the like. Alternatively, the communication interface may be configured to communicate with another device through the element having the transmission/reception function. The above-mentioned elements with transceiving functions may be implemented by antennas and/or radio frequency devices. The storage module 803 may be the memory 402 in the physical structure of the host relocation apparatus 40 shown in fig. 4.
When the processing module 801 is a processor, the communication module 802 is a transceiver, and the storage module 803 is a memory, the host relocation apparatus 80 according to the embodiment of the present application shown in fig. 8 can be the host relocation apparatus 40 shown in fig. 4.
As mentioned above, the host relocation apparatus 70 or the host relocation apparatus 80 provided in the embodiments of the present application can be used to implement the steps in the method implemented in the embodiments of the present application, and for convenience of description, only the parts related to the embodiments of the present application are shown, and details of the specific technology are not disclosed, please refer to the embodiments of the present application.
As another form of the present embodiment, there is provided a computer-readable storage medium having stored thereon instructions that, when executed, perform the host relocation method in the above-described method embodiments.
As another form of the present embodiment, a computer program product containing instructions is provided, and the instructions are executed to execute the host relocation method in the above method embodiments.
It is clear to those skilled in the art that, for convenience and brevity of description, the specific working processes of the above-described systems, apparatuses and units may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
Those skilled in the art will recognize that in one or more of the examples described above, the functions described herein may be implemented in hardware, software, firmware, or any combination thereof. When implemented in software, the functions may be stored on or transmitted over as one or more instructions or code on a computer-readable medium. Computer-readable media includes both computer storage media and communication media including any medium that facilitates transfer of a computer program from one place to another. A storage media may be any available media that can be accessed by a general purpose or special purpose computer. It is clear to those skilled in the art that, for convenience and brevity of description, the specific working processes of the above-described systems, apparatuses and units may refer to the corresponding processes in the foregoing method embodiments, and are not described herein again.
In the several embodiments provided in the present application, it should be understood that the disclosed system, apparatus and method may be implemented in other manners. For example, the above-described apparatus embodiments are merely illustrative, and for example, the division of the units is only one logical division, and other divisions may be realized in practice, for example, a plurality of units or components may be combined or integrated into another system, or some features may be omitted, or not executed. In addition, the shown or discussed mutual coupling or direct coupling or communication connection may be an indirect coupling or communication connection of some interfaces, devices or units, and may be an electric or other form.
The units described as separate parts may or may not be physically separate, and parts displayed as units may or may not be physical units, may be located in one place, or may be distributed on a plurality of network units. Some or all of the units can be selected according to actual needs to achieve the purpose of the solution of the embodiment.
In addition, functional units in the embodiments of the present application may be integrated into one processing unit, or each unit may be physically included alone, or two or more units may be integrated into one unit. The integrated unit can be realized in a form of hardware, or in a form of hardware plus a software functional unit.
The integrated unit implemented in the form of a software functional unit may be stored in a computer readable storage medium. The software functional unit is stored in a storage medium and includes several instructions for causing a computer device (which may be a personal computer, a server, or a network device) to execute some steps of the methods described in the embodiments of the present application. And the aforementioned storage medium includes: various media capable of storing program codes, such as a usb disk, a removable hard disk, a Read-Only Memory (ROM), a Random Access Memory (RAM), a magnetic disk, or an optical disk.
Finally, it should be noted that: the above embodiments are only used to illustrate the technical solutions of the present application, and not to limit the same; although the present application has been described in detail with reference to the foregoing embodiments, it should be understood by those of ordinary skill in the art that: the technical solutions described in the foregoing embodiments may still be modified, or some technical features may be equivalently replaced; and such modifications or substitutions do not depart from the spirit and scope of the corresponding technical solutions in the embodiments of the present application.

Claims (18)

1. A host computer relocation method is characterized by comprising the following steps:
acquiring performance parameters of a source end host, wherein the performance parameters comprise the hardware specification of the source end host;
determining a hardware specification required by a target end host under the service scene according to the performance parameters, the service scene of the source end host and the target load of the target end host;
sending the hardware specification required by the destination host to a destination platform where the destination host is located, so that the destination platform creates the destination host according to the hardware specification required by the destination host;
and sending a migration instruction to the source end host, wherein the migration instruction is used for indicating the source end host to migrate the data of the source end host to the destination end host.
2. The method of claim 1, wherein the performance parameters further include resource consumption parameters of N traffic scenarios, and the resource consumption parameters are used to represent resources consumed by the source host in any traffic scenario; said N is greater than or equal to 1;
determining the hardware specification of the destination host under the service scenario according to the performance parameter, the service scenario of the source host and the target load of the destination host, including:
modifying the parameters of the hardware specification of the source end host to obtain an optional hardware specification;
judging whether the optional hardware specification meets the requirement of the target load or not according to the resource consumption parameters of the source end host under M service scenes in the N service scenes and the parameters of the optional hardware specification; said M is less than or equal to N;
and if the selectable hardware specification meets the requirement of the target load, taking the selectable hardware specification as the hardware specification of the destination host.
3. The method of claim 2, wherein the performance parameters further include a load of the source host in each of the N service scenarios, and wherein the determining whether the optional hardware specification meets the requirement of the target load according to the resource consumption parameters of the source host in M service scenarios in the N service scenarios and the parameter of the optional hardware specification comprises:
respectively calculating a performance evaluation value of the hardware specification of the source end host and a performance evaluation value of the selectable hardware specification under each service scene in the M service scenes; the performance evaluation value of the hardware specification of the source end host is obtained by calculation according to the resource consumption parameter under the service scene and the grade value of the hardware specification of the source end host; the performance evaluation value of the selectable hardware specification is calculated according to the resource consumption parameter under the service scene and the evaluation value of the selectable hardware specification;
respectively calculating a first reference value under each service scene in the M service scenes, wherein the first reference value is obtained by calculation according to the performance evaluation value of the selectable hardware specification under the service scene and the performance evaluation value of the hardware specification of the source end host under the service scene;
if the first reference value in a preset proportion of the M service scenes is greater than or equal to a threshold, the selectable hardware specification meets the requirement of the target load, and the threshold is calculated according to a difference value between the load of the source end host and the target load.
4. The method of claim 2, wherein the determining whether the optional hardware specification meets the requirement of the target load according to the resource consumption parameter of the source host in M of the N service scenarios and the parameter of the optional hardware specification comprises:
respectively calculating the resource consumption of the source end host in each service scene in the M service scenes according to the resource consumption parameters of the source end host in the M service scenes;
respectively calculating a second reference value in each service scene of the M service scenes, wherein the second reference value is calculated according to the resource consumption of the source end host in the service scene and the parameter of the selectable hardware specification;
if the second reference value in the preset proportion of the M service scenes is smaller than or equal to the target load, the selectable hardware specification meets the requirement of the target load.
5. The method of any of claims 2-4, wherein the performance parameters further include a load of the source host in each of the N traffic scenarios; the M service scenarios are service scenarios in which the load of the source end host is greater than or equal to a preset load threshold among the N service scenarios.
6. The method according to any of claims 1-4, wherein the hardware specification comprises one or more of the following parameters of one or more hardware units in the host:
type, number, size.
7. The method of claim 6, wherein the hardware unit comprises one or more of the following hardware:
CPU, internal memory and hard disk.
8. The method according to any of claims 2-4, wherein the resource consumption parameters comprise one or more of: resource consumption rate, resource consumption amount.
9. An electronic device, characterized in that the electronic device comprises:
the device comprises an acquisition unit, a processing unit and a processing unit, wherein the acquisition unit is used for acquiring performance parameters of a source end host, and the performance parameters comprise hardware specifications required by the source end host;
a determining unit, configured to determine, according to the performance parameter acquired by the acquisition unit, a service scenario of the source end host, and a target load of a destination end host, a hardware specification required by the destination end host in the service scenario;
a sending unit, configured to send a hardware specification required by the destination host to a destination platform where the destination host is located, so that the destination platform creates the destination host according to the hardware specification required by the destination host; and sending a migration instruction to the source end host, wherein the migration instruction is used for indicating the source end host to migrate the data of the source end host to the destination end host.
10. The electronic device of claim 9, wherein the performance parameters further comprise resource consumption parameters for N traffic scenarios; the resource consumption parameter is used for representing the resource consumed by the source host under the service scene; said N is greater than or equal to 1;
the determining unit is specifically configured to:
modifying the hardware specification parameters of the source end host to obtain an optional hardware specification;
judging whether the optional hardware specification meets the requirement of the target load according to resource consumption parameters of the source end host under M service scenes in the N service scenes and parameters of the optional hardware specification; said M is less than or equal to N;
and if the selectable hardware specification meets the requirement of the target load, taking the selectable hardware specification as the hardware specification of the destination host.
11. The electronic device of claim 10, wherein the performance parameters further include a load of the source host in each of the N traffic scenarios;
the determining unit is specifically configured to:
respectively calculating a performance evaluation value of the hardware specification of the source end host and a performance evaluation value of the selectable hardware specification under each service scene in the M service scenes; the performance evaluation value of the hardware specification of the source end host is obtained by calculation according to the resource consumption parameter under the service scene and the grade value of the hardware specification of the source end host; the performance evaluation value of the selectable hardware specification is calculated according to the resource consumption parameter under the service scene and the evaluation value of the selectable hardware specification;
respectively calculating a first reference value under each service scene in the M service scenes, wherein the first reference value is obtained by calculating a performance evaluation value of the selectable hardware specification under the service scene and a performance evaluation value of the hardware specification of the source end host under the service scene;
if the first reference value in a preset proportion of the M service scenes is greater than or equal to a threshold, the selectable hardware specification meets the requirement of the target load, and the threshold is calculated according to a difference between the load of the source end host and the target load.
12. The electronic device according to claim 10, wherein the determining unit is specifically configured to:
respectively calculating the resource consumption of the source end host in each service scene in the M service scenes according to the resource consumption parameters of the source end host in the M service scenes;
respectively calculating a second reference value in each service scene of the M service scenes, wherein the second reference value is calculated according to the resource consumption of the source end host in the service scene and the parameter of the selectable hardware specification;
if the second reference value in the preset proportion of the M service scenes is smaller than or equal to the target load, the selectable hardware specification meets the requirement of the target load.
13. The electronic device of any of claims 10-12, wherein the performance parameters further include the source host load for each of the N traffic scenarios; the M service scenarios are service scenarios in which the load of the source end host is greater than or equal to a preset load threshold in the N service scenarios.
14. The electronic device of any of claims 9-12, wherein the hardware specification comprises one or more of the following parameters for one or more hardware units in the host:
type, number, size.
15. The electronic device of claim 14, wherein the hardware unit comprises one or more of the following hardware:
CPU, internal memory and hard disk.
16. The electronic device of any of claims 10-12, wherein the resource consumption parameters include one or more of: resource consumption rate, resource consumption amount.
17. An electronic device, comprising a memory for storing a computer program and a processor for calling the computer program to perform the host relocation method according to any one of claims 1-8.
18. A computer-readable storage medium, in which a computer program is stored, which, when run on a processor, causes the processor to execute the host relocation method according to any one of claims 1 to 8.
CN201910065533.0A 2019-01-23 2019-01-23 Host computer relocation method and device Active CN109857521B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201910065533.0A CN109857521B (en) 2019-01-23 2019-01-23 Host computer relocation method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201910065533.0A CN109857521B (en) 2019-01-23 2019-01-23 Host computer relocation method and device

Publications (2)

Publication Number Publication Date
CN109857521A CN109857521A (en) 2019-06-07
CN109857521B true CN109857521B (en) 2021-06-01

Family

ID=66895812

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201910065533.0A Active CN109857521B (en) 2019-01-23 2019-01-23 Host computer relocation method and device

Country Status (1)

Country Link
CN (1) CN109857521B (en)

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101739287A (en) * 2008-11-13 2010-06-16 国际商业机器公司 Device, system and method for managing virtual machines
CN101937357A (en) * 2009-07-01 2011-01-05 华为技术有限公司 Virtual machine migration decision-making method, device and system
CN102609361A (en) * 2012-01-16 2012-07-25 北京邮电大学 Method and device for transferring storage data of virtual machine
CN104102523A (en) * 2013-04-03 2014-10-15 华为技术有限公司 Method for migrating virtual machine and resource scheduling platform

Family Cites Families (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US9317314B2 (en) * 2010-06-29 2016-04-19 Microsoft Techology Licensing, Llc Techniques for migrating a virtual machine using shared storage

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101739287A (en) * 2008-11-13 2010-06-16 国际商业机器公司 Device, system and method for managing virtual machines
CN101937357A (en) * 2009-07-01 2011-01-05 华为技术有限公司 Virtual machine migration decision-making method, device and system
CN102609361A (en) * 2012-01-16 2012-07-25 北京邮电大学 Method and device for transferring storage data of virtual machine
CN104102523A (en) * 2013-04-03 2014-10-15 华为技术有限公司 Method for migrating virtual machine and resource scheduling platform

Also Published As

Publication number Publication date
CN109857521A (en) 2019-06-07

Similar Documents

Publication Publication Date Title
CN110063051B (en) System and method for reconfiguring server and server
TWI752066B (en) Method and device for processing read and write requests
CA2978889C (en) Opportunistic resource migration to optimize resource placement
US10628225B2 (en) Resource configuration system, resource configuration method and resource configuration program for selecting a computational resource and selecting a provisioning method
US20200364608A1 (en) Communicating in a federated learning environment
US10324754B2 (en) Managing virtual machine patterns
US10057187B1 (en) Dynamic resource creation to connect client resources in a distributed system
US20140025890A1 (en) Methods and structure for improved flexibility in shared storage caching by multiple systems operating as multiple virtual machines
US10616134B1 (en) Prioritizing resource hosts for resource placement
CN109417488A (en) The method and apparatus of virtual network function resource management
CN110291502A (en) A kind of scheduling accelerates the method, apparatus and acceleration system of resource
CN102413183B (en) Cloud intelligence switch and processing method and system thereof
US9755986B1 (en) Techniques for tightly-integrating an enterprise storage array into a distributed virtualized computing environment
CN103455363A (en) Command processing method, device and physical host of virtual machine
US20190156245A1 (en) Platform as a service cloud server and machine learning data processing method thereof
US9971785B1 (en) System and methods for performing distributed data replication in a networked virtualization environment
CN108228099B (en) Data storage method and device
CN109412865A (en) A kind of virtual network resource allocation method, system and electronic equipment
CN111247508A (en) Network storage architecture
CN109857521B (en) Host computer relocation method and device
CN110515540B (en) Method and device for topology of hard disk
CN107562510B (en) Management method and management equipment for application instances
US11307889B2 (en) Schedule virtual machines
CN114281516A (en) Resource allocation method and device based on NUMA attribute
US20160378510A1 (en) Configuration Method, Data Exchange Method and Server 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