Computing resource selection method and system and electronic equipment

文档序号:7305 发布日期:2021-09-17 浏览:122次 中文

1. A computing resource selection method, comprising:

constructing a computing resource selection model, wherein the computing resource selection model comprises a target layer, a criterion layer and a scheme layer, the target layer is an optimal computing resource, and the scheme layer comprises a plurality of application self-containing units which are used as optimal computing resource alternatives; the criteria layer includes a set of characteristics determined from the hosting unit from the plurality of applications that affect optimal computing resource selection;

generating a criterion layer judgment matrix and a plurality of scheme layer judgment matrices according to the computing resource selection model; and the number of the first and second groups,

and generating an optimal computing resource selection scheme according to the criterion layer judgment matrix and the scheme layer judgment matrixes.

2. The computing resource selection method according to claim 1, wherein the plurality of application self-contained units are bare metal servers and containers, or bare metal servers and virtual machines;

if the plurality of application self-containing units are bare metal servers and containers, elements of the feature set comprise isolation features, flexible features and portable features;

if the plurality of application self-contained units are bare metal servers and virtual machines, the elements of the feature set comprise isolation features, hardware access features and delay features.

3. The computing resource selection method of claim 2, wherein the criterion layer decision matrix is generated by the following equation (1):

wherein A is0Representing a criterion layer judgment matrix;

when the plurality of application self-contained units are bare metal servers and containers, at A0In, x1Weight of influence, x, of the 1 st element isolation property of the property set in the criteria layer on the target layer2Weight of influence, x, of the flexible property of the 2 nd element of the property set in the criteria layer on the target layer3The influence weight of the 3 rd element portable characteristic representing the characteristic set in the criterion layer on the target layer;

when the plurality of application self-contained units are bare metal servers and virtual machines, at A0In, x1Weight of influence, x, of the 1 st element isolation property of the property set in the criteria layer on the target layer2Weight of influence, x, of the 2 nd element hardware access characteristic representing the set of characteristics in the criteria layer on the target layer3The influence weight of the 3 rd element delay characteristic representing the characteristic set in the criterion layer on the target layer.

4. The computing resource selection method according to claim 2, wherein the plurality of scheme layer decision matrices are generated by the following formula (2):

wherein when the plurality of application self-contained units are bare metal servers and containers, ATRepresenting a scheme layer decision matrix corresponding to the 1 st element isolation property in the criterion layer, AZRepresenting a scheme layer decision matrix corresponding to the 2 nd element flexibility characteristic in the criterion layer, AGThe representation corresponds to the 3 rd element portability property in the criterion layerThe scheme layer judgment matrix of (1); in ATIn, y1,TRepresenting the weight of the impact of the bare metal server of the 1 st element in the scheme layer on the isolation characteristics of the 1 st element in the criterion layer, y2,TRepresenting the influence weight of the 2 nd element container in the scheme layer on the 1 st element isolation characteristic in the criterion layer; in AZIn, y1,ZRepresenting the influence weight, y, of the bare metal server of the 1 st element in the scheme layer on the flexible property of the 2 nd element in the criterion layer2,ZRepresenting the influence weight of the 2 nd element container in the scheme layer on the flexibility characteristic of the 2 nd element in the criterion layer; in AGIn, y1,GRepresents the weight of the influence of the bare metal server of the 1 st element in the scheme layer on the portability of the 3 rd element in the criterion layer, y2,GRepresenting the influence weight of the 2 nd element container in the scheme layer on the portability of the 3 rd element in the criterion layer;

when the plurality of application self-accommodating units are bare metal servers and virtual machines, ATRepresenting a scheme layer decision matrix corresponding to the 1 st element isolation property in the criterion layer, AZRepresenting a scheme layer decision matrix corresponding to the 2 nd element hardware access characteristic in the criteria layer, AGRepresenting a scheme layer judgment matrix corresponding to the 3 rd element delay characteristic in the criterion layer; in ATIn, y1,TRepresenting the weight of the impact of the bare metal server of the 1 st element in the scheme layer on the isolation characteristics of the 1 st element in the criterion layer, y2,TRepresenting the influence weight of the 2 nd element virtual machine in the scheme layer on the 1 st element isolation characteristic in the criterion layer; in AZIn, y1,ZWeight of influence, y, of bare metal server of element 1 in scheme layer on hardware access characteristic of element 2 in criterion layer2,ZRepresenting the influence weight of the 2 nd element virtual machine in the scheme layer on the 2 nd element hardware access characteristic in the criterion layer; in AGIn, y1,GRepresents the weight of the influence of the bare metal server of the 1 st element in the scheme layer on the delay characteristic of the 3 rd element in the criterion layer, y2,GRepresenting the influence weight of the 2 nd element virtual machine in the scheme layer on the 3 rd element delay characteristic in the criterion layer.

5. The method for computing resource selection according to any one of claims 1 to 4, wherein the generating an optimal computing resource selection solution according to the criterion layer determination matrix and the plurality of solution layer determination matrices specifically includes:

generating a first eigenvector corresponding to the maximum eigenvalue of the criterion layer judgment matrix;

generating a plurality of second eigenvectors respectively corresponding to the maximum eigenvalues of the plurality of scheme layer judgment matrixes;

generating an influence weight vector of a scheme layer on a target layer according to the first feature vector and the plurality of second feature vectors, wherein the influence weight vector of the scheme layer on the target layer comprises influence weights of all the application self-contained units on optimal computing resources;

and selecting the application self-containing unit corresponding to the maximum weight value from the influence weights of the application self-containing units on the optimal computing resource as the optimal computing resource.

6. The computing resource selection method of claim 5,

if the plurality of application self-containing units are bare metal servers and containers, the influence weight vector of the scheme layer on the target layer comprises the influence weight of the bare metal servers on the optimal computing resources and the influence weight of the containers on the optimal computing resources;

the selecting the application self-containing unit corresponding to the maximum weight value from the influence weights of the application self-containing units on the optimal computing resource as the optimal computing resource comprises the following steps:

judging whether the influence weight of the bare metal server on the optimal computing resource is greater than the influence weight of the container on the optimal computing resource, if so, selecting the bare metal server as the optimal computing resource, and otherwise, selecting the container as the optimal computing resource;

if the plurality of application self-containing units are bare metal servers and virtual machines, the influence weight vector of the scheme layer on the target layer comprises the influence weight of the bare metal servers on the optimal computing resources and the influence weight of the virtual machines on the optimal computing resources;

the selecting the application self-containing unit corresponding to the maximum weight value from the influence weights of the application self-containing units on the optimal computing resource as the optimal computing resource comprises the following steps:

and judging whether the influence weight of the bare metal server on the optimal computing resource is greater than the influence weight of the virtual machine on the optimal computing resource, if so, selecting the bare metal server as the optimal computing resource, and otherwise, selecting the virtual machine as the optimal computing resource.

7. A computing resource selection system, comprising:

a construction module configured to construct a computing resource selection model, the computing resource selection model including a target layer, a criterion layer, and a solution layer, the target layer being an optimal computing resource, the solution layer including a plurality of application self-contained units as optimal computing resource alternatives; the criteria layer includes a set of characteristics determined from the hosting unit from the plurality of applications that affect optimal computing resource selection;

a first generation module configured to generate a criteria layer decision matrix and a plurality of solution layer decision matrices from the computing resource selection model;

a second generation module configured to generate an optimal computing resource selection scheme based on the criteria layer decision matrix and the plurality of scheme layer decision matrices.

8. The computing resource selection system of claim 7,

the application self-containing unit in the computing resource selection model constructed by the construction module is a bare metal server and a container, or the bare metal server and a virtual machine;

if the plurality of application self-containing units are bare metal servers and containers, elements of the feature set comprise isolation features, flexible features and portable features;

if the plurality of application self-contained units are bare metal servers and virtual machines, the elements of the feature set comprise isolation features, hardware access features and delay features.

9. The computing resource selection system of claim 8, wherein the second generation module comprises:

a first generating unit configured to generate a first eigenvector corresponding to a maximum eigenvalue of the criterion layer determination matrix;

a second generation unit configured to generate a plurality of second eigenvectors corresponding to the maximum eigenvalues of the plurality of scheme layer determination matrices, respectively;

a third generating unit, configured to generate an influence weight vector of the solution layer on the target layer according to the first eigenvector and the plurality of second eigenvectors, wherein the influence weight vector of the solution layer on the target layer comprises influence weights of the self-contained units on the optimal computing resources;

and the selecting unit is arranged to select the application self-containing unit corresponding to the maximum weight value from the influence weights of the application self-containing units on the optimal computing resource as the optimal computing resource.

10. An electronic device comprising a memory and a processor, the memory having a computer program stored therein, the processor performing the computing resource selection method of any of claims 1-6 when the processor executes the computer program stored by the memory.

Background

The container and the virtual machine can isolate the application program and the relevance thereof, thereby constructing a set of self-contained units capable of running everywhere. Both the container and the virtual machine are free from the need for physical hardware, so that a user can more efficiently use computing resources. Specifically, the container is a package called container mirror image, in which all dependencies, class libraries, other binary files, configuration files and the like required by the application are uniformly typed into the package except the application program; after the container layer installation is completed, container instances can be allocated from the system available computing resources, and each containerized application shares the same operating system. For the virtual machine, the virtual machine depends on the hypervisor (virtual machine manager), and when the hypervisor is installed, the hypervisor allocates virtual machine instances from the available computing resources of the system, and each virtual machine can obtain a unique operating system and application program. However, with the development of business, the performance of the container and the virtual machine cannot completely meet the business requirements of the enterprise, the original core application of the enterprise does not want to be adjusted too much based on the container or the virtual machine, and meanwhile, the performance and the stability have higher requirements, and the physical machine service is expected to be used like the cloud host service, so that the flexible use of resources and the flexible configuration of a network are realized. To meet the complex demands of users, Bare Metal servers (barrel Metal servers) have been produced. The bare metal server has the appearance of a virtual machine and the heart of a physical machine, and has the advantages of extreme performance, minute-level delivery capacity, physical isolation, full-automatic operation and maintenance and the like.

Although bare metal is more suitable than a container or a virtual machine in many scenes, at present, the flexibility is not enough, and in practical application, bare metal service and the container or the virtual machine can be complementary technologies, namely, the bare metal and the container or the virtual machine can coexist in the same data center and can coexist for a long time. In the same data center, how to select the optimal computing resource from the container and the bare metal server or the virtual machine and the bare metal server according to the traffic characteristics becomes an urgent problem to be solved.

Disclosure of Invention

The present disclosure provides a computing resource selection method, system and electronic device, which can select a scheme corresponding to an optimal computing resource from a bare metal server and a virtual machine, or from the bare metal server and the virtual machine, according to a traffic characteristic.

In a first aspect, an embodiment of the present disclosure provides a computing resource selection method, including:

constructing a computing resource selection model, wherein the computing resource selection model comprises a target layer, a criterion layer and a scheme layer, the target layer is an optimal computing resource, and the scheme layer comprises a plurality of application self-containing units which are used as optimal computing resource alternatives; the criteria layer includes a set of characteristics determined from the hosting unit from the plurality of applications that affect optimal computing resource selection;

generating a criterion layer judgment matrix and a plurality of scheme layer judgment matrices according to the computing resource selection model; and the number of the first and second groups,

and generating an optimal computing resource selection scheme according to the criterion layer judgment matrix and the scheme layer judgment matrixes.

Further, the plurality of application self-containing units are bare metal servers and containers, or bare metal servers and virtual machines;

if the plurality of application self-containing units are bare metal servers and containers, elements of the feature set comprise isolation features, flexible features and portable features;

if the plurality of application self-contained units are bare metal servers and virtual machines, the elements of the feature set comprise isolation features, hardware access features and delay features.

Further, the criterion layer judgment matrix is generated by the following formula (1):

wherein A is0Representing a criterion layer judgment matrix;

when the plurality of application self-contained units are bare metal servers and containers, at A0In, x1Weight of influence, x, of the 1 st element isolation property of the property set in the criteria layer on the target layer2Weight of influence, x, of the flexible property of the 2 nd element of the property set in the criteria layer on the target layer3The influence weight of the 3 rd element portable characteristic representing the characteristic set in the criterion layer on the target layer;

when the plurality of application self-contained units are bare metal servers and virtual machines, at A0In, x1Weight of influence, x, of the 1 st element isolation property of the property set in the criteria layer on the target layer2Weight of influence, x, of the 2 nd element hardware access characteristic representing the set of characteristics in the criteria layer on the target layer3The influence weight of the 3 rd element delay characteristic representing the characteristic set in the criterion layer on the target layer.

Further, the plurality of solution layer decision matrices are generated by the following formula (2):

wherein when the plurality of application self-contained units are bare metal servers and containers, ATRepresenting a scheme layer decision matrix corresponding to the 1 st element isolation property in the criterion layer, AZRepresenting a scheme layer decision matrix corresponding to the 2 nd element flexibility characteristic in the criterion layer, AGRepresenting a scheme layer judgment matrix corresponding to the 3 rd element portability characteristic in the criterion layer; in ATIn, y1,TRepresenting the weight of the impact of the bare metal server of the 1 st element in the scheme layer on the isolation characteristics of the 1 st element in the criterion layer, y2,TRepresenting the influence weight of the 2 nd element container in the scheme layer on the 1 st element isolation characteristic in the criterion layer; in AZIn, y1,ZRepresenting the influence weight, y, of the bare metal server of the 1 st element in the scheme layer on the flexible property of the 2 nd element in the criterion layer2,ZRepresenting the influence weight of the 2 nd element container in the scheme layer on the 2 nd element flexible property in the criterion layer; in AGIn, y1,GRepresents the weight of the influence of the bare metal server of the 1 st element in the scheme layer on the portability of the 3 rd element in the criterion layer, y2,GRepresenting the influence weight of the 2 nd element container in the scheme layer on the portability of the 3 rd element in the criterion layer;

when the plurality of application self-accommodating units are bare metal servers and virtual machines, ATRepresenting a scheme layer decision matrix corresponding to the 1 st element isolation property in the criterion layer, AZRepresenting a scheme layer decision matrix corresponding to the 2 nd element hardware access characteristic in the criteria layer, AGRepresenting a scheme layer judgment matrix corresponding to the 3 rd element delay characteristic in the criterion layer; in ATIn, y1,TRepresenting the weight of the impact of the bare metal server of the 1 st element in the scheme layer on the isolation characteristics of the 1 st element in the criterion layer, y2,TRepresenting the influence weight of the 2 nd element virtual machine in the scheme layer on the 1 st element isolation characteristic in the criterion layer; in AZIn, y1,ZWeight of influence, y, of bare metal server of element 1 in scheme layer on hardware access characteristic of element 2 in criterion layer2,ZRepresenting the influence weight of the 2 nd element virtual machine in the scheme layer on the 2 nd element hardware access characteristic in the criterion layer; in AGIn, y1,GRepresents the weight of the influence of the bare metal server of the 1 st element in the scheme layer on the delay characteristic of the 3 rd element in the criterion layer, y2,GRepresenting the influence weight of the 2 nd element virtual machine in the scheme layer on the 3 rd element delay characteristic in the criterion layer.

Further, the generating an optimal computing resource selection scheme according to the criterion layer judgment matrix and the plurality of scheme layer judgment matrices specifically includes:

generating a first eigenvector corresponding to the maximum eigenvalue of the criterion layer judgment matrix;

generating a plurality of second eigenvectors respectively corresponding to the maximum eigenvalues of the plurality of scheme layer judgment matrixes;

generating an influence weight vector of a scheme layer on a target layer according to the first feature vector and the plurality of second feature vectors, wherein the influence weight vector of the scheme layer on the target layer comprises influence weights of all the application self-contained units on optimal computing resources;

and selecting the application self-containing unit corresponding to the maximum weight value from the influence weights of the application self-containing units on the optimal computing resource as the optimal computing resource.

Further, if the plurality of application self-containing units are bare metal servers and containers, the influence weight vector of the scheme layer on the target layer includes influence weights of the bare metal servers on the optimal computing resources and influence weights of the containers on the optimal computing resources;

the selecting the application self-containing unit corresponding to the maximum weight value from the influence weights of the application self-containing units on the optimal computing resource as the optimal computing resource comprises the following steps:

judging whether the influence weight of the bare metal server on the optimal computing resource is greater than the influence weight of the container on the optimal computing resource, if so, selecting the bare metal server as the optimal computing resource, and otherwise, selecting the container as the optimal computing resource;

if the plurality of application self-containing units are bare metal servers and virtual machines, the influence weight vector of the scheme layer on the target layer comprises the influence weight of the bare metal servers on the optimal computing resources and the influence weight of the virtual machines on the optimal computing resources;

the selecting the application self-containing unit corresponding to the maximum weight value from the influence weights of the application self-containing units on the optimal computing resource as the optimal computing resource comprises the following steps:

and judging whether the influence weight of the bare metal server on the optimal computing resource is greater than the influence weight of the virtual machine on the optimal computing resource, if so, selecting the bare metal server as the optimal computing resource, and otherwise, selecting the virtual machine as the optimal computing resource.

In a second aspect, an embodiment of the present disclosure provides a computing resource selection system, including:

a construction module configured to construct a computing resource selection model, the computing resource selection model including a target layer, a criterion layer, and a solution layer, the target layer being an optimal computing resource, the solution layer including a plurality of application self-contained units as optimal computing resource alternatives; the criteria layer includes a set of characteristics determined from the hosting unit from the plurality of applications that affect optimal computing resource selection;

a first generation module configured to generate a criteria layer decision matrix and a plurality of solution layer decision matrices from the computing resource selection model;

a second generation module configured to generate an optimal computing resource selection scheme based on the criteria layer decision matrix and the plurality of scheme layer decision matrices.

Further, the application self-containing unit in the computing resource selection model constructed by the construction module 11 is a bare metal server and a container, or a bare metal server and a virtual machine;

if the plurality of application self-containing units are bare metal servers and containers, elements of the feature set comprise isolation features, flexible features and portable features;

if the plurality of application self-contained units are bare metal servers and virtual machines, the elements of the feature set comprise isolation features, hardware access features and delay features.

Further, the second generating module includes:

a first generating unit configured to generate a first eigenvector corresponding to a maximum eigenvalue of the criterion layer determination matrix;

a second generation unit configured to generate a plurality of second eigenvectors corresponding to the maximum eigenvalues of the plurality of scheme layer determination matrices, respectively;

a third generating unit, configured to generate an influence weight vector of the solution layer on the target layer according to the first eigenvector and the plurality of second eigenvectors, wherein the influence weight vector of the solution layer on the target layer comprises influence weights of the self-contained units on the optimal computing resources;

and the selecting unit is arranged to select the application self-containing unit corresponding to the maximum weight value from the influence weights of the application self-containing units on the optimal computing resource as the optimal computing resource.

In a third aspect, an embodiment of the present disclosure provides an electronic device, including a memory and a processor, where the memory stores a computer program, and when the processor runs the computer program stored in the memory, the processor executes the computing resource selection method according to any one of the first aspect.

Has the advantages that:

according to the computing resource selection method, the computing resource selection system and the electronic equipment, a computing resource selection model is constructed, the computing resource selection model comprises a target layer, a criterion layer and a scheme layer, the target layer is an optimal computing resource, and the scheme layer comprises a plurality of application self-containing units which are used as optimal computing resource alternatives; the criteria layer includes a set of characteristics determined from the hosting unit from the plurality of applications that affect optimal computing resource selection; then generating a criterion layer judgment matrix and a plurality of scheme layer judgment matrices according to the computing resource selection model; and generating an optimal computing resource selection scheme according to the criterion layer judgment matrix and the scheme layer judgment matrices. Therefore, one application self-containing unit is selected as the optimal computing resource based on the analytic hierarchy process in the data center with a plurality of application self-containing units coexisting according to the flow characteristics.

Drawings

FIG. 1 is a flowchart illustrating a computing resource selection method according to an embodiment of the disclosure;

FIG. 2 is a layer structure diagram of a computing resource selection model according to an embodiment of the present disclosure;

FIG. 3 is a layer structure diagram of another computing resource selection model according to an embodiment of the present disclosure;

FIG. 4 is an architecture diagram of a computing resource selection system according to a second embodiment of the disclosure;

fig. 5 is an architecture diagram of an electronic device according to a third embodiment of the disclosure.

Detailed Description

In order to make the technical solutions of the present disclosure better understood by those skilled in the art, the present disclosure is further described in detail below with reference to the accompanying drawings and examples.

In which the terminology used in the embodiments of the disclosure is for the purpose of describing particular embodiments only and is not intended to be limiting of the disclosure. As used in the disclosed embodiments and the appended claims, the singular forms "a," "an," and "the" are intended to include the plural forms as well, unless the context clearly indicates otherwise.

As more and more applications are developed and deployed based on containers, the tendency to use physical servers becomes greater. On one hand, bare metal can be higher along with the continuous strength of the container technology, on the other hand, hardware is in a new development stage, various computing technologies such as GPU, FPGA and ASIC are arranged in a hundred flowers, the traditional virtualization technology is relatively lagged in development, and the bare metal is in a better market opportunity. However, the bare metal at the present stage does not reach a more ideal state, and the greatest problem is insufficient flexibility. So bare metal and container or virtual machine co-exist for a long time. In the same data center, how to select the optimal computing resource from the container and the bare metal server or the virtual machine and the bare metal server according to the traffic characteristics becomes an urgent problem to be solved.

The following describes the technical solutions of the present disclosure and how to solve the above problems in detail with specific examples. The following several specific embodiments may be combined with each other, and details of the same or similar concepts or processes may not be repeated in some embodiments.

Fig. 1 is a schematic flowchart of a computing resource selection method provided in an embodiment of the present disclosure, and is applied to a scenario in which a same data center or a cloud server has multiple application self-contained units, such as a scenario in which a bare metal server and a container coexist, or a scenario in which a bare metal server and a virtual machine coexist, as shown in fig. 1, where the computing resource selection method includes:

step S101: constructing a computing resource selection model, wherein the computing resource selection model comprises a target layer, a criterion layer and a scheme layer, the target layer is an optimal computing resource, and the scheme layer comprises a plurality of application self-containing units which are used as optimal computing resource alternatives; the criteria layer includes a set of characteristics determined from the hosting unit from the plurality of applications that affect optimal computing resource selection;

step S102: generating a criterion layer judgment matrix and a plurality of scheme layer judgment matrices according to the computing resource selection model; and the number of the first and second groups,

step S103: and generating an optimal computing resource selection scheme according to the criterion layer judgment matrix and the scheme layer judgment matrixes.

The computing resource selection method of this embodiment is based on an Analytic Hierarchy Process (AHP), which is a qualitative and quantitative decision analysis method for solving a multi-objective complex problem. The method combines quantitative analysis and qualitative analysis, judges the relative importance degree between standards whether each measurement target can be realized or not by using the experience of a decision maker, reasonably gives the weight of each standard of each decision scheme, and uses the weight to calculate the quality sequence of each scheme, thereby being effectively applied to the situations which are difficult to solve by using a quantitative method. The method comprises the steps that firstly, a computing resource selection model is built, a target layer of the computing network selection model is an optimal computing resource, a scheme layer comprises a plurality of application self-containing units which are used as optimal computing resource candidates, and the application self-containing units are used for isolating application programs and relevance thereof on a data center or a server, so that a set of units capable of running anywhere, such as a container, a virtual machine and a bare metal server, is built; determining a scheme layer as an alternative of the optimal computing resource according to the actual deployment situation, wherein the criterion layer is a target layer, a criterion layer and a scheme layer from top to bottom according to factors and decision criteria considered by elements of the scheme layer in determining the target layer; generating a criterion layer judgment matrix and a scheme layer judgment matrix according to the computing resource selection model, wherein the criterion layer judgment matrix represents the weight sequencing of each element of the criterion layer to the element of the target layer, the target layer only has one element, so that the criterion layer judgment matrix has only one meaning, the meaning of the scheme layer judgment matrix represents the weight sequencing of each element of the scheme layer to each element of the criterion layer, and the number of the scheme layer judgment matrices is the number of the elements of the criterion layer; each layer element needs to list two-by-two comparison judgment matrixes for each element of the upper layer. And calculating the composite weight of each layer of element to the optimal computing resource, and performing total sequencing to determine the importance degree of each element at the bottommost layer in the hierarchical structure diagram in a total target. According to the embodiment of the disclosure, the most suitable computing resource scheme can be selected from the containing units according to the flow characteristics from each application of the scheme layer, and becomes the optimal computing resource.

Further, the plurality of application self-containing units are bare metal servers and containers, or bare metal servers and virtual machines;

if the plurality of application self-containing units are bare metal servers and containers, elements of the feature set comprise isolation features, flexible features and portable features;

if the plurality of application self-contained units are bare metal servers and virtual machines, the elements of the feature set comprise isolation features, hardware access features and delay features. The scheme layer can be a bare metal server and a virtual machine, or the bare metal server and the virtual machine;

fig. 2 is a layer structure diagram of a computing resource selection model provided in an embodiment of the present disclosure, and as shown in fig. 2, when the application self-accommodating unit is a bare metal server and a container, elements of a feature set of a criterion layer include an isolation feature, a flexible feature, and a portable feature, and the isolation feature, the flexible feature, and the portable feature are selected as factors and a decision criterion for computing resource selection consideration according to differentiated features of the bare metal server and the container;

fig. 3 is a layer structure diagram of another computing resource selection model provided in this disclosure, and as shown in fig. 3, when the application self-accommodating unit is a bare metal server and a virtual machine, elements of a feature set of a criterion layer include an isolation feature, a hardware access feature, and a delay feature, and according to differentiated features of the bare metal server and the virtual machine, the isolation feature, a flexible feature, and a portable feature are selected as factors and decision criteria for computing resource selection consideration. The characteristic set of the criterion layer is determined according to the differentiated features of the scheme layer, so that the emphasis on selecting the target layer can be more emphasized, and the optimal computing resource selected from the scheme layer can better meet the expected target.

Further, the criterion layer judgment matrix is generated by the following formula (1):

wherein A is0Representing a criterion layer judgment matrix;

when the plurality of application self-contained units are bare metal servers and containers, at A0In, x1Weight of influence, x, of the 1 st element isolation property of the property set in the criteria layer on the target layer2Weight of influence, x, of the flexible property of the 2 nd element of the property set in the criteria layer on the target layer3The influence weight of the 3 rd element portable characteristic representing the characteristic set in the criterion layer on the target layer;

when the plurality of application self-contained units are bare metal servers and virtual machines, at A0In, x1Weight of influence, x, of the 1 st element isolation property of the property set in the criteria layer on the target layer2Weight of influence, x, of the 2 nd element hardware access characteristic representing the set of characteristics in the criteria layer on the target layer3The influence weight of the 3 rd element delay characteristic representing the characteristic set in the criterion layer on the target layer.

The criterion layer judgment matrix represents the weight sorting of each element of the criterion layer to the element of the target layer. Since the target layer has only one element, the criterion layer decision matrix has only one, i.e. one

When the application self-contained units are bare metal servers and containers, T, Z, G are expressed as isolation, flexibility and portability, x, respectively1Weight of influence, x, of the 1 st element isolation property on the optimal computing resource representing the property set in the criterion layer2Weight of influence, x, of the flexible property of the 2 nd element representing the property set in the criterion layer on the optimal computing resource3A weight representing the influence of the portability characteristic of the 3 rd element of the characteristic set in the criterion layer on the optimal computing resource; x is the number of1、x2And x3The value is a preset value, and can be preset according to the actual application scene.

When the application self-contained unit is a bare metal server and a virtual machine, T, Z, G represents isolation property, hardware access property and delay property, x1Weight of influence, x, of the 1 st element isolation property on the optimal computing resource representing the property set in the criterion layer2Weight of influence, x, of the 2 nd element hardware access characteristic representing the set of characteristics in the criteria layer on the optimal computing resource3The influence weight of the delay characteristic of the 3 rd element representing the characteristic set in the criterion layer on the optimal computing resource.

Furthermore, consistency ratio can be introduced, and the inconsistency degree of the layer judgment matrix is judged by alignment.

Defining a consistency indexn is the number of elements of the criterion layer, lambda is the maximum characteristic root, and CI is 0, so that the consistency is complete; CI is close to 0, and the consistency is satisfactory; the larger the CI, the more severe the inconsistency. Defining a consistency ratio: CR ═ CI/RI, RI can be looked upObtaining, if n is 3, RI is 0.58; it is generally considered that the consistency ratio CR<At 0.1, the degree of inconsistency of A was considered to be within the allowable range, and satisfactory consistency was obtained, and the consistency was checked. Its normalized feature vector can be used as weight vector, otherwise it should be reconstructed into comparison matrix A, pair aijTo be adjusted.

Further, the plurality of solution layer decision matrices are generated by the following formula (2):

wherein when the plurality of application self-contained units are bare metal servers and containers, ATRepresenting a scheme layer decision matrix corresponding to the 1 st element isolation property in the criterion layer, AZRepresenting a scheme layer decision matrix corresponding to the 2 nd element flexibility characteristic in the criterion layer, AGRepresenting a scheme layer judgment matrix corresponding to the 3 rd element portability characteristic in the criterion layer; in ATIn, y1,TRepresenting the weight of the impact of the bare metal server of the 1 st element in the scheme layer on the isolation characteristics of the 1 st element in the criterion layer, y2,TRepresenting the influence weight of the 2 nd element container in the scheme layer on the 1 st element isolation characteristic in the criterion layer; in AZIn, y1,ZRepresenting the influence weight, y, of the bare metal server of the 1 st element in the scheme layer on the flexible property of the 2 nd element in the criterion layer2,ZRepresenting the influence weight of the 2 nd element container in the scheme layer on the 2 nd element flexible property in the criterion layer; in AGIn, y1,GRepresents the weight of the influence of the bare metal server of the 1 st element in the scheme layer on the portability of the 3 rd element in the criterion layer, y2,GRepresenting the influence weight of the 2 nd element container in the scheme layer on the portability of the 3 rd element in the criterion layer;

the multiple application self-accommodating units are bare metal servers and virtualWhen simulating a machine, ATRepresenting a scheme layer decision matrix corresponding to the 1 st element isolation property in the criterion layer, AZRepresenting a scheme layer decision matrix corresponding to the 2 nd element hardware access characteristic in the criteria layer, AGRepresenting a scheme layer judgment matrix corresponding to the 3 rd element delay characteristic in the criterion layer; in ATIn, y1,TRepresenting the weight of the impact of the bare metal server of the 1 st element in the scheme layer on the isolation characteristics of the 1 st element in the criterion layer, y2,TRepresenting the influence weight of the 2 nd element virtual machine in the scheme layer on the 1 st element isolation characteristic in the criterion layer; in AZIn, y1,ZWeight of influence, y, of bare metal server of element 1 in scheme layer on hardware access characteristic of element 2 in criterion layer2,ZRepresenting the influence weight of the 2 nd element virtual machine in the scheme layer on the 2 nd element hardware access characteristic in the criterion layer; in AGIn, y1,GRepresents the weight of the influence of the bare metal server of the 1 st element in the scheme layer on the delay characteristic of the 3 rd element in the criterion layer, y2,GRepresenting the influence weight of the 2 nd element virtual machine in the scheme layer on the 3 rd element delay characteristic in the criterion layer.

The meaning of the scheme layer judgment matrix represents the weight ordering of each element of the scheme layer to each element of the criterion layer. Since the rule layer has 3 elements, the scheme layer decision matrix has 3.

If the application self-containing unit is a bare metal server and a container, the scheme layer judgment matrix is

Wherein, yi,mWeight of influence of the ith element of the table scheme layer on the mth element of the criterion layer, yj,mThe impact weight of the jth element of the table scheme layer on the mth element of the criteria layer. i ═ 1, 2 (representing container and bare metal server); j ═ 2, 1 (representing bare metal server and container); m is T,Z、G;

In the above formula (4), C denotes a container, B denotes a bare metal server, ATRepresenting a scheme layer decision matrix corresponding to the 1 st element isolation property in the criterion layer, AZRepresenting a scheme layer decision matrix corresponding to the 2 nd element flexibility characteristic in the criterion layer, AGRepresenting a scheme layer decision matrix, y, corresponding to the 3 rd element portability feature in the criteria layer1,TWeight of influence, y, representing bare metal server on isolation characteristics2,TWeight of influence of the container on the isolation characteristic in the criterion layer, y1,ZRepresenting the weight of influence of bare metal servers on the Flexible Properties, y2,ZRepresenting the weight of the impact of a container on a flexible property, y1,GWeight of influence, y, on the portability of bare metal servers2,GRepresenting the weight of the container's impact on the portability;

further, in the above-mentioned case,

wherein, T0、Z0And G0The values are obtained according to the actual computing resource conditions and respectively correspond to the isolation characteristic, the flexible characteristic and the portable characteristic. Preferably, x1,TIs TC,x1,ZIs ZC,x1,GIs GC,x2,TIs TB,x2,ZIs ZB,x2,GIs GB,TC、ZC、GC、TB、ZBAnd GBAre preset values, which can be preset according to the actual application scene.

If the application self-containing unit is a bare metal server and a virtual machine, the scheme layer judgment matrix is

Wherein y isi,mWeight y of influence of ith element of table scheme layer on mth element of criterion layerj,mThe impact weight of the jth element of the table scheme layer on the mth element of the criteria layer. 1, 2 (representing bare metal server and virtual machine); j ═ 2, 1 (representing the virtual machine and bare metal server); m is T, Z, G;

in the above equation (6), V represents a virtual machine, B represents a bare metal server, ATRepresenting a scheme layer decision matrix corresponding to the isolation characteristic, AZRepresenting a scheme level decision matrix corresponding to a hardware access characteristic, AGIndicating a scheme layer decision matrix, y, corresponding to the delay characteristics1,TWeight of influence, y, representing bare metal server on isolation characteristics2,TRepresenting the weight of the impact of the virtual machine on the isolation characteristic, y1,ZWeight of influence, y, representing bare metal server on hardware access characteristics2,ZWeight, y, representing the impact of a virtual machine on a hardware access characteristic1,GWeight, y, representing the impact of bare metal servers on delay characteristics2,GRepresenting the weight of the impact of the virtual machine on the latency characteristics.

Further, in the above-mentioned case,

wherein, T0、Z0And G0The values are obtained according to the actual computing resource conditions and respectively correspond to the isolation characteristic, the hardware access characteristic and the delay characteristic. Preferably, x1,TIs TV,x1,ZIs ZV,x1,GIs GV,x2,TIs TB,x2,ZIs ZB,x2,GIs GB,TV、ZV、GV、TB、ZBAnd GBAre preset values, which can be preset according to the actual application scene.

Further, the generating an optimal computing resource selection scheme according to the criterion layer judgment matrix and the plurality of scheme layer judgment matrices specifically includes:

generating a first eigenvector corresponding to the maximum eigenvalue of the criterion layer judgment matrix;

generating a plurality of second eigenvectors respectively corresponding to the maximum eigenvalues of the plurality of scheme layer judgment matrixes;

generating an influence weight vector of a scheme layer on a target layer according to the first feature vector and the plurality of second feature vectors, wherein the influence weight vector of the scheme layer on the target layer comprises influence weights of all the application self-contained units on optimal computing resources;

and selecting the application self-containing unit corresponding to the maximum weight value from the influence weights of the application self-containing units on the optimal computing resource as the optimal computing resource.

According to the criterion layer judgment matrix and the scheme layer judgment matrix, solving a criterion layer judgment matrix A0Eigenvectors corresponding to the largest eigenvalues of the matrix, WO-WO 1, WO2, WO3]T

Solving a scheme layer judgment matrix ATThe eigenvector corresponding to the largest eigenvalue of the matrix, wd1 ═ wt1, wt2]T

Solving a scheme layer judgment matrix AZEigenvectors corresponding to the largest eigenvalues of the matrix, wd2 ═ wz1, wz2]T

Solving a scheme layer judgment matrix AGThe eigenvector corresponding to the maximum eigenvalue of the matrix, wd3 ═ wg1, wg2]T

The matrix WD is generated from WD1, WD2 and WD3,the weight vector of the influence of the generation scheme layers according to WO and WD on the optimal computational resource is K, which is the product of the matrix WO and the matrix WD.

Specifically, if the application self-contained unit is a bare metal server and a container, K is WD, WO, WC, and K includes two elements, WC represents an influence weight of the container on the optimal computing resource, and WB represents an influence weight of the bare metal server on the optimal computing resource. Comparing the values of the two eigenvectors, determining the scheme corresponding to the element with the largest value as the optimal scheme according to the analysis and calculation result, namely determining the application self-accommodation unit corresponding to the larger value of the influence weight as the optimal calculation resource according to the values of the influence weights WC and WB.

If the application self-holding unit is a bare metal server and a virtual machine, K is WD, WO, WV, WB, and K includes two elements WV and WB, where WV denotes an influence weight of the virtual machine on the optimal computing resource, and WB denotes an influence weight of the bare metal server on the optimal computing resource. And determining the application self-containing unit corresponding to the larger value of the influence weight as the optimal computing resource according to the values of the influence weights WV and WB.

Further, if the plurality of application self-containing units are bare metal servers and containers, the influence weight vector of the scheme layer on the target layer includes influence weights of the bare metal servers on the optimal computing resources and influence weights of the containers on the optimal computing resources;

the selecting the application self-containing unit corresponding to the maximum weight value from the influence weights of the application self-containing units on the optimal computing resource as the optimal computing resource comprises the following steps:

judging whether the influence weight of the bare metal server on the optimal computing resource is greater than the influence weight of the container on the optimal computing resource, if so, selecting the bare metal server as the optimal computing resource, and otherwise, selecting the container as the optimal computing resource;

if the plurality of application self-containing units are bare metal servers and virtual machines, the influence weight vector of the scheme layer on the target layer comprises the influence weight of the bare metal servers on the optimal computing resources and the influence weight of the virtual machines on the optimal computing resources;

the selecting the application self-containing unit corresponding to the maximum weight value from the influence weights of the application self-containing units on the optimal computing resource as the optimal computing resource comprises the following steps:

and judging whether the influence weight of the bare metal server on the optimal computing resource is greater than the influence weight of the virtual machine on the optimal computing resource, if so, selecting the bare metal server as the optimal computing resource, and otherwise, selecting the virtual machine as the optimal computing resource. .

Specifically, if the application self-containing unit is a bare metal server and a container, according to the values of WC and WB, if WB is greater than the value of WC, the generated optimal computing resource is the bare metal server, and if WB is less than or equal to the value of WC, the generated optimal computing resource is the container;

if the self-accommodating unit is a bare metal server and a virtual machine, according to the values of WV and WB, if WB is larger than the value of WV, the generated optimal computing resource is the bare metal server, and if WB is smaller than or equal to the value of WV, the generated optimal computing resource is the virtual machine.

The embodiment of the disclosure can realize that one application self-accommodating unit is selected as an optimal computing resource based on an analytic hierarchy process in a data center with a plurality of application self-accommodating units coexisting according to flow characteristics, and particularly, computing resources more suitable for current requirements can be selected between a bare metal server and a container and between the bare metal server and a virtual machine according to characteristics of a scheme.

Fig. 4 is an architecture diagram of a computing resource selection system according to a second embodiment of the present disclosure, as shown in fig. 4, including:

a building module 11 configured to build a computing resource selection model, where the computing resource selection model includes a target layer, a criterion layer, and a solution layer, the target layer is an optimal computing resource, and the solution layer includes a plurality of application self-contained units that are candidates for the optimal computing resource; the criteria layer includes a set of characteristics determined from the hosting unit from the plurality of applications that affect optimal computing resource selection;

a first generating module 12 arranged to generate a criterion layer decision matrix and a plurality of solution layer decision matrices from the computational resource selection model;

a second generating module 13 configured to generate an optimal computing resource selection scheme based on the criterion layer decision matrix and the plurality of scheme layer decision matrices.

Further, the application self-containing unit in the computing resource selection model constructed by the construction module 11 is a bare metal server and a container, or a bare metal server and a virtual machine;

if the plurality of application self-containing units are bare metal servers and containers, elements of the feature set comprise isolation features, flexible features and portable features;

if the plurality of application self-contained units are bare metal servers and virtual machines, the elements of the feature set comprise isolation features, hardware access features and delay features.

Further, the first generating module 12 is specifically configured to:

generating the criterion layer judgment matrix by the following formula (1):

wherein A is0Representing a criterion layer judgment matrix;

wherein A is0Representing a criterion layer judgment matrix;

when the plurality of application self-contained units are bare metal servers and containers, at A0In, x1Weight of influence, x, of the 1 st element isolation property of the property set in the criteria layer on the target layer2Weight of influence, x, of the flexible property of the 2 nd element of the property set in the criteria layer on the target layer3The influence weight of the 3 rd element portable characteristic representing the characteristic set in the criterion layer on the target layer;

when the plurality of application self-contained units are bare metal servers and virtual machines, at A0In, x1Weight of influence, x, of the 1 st element isolation property of the property set in the criteria layer on the target layer2Weight of influence, x, of the 2 nd element hardware access characteristic representing the set of characteristics in the criteria layer on the target layer3The influence weight of the 3 rd element delay characteristic representing the characteristic set in the criterion layer on the target layer.

Further, the first generating module 12 is specifically further configured to:

generating the plurality of scheme layer decision matrices by the following equation (2):

wherein when the plurality of application self-contained units are bare metal servers and containers, ATRepresenting a scheme layer decision matrix corresponding to the 1 st element isolation property in the criterion layer, AZRepresenting a scheme layer decision matrix corresponding to the 2 nd element flexibility characteristic in the criterion layer, AGRepresenting a scheme layer judgment matrix corresponding to the 3 rd element portability characteristic in the criterion layer; in ATIn, y1,TRepresenting the weight of the impact of the bare metal server of the 1 st element in the scheme layer on the isolation characteristics of the 1 st element in the criterion layer, y2,TRepresenting the influence weight of the 2 nd element container in the scheme layer on the 1 st element isolation characteristic in the criterion layer; in AZIn, y1,ZRepresenting the influence weight, y, of the bare metal server of the 1 st element in the scheme layer on the flexible property of the 2 nd element in the criterion layer2,ZRepresenting the influence weight of the 2 nd element container in the scheme layer on the 2 nd element flexible property in the criterion layer; in AGIn, y1,GRepresents the weight of the influence of the bare metal server of the 1 st element in the scheme layer on the portability of the 3 rd element in the criterion layer, y2,GRepresenting the influence weight of the 2 nd element container in the scheme layer on the portability of the 3 rd element in the criterion layer;

when the plurality of application self-accommodating units are bare metal servers and virtual machines, ATRepresenting a scheme layer decision matrix corresponding to the 1 st element isolation property in the criterion layer, AZRepresenting a scheme layer decision matrix corresponding to the 2 nd element hardware access characteristic in the criteria layer, AGRepresentation and criteriaA scheme layer judgment matrix corresponding to the 3 rd element delay characteristic in the layer; in ATIn, y1,TRepresenting the weight of the impact of the bare metal server of the 1 st element in the scheme layer on the isolation characteristics of the 1 st element in the criterion layer, y2,TRepresenting the influence weight of the 2 nd element virtual machine in the scheme layer on the 1 st element isolation characteristic in the criterion layer; in AZIn, y1,ZWeight of influence, y, of bare metal server of element 1 in scheme layer on hardware access characteristic of element 2 in criterion layer2,ZRepresenting the influence weight of the 2 nd element virtual machine in the scheme layer on the 2 nd element hardware access characteristic in the criterion layer; in AGIn, y1,GRepresents the weight of the influence of the bare metal server of the 1 st element in the scheme layer on the delay characteristic of the 3 rd element in the criterion layer, y2,GRepresenting the influence weight of the 2 nd element virtual machine in the scheme layer on the 3 rd element delay characteristic in the criterion layer.

Further, the second generating module 12 includes:

a first generating unit configured to generate a first eigenvector corresponding to a maximum eigenvalue of the criterion layer determination matrix;

a second generation unit configured to generate a plurality of second eigenvectors corresponding to the maximum eigenvalues of the plurality of scheme layer determination matrices, respectively;

a third generating unit, configured to generate an influence weight vector of the solution layer on the target layer according to the first eigenvector and the plurality of second eigenvectors, wherein the influence weight vector of the solution layer on the target layer comprises influence weights of the self-contained units on the optimal computing resources;

and the selecting unit is arranged to select the application self-containing unit corresponding to the maximum value from the influence weights of the application self-containing units on the optimal computing resource as the optimal computing resource.

Further, if the plurality of application self-containing units are bare metal servers and containers, the influence weight vector of the scheme layer on the target layer includes influence weights of the bare metal servers on the optimal computing resources and influence weights of the containers on the optimal computing resources;

the selection unit is specifically configured to:

judging whether the influence weight of the bare metal server on the optimal computing resource is greater than the influence weight of the container on the optimal computing resource, if so, selecting the bare metal server as the optimal computing resource, and otherwise, selecting the container as the optimal computing resource; (ii) a

If the plurality of application self-containing units are bare metal servers and virtual machines, the influence weight vector of the scheme layer on the target layer comprises the influence weight of the bare metal servers on the optimal computing resources and the influence weight of the virtual machines on the optimal computing resources;

the selection unit is specifically configured to:

and judging whether the influence weight of the bare metal server on the optimal computing resource is greater than the influence weight of the virtual machine on the optimal computing resource, if so, selecting the bare metal server as the optimal computing resource, and otherwise, selecting the virtual machine as the optimal computing resource.

The computing resource selection system in the embodiment of the disclosure is used for implementing the computing resource selection method in the first method embodiment, so that the description is simpler, and specific reference may be made to the related description in the first method embodiment, which is not described herein again.

Furthermore, as shown in fig. 5, a third embodiment of the present disclosure further provides an electronic device, which includes a memory 10 and a processor 20, where the memory 10 stores a computer program, and when the processor 20 runs the computer program stored in the memory 10, the processor 20 executes the above-mentioned various possible computing resource selection methods.

The memory 10 is connected to the processor 20, the memory 10 may be a flash memory, a read-only memory or other memories, and the processor 20 may be a central processing unit or a single chip microcomputer.

It is to be understood that the above embodiments are merely exemplary embodiments that are employed to illustrate the principles of the present disclosure, and that the present disclosure is not limited thereto. It will be apparent to those skilled in the art that various changes and modifications can be made therein without departing from the spirit and scope of the disclosure, and these are to be considered as the scope of the disclosure.

完整详细技术资料下载
上一篇:石墨接头机器人自动装卡簧、装栓机
下一篇:一种虚拟机调度和安全访问方法、装置、设备及可读介质

网友询问留言

已有0条留言

还没有人留言评论。精彩留言会获得点赞!

精彩留言,会给你点赞!