CN110287025A - A kind of resource allocation methods, device and equipment - Google Patents
A kind of resource allocation methods, device and equipment Download PDFInfo
- Publication number
- CN110287025A CN110287025A CN201910532166.0A CN201910532166A CN110287025A CN 110287025 A CN110287025 A CN 110287025A CN 201910532166 A CN201910532166 A CN 201910532166A CN 110287025 A CN110287025 A CN 110287025A
- Authority
- CN
- China
- Prior art keywords
- resource
- rack group
- available
- needs
- rack
- 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.)
- Pending
Links
Classifications
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F9/00—Arrangements for program control, e.g. control units
- G06F9/06—Arrangements for program control, e.g. control units using stored programs, i.e. using an internal store of processing equipment to receive or retain programs
- G06F9/46—Multiprogramming arrangements
- G06F9/50—Allocation of resources, e.g. of the central processing unit [CPU]
- G06F9/5005—Allocation of resources, e.g. of the central processing unit [CPU] to service a request
- G06F9/5027—Allocation of resources, e.g. of the central processing unit [CPU] to service a request the resource being a machine, e.g. CPUs, Servers, Terminals
-
- G—PHYSICS
- G06—COMPUTING; CALCULATING OR COUNTING
- G06F—ELECTRIC DIGITAL DATA PROCESSING
- G06F2209/00—Indexing scheme relating to G06F9/00
- G06F2209/50—Indexing scheme relating to G06F9/50
- G06F2209/504—Resource capping
Landscapes
- Engineering & Computer Science (AREA)
- Software Systems (AREA)
- Theoretical Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Stored Programmes (AREA)
Abstract
The invention discloses a kind of resource allocation methods, device and equipment, are related to the field of cloud calculation of financial technology, and when solving progress resource allocation existing in the prior art, resource allocation process is slow, the problem of wasting time.The present invention determines the resource quantity needed first, if it is determined that the resource quantity needed is not more than the quantity based on the TOR available rack group established, so can be used in rack group from this selects available resources identical with the resource quantity of the needs to be allocated, here available rack group is that there are the rack groups of available resources in the rack group, due to when determining that the resource quantity needed is not more than the quantity of available rack group, resource identical with the resource quantity needed is selected to be allocated from the rack group, without manually selecting available resources in resource pool, improve the process of resource allocation, save the time.
Description
Technical field
The present invention relates to the field of cloud computer technology of financial technology (Fintech), in particular to a kind of resource allocation methods,
Device and equipment.
Background technique
With the development of computer technology, more and more technical applications are in financial field, and traditional financial industry is gradually
Changing to financial technology (Fintech), cloud computing is also, at present in field of cloud calculation, numerous larger IT resources and soft of possessing
The enterprise of part system all can cloud computing environment, most important one technology be virtualizations inside the data center deployment of oneself
And the resource pool management mode and technology of virtualization are supported, for example cloud computing environment uses KVM virtualization technology, in IaaS
(infrastructure services, Infrastructure as a Service) layer uses traditional virtualization architecture scheme.In order to protect
The stability and high availability of card system, current application High Availabitity rule are as follows:
One, former using High Availabitity rule
1, kernel subsystems (A, B1 class) instance number is not less than 3, and non-core subsystem instance number is not less than 2;
2, a subsystem, on the instance number of single DCN is at least deployed in two different cabinets.
Two, the application High Availabitity rule under more living with city multicenter
1, the IDC (Internet Data Center, Internet data center) of the example deployment of a subsystem is counted not
Less than 2;
2, important subsystem (A, B1, B2 class), in single DCN (Data Center Node, data center's node)
Instance number is not less than 2;
3, important subsystem (A, B1, B2 class), the instance number in single DCN are at least deployed in two different cabinets
On.
Host resource distribution includes that physical host and fictitious host computer distribute in existing scheme, first according to resource requirement side
Demand screens unappropriated machine according to physical region from CMDB, carries out physical machine deployment, machine tool dispensing, virtualization etc. one
Sequence of maneuvers forms resource pool, then hand picking meets the resource of above-mentioned two High Availabitity rule, last basis from resource pool
Subsystem distributes the information such as DCN, application domain, and consigns to resource requirement side.
Due to needing hand picking resource in resource allocation, keeps resource allocation process slow, waste time.
Summary of the invention
The present invention provides a kind of resource allocation methods, device and equipment, to solve existing in the prior art provided
When source is distributed, resource allocation process is slow, the problem of wasting time.
In a first aspect, the embodiment of the present invention provides a kind of resource allocation methods, this method comprises:
Determine the resource quantity needed;
If the resource quantity of the needs is no more than the available rack group established of the wire laying mode TOR based on data center
Quantity then can select available resources identical with the resource quantity of the needs to be allocated from described in rack group, wherein
Described can be that there are the rack groups of available resources in the rack group with rack group.
The above method, it is first determined the resource quantity of needs, if it is determined that the resource quantity of needs is not more than is built based on TOR
The quantity of vertical available rack group selects available resources identical with the resource quantity of the needs then can be used from this in rack group
It is allocated, available rack group here is that there are the rack groups of available resources in the rack group, due to determining needs
When resource quantity is not more than the quantity of available rack group, selected from the rack group resource identical with the resource quantity of needs into
Row distribution, without manually selecting available resources in resource pool, improves the process of resource allocation, saves the time.
In one possible implementation, after the determining resource quantity needed, further includes:
The resource of the needs is physical host resource, if the resource quantity of the needs can use rack group greater than described
Quantity then can be used the available resources of rack group to carry out duplicate allocation for described at least one in rack group;
The resource of the needs is fictitious host computer resource, if the resource quantity of the needs can use rack group greater than described
Quantity, and no more than the quantity of available physical host in the corresponding operation system of resource of the needs, then from the business system
Available resources identical with the resource quantity of the needs are selected to be allocated in the quantity of available physical host in system.
The above method, after determining the resource quantity needed, resource as needed is different, and processing mode is also different,
Resource if necessary is physical host resource, and the resource quantity needed is greater than the quantity of available rack group, then by the machine
At least one in frame group can be used the available resources of rack group to carry out duplicate allocation;Resource if necessary is fictitious host computer resource,
And the resource quantity needed is greater than the quantity of available rack group, the available physical of operation system corresponding no more than the resource of needs
The quantity of host, then selected from the available physical host of the operation system with the identical available resources of resource quantity of needs into
Row distribution.
In one possible implementation, the resource of the needs is fictitious host computer resource, if the resource of the needs
Quantity can use the quantity of rack group described in being greater than, further includes:
If the resource quantity of the needs is greater than the quantity of available resources in the corresponding operation system of resource of the needs,
Then without resource allocation.
The above method, resource if necessary is fictitious host computer resource, and the resource quantity needed is greater than available rack group
Quantity, and be greater than need the corresponding operation system of resource in available resources quantity, then carry out abnormal prompt, illustrate can be used
Resource is inadequate, can not carry out resource allocation.
In one possible implementation, the resource of the needs is physical host resource;
It is described available resources identical with the resource quantity of the needs to be selected to be allocated in rack group from described,
Include:
The available machine for selecting resource utilization identical with the resource quantity of the needs small in rack group can be used from described
Frame group;
For the small available rack group of a resource utilization, selected in the available rack group small from the resource utilization
One available physical machine SN and IP address;
Terminal where the available physical machine SN and IP address of selection are sent to user.
The above method, give when the resource of needs be physical host resource when, how from available rack group selection with
The identical available resources of the resource quantity needed are allocated.
In one possible implementation, the resource of the needs is fictitious host computer resource;
It is described available resources identical with the resource quantity of the needs to be selected to be allocated in rack group from described,
Include:
The available machine for selecting resource utilization identical with the resource quantity of the needs small in rack group can be used from described
Frame group;
IP address identical with the resource quantity of the needs is selected in the available rack group small from the resource utilization,
And resource name is selected from the small available rack group of the resource utilization;
The corresponding machine tool SN of fictitious host computer and fictitious host computer IP address are determined according to the IP address and the resource name;
Terminal where the machine tool SN and fictitious host computer IP address are sent to user.
The above method, give when the resource of needs be fictitious host computer resource when, how from available rack group selection with
The identical available resources of the resource quantity needed are allocated.
Second aspect, the embodiment of the present invention provide a kind of resource allocation device, which includes:
Determining module, for determining the resource quantity needed;
Distribution module, if the resource quantity of the needs no more than based on data center wire laying mode TOR establish can
With the quantity of rack group, then it is used to select available resources identical with the resource quantity of the needs in rack group from described can use
It is allocated, wherein the available rack group is that there are the rack groups of available resources in the rack group.
In one possible implementation, the distribution module is also used to:
After the determining resource quantity needed, the resource of the needs is physical host resource, if the needs
Resource quantity can use the quantity of rack group described in being greater than, then the available money that can use at least one in rack group that rack group can be used
Source carries out duplicate allocation;
The resource of the needs is fictitious host computer resource, if the resource quantity of the needs can use rack group greater than described
Quantity, and the resource quantity of the needs is no more than the number of available physical host in the corresponding operation system of resource of the needs
Amount, then from selecting identical with the resource quantity of the needs available money in the operation system in the quantity of available physical host
Source is allocated.
In one possible implementation, the distribution module is also used to:
The resource of the needs is fictitious host computer resource, if the resource quantity of the needs can use rack group greater than described
Quantity, if the resource quantity of the needs is greater than the quantity of available resources in the corresponding operation system of resource of the needs,
Without resource allocation.
In one possible implementation, the resource of the needs is physical host resource, and the distribution module is specific
For:
The available machine for selecting resource utilization identical with the resource quantity of the needs small in rack group can be used from described
Frame group;
For the small available rack group of a resource utilization, selected in the available rack group small from the resource utilization
One available physical machine SN and IP address;
Terminal where the available physical machine SN and IP address of selection are sent to user.
In one possible implementation, the resource of the needs is fictitious host computer resource;The distribution module is specific
For:
The available machine for selecting resource utilization identical with the resource quantity of the needs small in rack group can be used from described
Frame group;
IP address identical with the resource quantity of the needs is selected in the available rack group small from the resource utilization,
And resource name is selected from the small available rack group of the resource utilization;
The corresponding machine tool SN of fictitious host computer and fictitious host computer IP address are determined according to the IP address and the resource name;
Terminal where the machine tool SN and fictitious host computer IP address are sent to user.
The third aspect, the embodiment of the present invention provide another resource allocation apparatus, which includes:
Memory and processor;
Memory, for storing program instruction;
Processor executes first aspect according to the program of acquisition for calling the program instruction stored in the memory
Described in any item methods.
Fourth aspect, the embodiment of the present invention, which also provides the computer-readable recording medium storage, computer instruction, when
When the computer instruction is run on computers, so that computer executes method described in any one of first aspect.
In addition, second aspect technical effect brought by any implementation into fourth aspect can be found in first aspect
Technical effect brought by middle difference implementation, details are not described herein again.
The aspects of the invention or other aspects can more straightforwards in the following description.
Detailed description of the invention
To describe the technical solutions in the embodiments of the present invention more clearly, make required in being described below to embodiment
Attached drawing is briefly introduced, it should be apparent that, drawings in the following description are only some embodiments of the invention, for this
For the those of ordinary skill in field, without any creative labor, it can also be obtained according to these attached drawings
His attached drawing.
Fig. 1 provides a kind of method of resource allocation for the embodiment of the present invention;
Fig. 2 is physical host resource allocation flow diagram provided in an embodiment of the present invention;
Fig. 3 is fictitious host computer resource allocation flow diagram provided in an embodiment of the present invention;
Fig. 4 is the first resource allocation device structural schematic diagram provided in an embodiment of the present invention;
Fig. 5 is second of resource allocation device structural schematic diagram provided in an embodiment of the present invention.
Specific embodiment
To make the objectives, technical solutions, and advantages of the present invention clearer, below in conjunction with attached drawing to the present invention make into
It is described in detail to one step, it is clear that the described embodiments are only some of the embodiments of the present invention, rather than whole implementation
Example.Based on the embodiments of the present invention, obtained by those of ordinary skill in the art without making creative efforts
All other embodiment, shall fall within the protection scope of the present invention.
The embodiment of the present application provides a kind of resource allocation methods, device and equipment, existing in the prior art to solve
When carrying out resource allocation, resource allocation process is slow, the problem of wasting time.Wherein, method and apparatus are based on same invention
Design, since the principle that method and device solves the problems, such as is similar, the implementation of apparatus and method can be repeated with cross-reference
Place repeats no more.
Hereinafter, the part word in the application is explained, in order to those skilled in the art understand that.
1), IaaS:Infrastructure as a Service, infrastructure service, and are the bottoms of cloud service,
Some basic resources are mainly provided.
2), ToR:Top of Rack is a kind of wire laying mode of data center, is exactly the server machine in the 42U of standard
The top of cabinet is installed by access switch.
3), RACK: the unified standard of Constructing data center, width are 19 inches of standard, and height usually carrys out table with " U " number
Show (1U=4.445cm), single cabinet is the 42U height of standard.
4), the abbreviation of KVM:Kernel-based Virtual Machine is the system virtualization module of an open source,
Hardware based Full-virtualization technology.
5), VM: virtual machine (Virtual Machine) refer to by software simulate with complete hardware system function,
Operate in the complete computer in a completely isolated environment.
6), SystemID: refer to that application system is numbered, each operation system has unique system identifier.
7), DCN:Data Center Node, data center's node refer to a logical concept in application system framework,
Actual typical data center is not represented, but the same DCN is necessarily pertaining only to some typical data center.
8), AppDomain:Application Domain, application domain, logical concept, using affiliated domain.
9), Hostname: Hostname, to show or be arranged the Hostname of system.
10), OpenStack: it is the cloud computing management platform project of an open source, is combined by several main components
Complete specific works.OpenStack supports almost all kinds of cloud environment, and project objective is to provide that implementation is simple, can advise greatly
Mould extension, the cloud computing that abundant, standard is unified manage platform.OpenStack is provided the foundation by the service of various complementations and is set
The solution for servicing (IaaS) is applied, each service provides API to be integrated.
11), AZ:Availability Zone, available area, AZ simply from the point of view of can be understood as some hosts (host)
Set.In OpenStack, Nova and Cinder module has been integrated with the function of AZ before Mitaka version.In Nova
In module, user can specify an AZ when creating empty machine, and machine empty in this way will generate on the host that this AZ is included.?
In Cinder module, user specified AZ, in this way volume can be stored when creating volume in the host that specified A is included
Distribution.
12), Affinity Group:OpenStack associated group, it is ensured that example is in identical or different management of computing program
On host.
13), Image: mirror image refers to system image.
14), SN:Serial Number, product ID, product ID are to verify " legal identity of product "
And the concept introduced, it is the legal equity for ensureing user, enjoys legitimate service, and the product of a set of legal copy is only right
Answer a set product sequence number.
15), CMDB:Configuration Management Database, configuration management database, CMDB storage with
The various configuration informations of equipment in enterprise IT architecture are managed, it and all service supports and service delivery process are all closely linked to,
It supports the operating of these processes, play the value of configuration information, while guaranteeing the accuracy of data dependent on related procedure.
16), ITSM:ITService Management, IT service management, IT service management are a set of help enterprises to IT
The method that planning, research and development, implementation and the operation of system are effectively managed, is methodology opinion, and it is flat to refer to ITSM management herein
Platform.
In addition, it is necessary to illustrate, in the application, "at least one" refers to one or more, and " multiple " refer to two
Or it is more than two."and/or" describes the incidence relation of affiliated partner, indicates may exist three kinds of relationships, for example, A and/or B,
The case where can indicate: individualism A exists simultaneously A and B, individualism B, wherein A, B can be odd number or plural number.Word
Symbol "/" typicallys represent the relationship that forward-backward correlation object is a kind of "or"." at least one of following (a) " or its similar expression, refers to
These in any combination, any combination including individual event (a) or complex item (a).For example, in a, b or c at least
One (a), it can indicate any one subsequent situation: a, b, c, d and b, a and c, b and c, a and b and c.
With the Quick Extended of business, data center's scale is gradually expanded, and business application resource requirement is more frequent, new item
Mesh is online, server migration, server cross guarantor, hardware fault etc. and rapid increasing new or replacement node scene needed gradually to increase, mesh
Before, when carrying out resource allocation, from resource bid to resource allocation, whole process manpower intervention is more, therefore hands over resource allocation
It is slow to pay process, moreover, in manpower intervention, for personnel to the not no macroscopical understanding of resource utilization, it is possible to can lead
It causes the utilization of resources unbalanced, increases the security risk using stable operation, this security risk will lead to banking (loan
Business, deposit business or other financial business) safety it is low, do not meet the regulatory requirements of bank and other financial mechanism.
If not needing personnel's participation from resource bid to resource allocation, automation is fully achieved, then can improve resource point
The process matched.
The application scenarios of description of the embodiment of the present invention are the technical solutions in order to more clearly illustrate the embodiment of the present invention,
The restriction for technical solution provided in an embodiment of the present invention is not constituted, those of ordinary skill in the art are it is found that with newly answering
With the appearance of scene, technical solution provided in an embodiment of the present invention is equally applicable for similar technical problem.
For above-mentioned application scenarios, the embodiment of the present invention provides a kind of method of resource allocation, as shown in Figure 1, this method
Specifically comprise the following steps:
S100 determines the resource quantity needed;
S101, if the resource quantity of the needs is no more than the available machine that the wire laying mode TOR based on data center is established
The quantity of frame group then can select available resources identical with the resource quantity of the needs to be divided from described in rack group
Match, wherein the available rack group is that there are the rack groups of available resources in the rack group.
In the embodiment of the present invention, it is first determined the resource quantity of needs, if it is determined that the resource quantity of needs is not more than base
In the quantity for the available rack group that TOR is established, then can be used selection in rack group identical with the resource quantity of the needs from this
Available resources are allocated, and available rack group here is that there are the rack groups of available resources in the rack group, due to true
Surely it when the resource quantity needed is not more than the quantity of available rack group, is selected from the rack group identical as the resource quantity needed
Resource be allocated, without manually selecting available resources in resource pool, the process of resource allocation is improved, when saving
Between.
When resource requirement side needs resource, a resource request information can be issued, can carry in resource request information needs
The resource quantity of the resource and needs wanted, for example, DCN, Appdomain, SystemId, Image, physical areas, machine models,
Then the information such as instance number determine the resource quantity of the resource and needs that need from resource request information.
Wherein, physical areas refers to the physical region divided, for example, directorial area, external connection area, server zone area etc.;Machine
Model can create corresponding resource according to the demand of business on demand, some business demands can have correspondence to machine models, Image
Requirement.
It should be noted that resource here can be physical host resource, it is also possible to fictitious host computer resource, it can be with
It is the combination of physical host resource and fictitious host computer resource.
For example, resource requirement side A issues a resource request information, the resource determined in resource request information is to need
Physical host resource is 5, and fictitious host computer resource is 3.
After the resource quantity that needs have been determined, by the number of the resource quantity of needs and the available rack group established based on TOR
Amount is compared, and resource quantity if necessary is not more than the quantity of available rack group, then selects and need from available rack group
The identical available resources of the resource quantity wanted are allocated, and available rack group here is that there are available resources in rack group
Rack group.
Here the resource quantity of needs is identical with subsequent instance number, all represents the number of resources of resource requirement side's needs.
It should be noted that two racks form a rack group, conventional rack is 42U, 21 seats in the plane, conventional object
Managing host is 2U, so a rack can at most place 21 physical hosts, a rack group can have up to 42 physics
Host.
If physical host is occupied, which can not be allocated again.If having 42 in a rack group
A physical host then illustrates that the rack group is available rack group there are at least one physical host is unoccupied.
When the resource quantity to needs is compared with the quantity of available rack group, resource quantity if necessary is little
In the quantity for the available rack group established based on TOR, then selection is identical with the resource quantity needed from available rack group can
Be allocated with resource, separately below to the resource that the resource of needs is physical host resource and needs be fictitious host computer resource into
Row explanation.
Situation one, the resource needed are physical host resource.
The available rack group for selecting resource utilization identical with the resource quantity needed small first from available rack group,
Then it is directed to the small available rack group of a resource utilization, selection one can be used in the available rack group small from resource utilization
Physical machine SN and IP address, terminal where the available physical machine SN and IP address of selection are finally sent to user.
Wherein, the resource utilization of rack group can be used, that is, under the rack group, the number of unappropriated physical host
Amount and the total quantity of physical host carry out ratio, are as a result the resource utilization of the available rack group.
For example, there is 42 physical hosts under rack group 1, wherein there is 21 physical hosts occupied, then the money of rack group 1
Source utilization rate is 50%.
The available rack group small with the identical resource utilization of resource quantity of needs is selected from available rack group, it can be with
The resource utilization of all available rack groups is calculated, money identical with the resource quantity needed is then selected from institute's organic frame group
The small available rack group of source utilization rate.
For example, there is 5 available rack groups, respectively available rack group 1 can use rack group 2, can use rack group 3, can use machine
Frame group 4 can use rack group 5, calculate separately out the resource utilization of each available rack group, can be used with the resource of rack group 1
Rate is 10%, can be 15% with the resource utilization of rack group 2, can be 30% with the resource utilization of rack group 3, can use rack
The resource utilization of group 4 is 35%, can be 50 with the resource utilization of rack group 5, the resource quantity needed is 2, then can from 5
With the available rack group for selecting 2 resource utilizations small in rack group, i.e., available rack group 1 and available rack group 2.
After the available rack group for having selected resource utilization identical with the resource quantity of needs small, make for a resource
With the small available rack group of rate, selection one available physical machine SN and IP in the available rack group small from the resource utilization
Location.
An available physical machine SN and IP address are selected in the available rack group small from resource utilization, can be random
Selection, can also be selected, with no restrictions to this application by preset rules.
For example, the available rack group for having selected 2 resource utilizations small, can use rack group 1 and available rack group 2, can use
Have 2 unappropriated physical hosts, physical host 1 and physical host 2 in rack group 1, can with have in rack group 23 not by
The physical host of occupancy, physical host 3, physical host 4 and physical host 5 select one from the available rack group of each selection
A available physical host SN and IP address, selection mode can be random selection, can also be selected according to preset rules.
After having selected physical host SN and IP address, the physical host SN and IP address of selection are returned into user place eventually
End.
Situation two, the resource needed are fictitious host computer resource.
The available rack group for selecting resource utilization identical with the resource quantity needed small from available rack group, from money
IP address identical with the resource quantity needed is selected in the small available rack group of source utilization rate, and small from resource utilization
Resource name can be selected in rack group, the corresponding machine tool SN of fictitious host computer and virtual master are determined according to IP address and resource name
Machine IP address;Terminal where machine tool SN and fictitious host computer IP address are sent to user.
The available rack group and feelings for selecting resource utilization identical with the resource quantity needed small from available rack group
Identical in shape one, it is no longer repeated herein.
IP address identical with the resource quantity needed is selected in the available rack group small from resource utilization, can be based on
Rack group calculates the AZ of Openstack, that is, the set of unappropriated physical host, then from the IP of virtual network segment
IP address identical with the resource quantity of the needs is distributed in the pond of location, and distributes physics host name according to being incremented by CMDB
Claim, the IP address distributed and physical host title are returned into user.
It should be noted that the creation rule of Hostname can be with are as follows: CN+city+IDC+ number, for example, using rule
The First Hostname of engine creation is CNSZFT05010001, and second Hostname is CNSZFT05010002, with this
Analogize, wherein CN is represented china (China), and SZ represents Shenzhen, and FT represents certain 0501 computer room, and 0001 represents number.
It is the explanation that resource allocation is carried out the case where being not more than the quantity of available rack group to the resource quantity of needs above,
Resource quantity if necessary is greater than the quantity of available rack group, illustrates the resource that rack group cannot meet the needs, if necessary
Resource be physical host resource, then can at least one in available rack group can be used rack group available resources repeat
Distribution.
It is below that physical host resource is illustrated to the resource of needs.
For example, the quantity of the physical host resource needed is 4, it can be available rack group 1 with rack group, rack group 2 can be used,
Can be with rack group 3, the quantity 4 of the physical resource needed is greater than the quantity 3 of available rack group, at this time can be from available rack group 1
One available physical host of middle random selection randomly chooses an available physical host, from available rack group 3 from rack group 2
Middle two available physical hosts of random selection carry out resource allocation, at this point, duplicate allocation can have been carried out with rack group 3.
Resource if necessary is fictitious host computer resource, and the resource quantity needed is greater than the quantity of available rack group, and
No more than the quantity of the available physical host of the corresponding operation system of resource of the needs, then from the available of the operation system
Available resources identical with the resource quantity of the needs are selected to be allocated in physical host.
In an implementation, it is selected from the available physical host of operation system identical with the resource quantity of the needs available
Resource is allocated, and the AZ of Openstack, that is, the set of unappropriated physical host can be obtained based on rack group,
Then IP address identical with the resource quantity of the needs is distributed from the IP address pond of virtual network segment, and according in CMDB
It is incremented by distribution physics Hostname, terminal where the IP address distributed and physical host title are sent to user.
Here the AZ of Openstack is obtained based on rack group, can be determining of being pre-created when building Openstack
Adopted rule, that is, there are corresponding relationships between rack group and AZ, it is determined that after rack group, it can be determined according to corresponding relationship
AZ;
The IP address pond of virtual net, can be virtual network segment, virtual network segment structure be pre-created when building Openstack
At the IP address pond of virtual net.
Resource if necessary is fictitious host computer resource, and the resource quantity needed is greater than the quantity of available rack group, and
Greater than the quantity of available resources in the corresponding operation system of resource of the needs, then illustrate what existing resource cannot meet the needs
Resource, therefore show abnormal prompt, without resource allocation.
It is illustrated below with specific embodiment.
Embodiment one: physical host resource allocation.
As shown in Fig. 2, being physical host resource allocation flow diagram provided in an embodiment of the present invention.
S200, rack group quantity can be used by determining now to net in CMDB;
S201 receives the ITSM resource bid information that user submits;
S202 obtains instance number from the ITMS resource bid information;
S203, rack group quantity can be used by judging in resource bid information whether instance number is less than in existing net, if it is, holding
Row S204, otherwise executes S211;
S204 calculates the resource utilization of each available rack group;
S205, the available rack group for selecting resource utilization identical with instance number small from available rack group;
S206, the available rack group small from each resource utilization of selection choose specific RACK;
S207 screens the physical host in specific seat in the plane from each available rack group;
S208 obtains the SN and IP address of the physical host of screening;
S209, the SN that will acquire and IP address, which are passed to physical machine, to be received pipe platform and is allocated;
The SN of distribution and IP address are synchronized to CMDB by S210;
S211 selects at least one rack group to carry out duplicate allocation;
S212 selects specific RACK from available rack group, executes S207.
Embodiment two: fictitious host computer resource allocation.
As shown in figure 3, being fictitious host computer resource allocation flow diagram provided in an embodiment of the present invention.
S300, the quantity of rack group can be used by determining now to net in CMDB;
S301 receives the ITSM resource bid information that user submits;
S302 obtains instance number N from the ITMS resource bid information;
S303, rack group quantity can be used by determining whether N is less than in existing net, if it is, executing S304, otherwise be executed
S312;
S304 calculates the resource utilization of each available rack group;
S305, selection and the small available rack group of N number of resource utilization from available rack group;
S306 establishes the AZ of OpenStack with the small available rack group of N number of utilization rate;
S307 selects N number of HOST from AZ;
S308 selects N number of IP address from the IP address pond of the virtual network segment of N number of HOST;
S309 determines Hostname according to being incremented by CMDB;
S310 is based on Hostname and N number of IP address, determines machine tool SN and corresponding IP address;
Determining machine tool SN and corresponding IP address are synchronized to CMDB by S311;
S312 will can form affinity group with the available HOST in rack group;
S313, judges whether N is less than HOST quantity in affinity group, if it is, executing S314, otherwise executes S316;
S314 randomly chooses N number of HOST from affine group;
S315 establishes the AZ of OpenStack based on available rack group, executes S307;
S316 shows exception information, without distribution.
Based on the same inventive concept, a kind of resource allocation device is additionally provided in the embodiment of the present invention, due to the device pair
What is answered is the corresponding device of resource allocation methods of the embodiment of the present invention, and the principle and this method phase that the device solves the problems, such as
Seemingly, therefore the implementation of the device may refer to the implementation of method, and overlaps will not be repeated.
As shown in figure 4, being a kind of resource allocation device structural schematic diagram provided in an embodiment of the present invention, which includes:
Determining module 400 and distribution module 401:
Determining module 400, for determining the resource quantity needed;
Distribution module 401, if what the resource quantity of the needs was established no more than the wire laying mode TOR based on data center
The quantity of rack group can be used, then for selection available money identical with the resource quantity of the needs in rack group can be used from described
Source is allocated, wherein the available rack group is that there are the rack groups of available resources in the rack group.
Optionally, the distribution module 401 is also used to:
After the determining resource quantity needed, the resource of the needs is physical host resource, if the needs
Resource quantity can use the quantity of rack group described in being greater than, then the available money that can use at least one in rack group that rack group can be used
Source carries out duplicate allocation;
The resource of the needs is fictitious host computer resource, if the resource quantity of the needs can use rack group greater than described
Quantity, and the resource quantity of the needs is no more than the number of available physical host in the corresponding operation system of resource of the needs
Amount, then from selecting identical with the resource quantity of the needs available money in the operation system in the quantity of available physical host
Source is allocated.
Optionally, the distribution module 401 is also used to:
The resource of the needs is fictitious host computer resource, if the resource quantity of the needs can use rack group greater than described
Quantity, if the resource quantity of the needs is greater than the quantity of available resources in the corresponding operation system of resource of the needs,
Without resource allocation.
Optionally, the resource of the needs is physical host resource, and the distribution module 401 is specifically used for:
The available machine for selecting resource utilization identical with the resource quantity of the needs small in rack group can be used from described
Frame group;
For the small available rack group of a resource utilization, selected in the available rack group small from the resource utilization
One available physical machine SN and IP address;
Terminal where the available physical machine SN and IP address of selection are sent to user.
Optionally, the resource of the needs is fictitious host computer resource;The distribution module 401 is specifically used for:
The available machine for selecting resource utilization identical with the resource quantity of the needs small in rack group can be used from described
Frame group;
IP address identical with the resource quantity of the needs is selected in the available rack group small from the resource utilization,
And resource name is selected from the small available rack group of the resource utilization;
The corresponding machine tool SN of fictitious host computer and fictitious host computer IP address are determined according to the IP address and the resource name;
Terminal where the machine tool SN and fictitious host computer IP address are sent to user.
Based on the same inventive concept, another resource allocation device is additionally provided in the embodiment of the present invention, due to the device
Corresponding is the corresponding device of resource allocation methods of the embodiment of the present invention, and the principle and this method phase that the device solves the problems, such as
Seemingly, therefore the implementation of the device may refer to the implementation of method, and overlaps will not be repeated.
As shown in figure 5, being a kind of resource allocation apparatus structural schematic diagram provided in an embodiment of the present invention, the equipment 500 packet
It includes:
Communication interface 501, memory 502 and processor 503;
Wherein, the processor 503 is communicated by the communication interface 501 with other equipment, for example, other equipment
It can be said external translation on line tool.Wherein, communication interface 501 can provide the solution party of application programming interface
Case.
Processor 503 can send foregoing translation parameter etc. to external translation on line tool by communication interface 501;Storage
Device 502, for storing program instruction;Processor 503, for calling the program instruction stored in the memory 502, according to obtaining
The program obtained executes the method in above-described embodiment.
In the embodiment of the present application, processor can be general processor, digital signal processor, specific integrated circuit,
Field programmable gate array or other programmable logic device, discrete gate or transistor logic, discrete hardware components,
It may be implemented or execute disclosed each method, step and the logic diagram in the embodiment of the present application.General processor can be
Microprocessor or any conventional processor etc..The step of method in conjunction with disclosed in the embodiment of the present application, can directly embody
Execute completion for hardware processor, or in processor hardware and software module combination execute completion.
In the embodiment of the present application, memory, for storing program instruction, memory can be nonvolatile memory,
Such as hard disk (hard disk drive, HDD) or solid state hard disk (solid-state drive, SSD) etc., it can also be volatile
Property memory (volatile memory), such as random access memory (random-access memory, RAM).Memory
Can also be can be used in carry or store have instruction or data structure form desired program code and can be by calculating
Any other medium of machine access, but not limited to this.Memory in the embodiment of the present application can also be circuit or other
Meaning can be realized the device of store function, for storing program instruction and/or data.It is not limited in the embodiment of the present application above-mentioned logical
Believe that the specific connection medium between interface, memory and processor, such as bus, bus can be divided into address bus, data
Bus, control bus etc..
Further, the embodiment of the present invention also provides a kind of readable storage medium storing program for executing of resource allocation, including program code, when
When said program code is run on the computing device, said program code is for making the calculating equipment execute resource allocation methods
The step of.
Above by reference to showing according to the method, apparatus (system) of the embodiment of the present application and/or the frame of computer program product
Figure and/or flow chart describe the application.It should be understood that can realize that block diagram and or flow chart is shown by computer program instructions
The combination of the block of a block and block diagram and or flow chart diagram for figure.These computer program instructions can be supplied to logical
With computer, the processor of special purpose computer and/or other programmable data processing units, to generate machine, so that via meter
The instruction that calculation machine processor and/or other programmable data processing units execute creates for realizing block diagram and or flow chart block
In specified function action method.
Correspondingly, the application can also be implemented with hardware and/or software (including firmware, resident software, microcode etc.).More
Further, the application can take computer usable or the shape of the computer program product on computer readable storage medium
Formula has the computer realized in the medium usable or computer readable program code, to be made by instruction execution system
It is used with or in conjunction with instruction execution system.In the present context, computer can be used or computer-readable medium can be with
It is arbitrary medium, may include, stores, communicates, transmits or transmit program, is made by instruction execution system, device or equipment
With, or instruction execution system, device or equipment is combined to use.
Obviously, various changes and modifications can be made to the invention without departing from essence of the invention by those skilled in the art
Mind and range.In this way, if these modifications and changes of the present invention belongs to the range of the claims in the present invention and its equivalent technologies
Within, then the present invention is also intended to include these modifications and variations.
Claims (11)
1. a kind of resource allocation methods, which is characterized in that this method comprises:
Determine the resource quantity needed;
If the resource quantity of the needs is no more than the number of the available rack group established of the wire laying mode TOR based on data center
Amount then can select available resources identical with the resource quantity of the needs to be allocated, wherein institute from described in rack group
Stating available rack group is that there are the rack groups of available resources in the rack group.
2. the method as described in claim 1, which is characterized in that after the determining resource quantity needed, further includes:
The resource of the needs is physical host resource, if the resource quantity of the needs can use the number of rack group greater than described
Amount then can be used the available resources of rack group to carry out duplicate allocation to described at least one in rack group;
The resource of the needs is fictitious host computer resource, if the resource quantity of the needs can use the number of rack group greater than described
Amount, and the quantity of the available physical host no more than the corresponding operation system of resource of the needs, then from the operation system
Available physical host in identical with the resource quantity of the needs available resources of selection be allocated.
3. method according to claim 2, which is characterized in that the resource of the needs is fictitious host computer resource, if the need
The resource quantity wanted can use the quantity of rack group described in being greater than, further includes:
If the resource quantity of the needs is greater than the quantity of available resources in the corresponding operation system of resource of the needs, no
Carry out resource allocation.
4. the method as described in claim 1, which is characterized in that the resource of the needs is physical host resource;
It is described available resources identical with the resource quantity of the needs to be selected to be allocated in rack group from described, it wraps
It includes:
The available rack group for selecting resource utilization identical with the resource quantity of the needs small in rack group can be used from described;
For the small available rack group of a resource utilization, one is selected in the available rack group small from the resource utilization
Available physical machine sequence number SN and network protocol IP address;
Terminal where the available physical machine SN and IP address of selection are sent to user.
5. method according to any of claims 1-4, which is characterized in that the resource of the needs is fictitious host computer resource;
It is described available resources identical with the resource quantity of the needs to be selected to be allocated in rack group from described, it wraps
It includes:
The available rack group for selecting resource utilization identical with the resource quantity of the needs small in rack group can be used from described;
IP address identical with the resource quantity of the needs is selected in the available rack group small from the resource utilization, and
Resource name is selected in the available rack group small from the resource utilization;
Fictitious host computer corresponding machine tool SN and fictitious host computer IP is determined according to the IP address and the resource name;
Terminal where the machine tool SN and fictitious host computer IP address are sent to user.
6. a kind of resource allocation device, which is characterized in that the device includes:
Determining module, for determining the resource quantity needed;
Distribution module, if the resource quantity of the needs is no more than the available machine that the wire laying mode TOR based on data center is established
The quantity of frame group, then for that available resources identical with the resource quantity of the needs can be selected to carry out in rack group from described
Distribution, wherein the available rack group is that there are the rack groups of available resources in the rack group.
7. device as claimed in claim 6, which is characterized in that the distribution module is also used to:
After the determining resource quantity needed, the resource of the needs is physical host resource, if the resource of the needs
Quantity can use the quantity of rack group described in being greater than, then to the available resources that can use at least one in rack group that rack group can be used
Carry out duplicate allocation;
The resource of the needs is fictitious host computer resource, if the resource quantity of the needs can use the number of rack group greater than described
Amount, and the resource quantity of the needs is no more than the number of available physical host in the corresponding operation system of resource of the needs
Amount, then from selecting identical with the resource quantity of the needs available money in the operation system in the quantity of available physical host
Source is allocated.
8. device as claimed in claim 6, which is characterized in that the resource of the needs is physical host resource, the distribution
Module is specifically used for:
The available rack group for selecting resource utilization identical with the resource quantity of the needs small in rack group can be used from described;
For the small available rack group of a resource utilization, one is selected in the available rack group small from the resource utilization
Available physical machine SN and IP address;
Terminal where the available physical machine SN and IP address of selection are sent to user.
9. such as the described in any item devices of claim 6-8, which is characterized in that the resource of the needs is fictitious host computer resource;
The distribution module is specifically used for:
The available rack group for selecting resource utilization identical with the resource quantity of the needs small in rack group can be used from described;
IP address identical with the resource quantity of the needs is selected in the available rack group small from the resource utilization, and
Resource name is selected in the available rack group small from the resource utilization;
The corresponding machine tool SN of fictitious host computer and fictitious host computer IP address are determined according to the IP address and the resource name;
Terminal where the machine tool SN and fictitious host computer IP address are sent to user.
10. a kind of resource allocation apparatus characterized by comprising
Memory and processor;
Memory, for storing program instruction;
Processor requires 1~5 according to the program execution benefit of acquisition for calling the program instruction stored in the memory
Described in any item methods.
11. a kind of computer readable storage medium, which is characterized in that the computer-readable recording medium storage has computer to refer to
It enables, when the computer instruction is run on computers, so that computer perform claim requires described in any one of 1~5
Method.
Priority Applications (2)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910532166.0A CN110287025A (en) | 2019-06-19 | 2019-06-19 | A kind of resource allocation methods, device and equipment |
PCT/CN2020/092740 WO2020253490A1 (en) | 2019-06-19 | 2020-05-27 | Resource allocation method, apparatus and device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201910532166.0A CN110287025A (en) | 2019-06-19 | 2019-06-19 | A kind of resource allocation methods, device and equipment |
Publications (1)
Publication Number | Publication Date |
---|---|
CN110287025A true CN110287025A (en) | 2019-09-27 |
Family
ID=68004791
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201910532166.0A Pending CN110287025A (en) | 2019-06-19 | 2019-06-19 | A kind of resource allocation methods, device and equipment |
Country Status (2)
Country | Link |
---|---|
CN (1) | CN110287025A (en) |
WO (1) | WO2020253490A1 (en) |
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2020253490A1 (en) * | 2019-06-19 | 2020-12-24 | 深圳前海微众银行股份有限公司 | Resource allocation method, apparatus and device |
CN113949637A (en) * | 2021-10-28 | 2022-01-18 | 中国建设银行股份有限公司 | Intelligent distribution and deployment method and device for switch resources |
Family Cites Families (6)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
US9317336B2 (en) * | 2011-07-27 | 2016-04-19 | Alcatel Lucent | Method and apparatus for assignment of virtual resources within a cloud environment |
CN103327095B (en) * | 2013-06-20 | 2016-03-02 | 电子科技大学 | A kind of implementation method of extendible data center network architecture |
CN105404545B (en) * | 2015-12-03 | 2018-11-30 | 中国联合网络通信集团有限公司 | The method and device of virtual machine distribution |
US20180254999A1 (en) * | 2017-03-06 | 2018-09-06 | Linkedin Corporation | Multidimensional resource allocation in data centers |
CN108037984B (en) * | 2017-11-28 | 2022-01-11 | 深圳前海微众银行股份有限公司 | Resource management method, system and readable storage medium for data analysis |
CN110287025A (en) * | 2019-06-19 | 2019-09-27 | 深圳前海微众银行股份有限公司 | A kind of resource allocation methods, device and equipment |
-
2019
- 2019-06-19 CN CN201910532166.0A patent/CN110287025A/en active Pending
-
2020
- 2020-05-27 WO PCT/CN2020/092740 patent/WO2020253490A1/en active Application Filing
Cited By (2)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
WO2020253490A1 (en) * | 2019-06-19 | 2020-12-24 | 深圳前海微众银行股份有限公司 | Resource allocation method, apparatus and device |
CN113949637A (en) * | 2021-10-28 | 2022-01-18 | 中国建设银行股份有限公司 | Intelligent distribution and deployment method and device for switch resources |
Also Published As
Publication number | Publication date |
---|---|
WO2020253490A1 (en) | 2020-12-24 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US20200364608A1 (en) | Communicating in a federated learning environment | |
US9525725B1 (en) | Client-initiated leader election in distributed client-server systems | |
CN106385329B (en) | Processing method, device and the equipment of resource pool | |
CN103365725B (en) | Method and system for dynamic allocation of workload deployment units across a plurality of clouds | |
CN110119303A (en) | Construct virtual mainboard and virtual memory facilities | |
CN106209402B (en) | A kind of telescopic method and equipment of virtual network function | |
US8695079B1 (en) | Allocating shared resources | |
CN105979007A (en) | Acceleration resource processing method and device and network function virtualization system | |
CN105872128B (en) | The distribution method and device of virtual ip address | |
CN110478898B (en) | Configuration method and device of virtual scene in game, storage medium and electronic equipment | |
CN110162407A (en) | A kind of method for managing resource and device | |
CN106716968A (en) | Account management method, device and account management system | |
CN110502732A (en) | A kind of rule generating method of discount coupon, device and server | |
CN110287025A (en) | A kind of resource allocation methods, device and equipment | |
CN109462508A (en) | Node deployment method, device and storage medium | |
CN105812423B (en) | A kind of cloud system configuration method, server and device | |
CN107580011A (en) | A kind of data sharing method and desktop cloud server terminal | |
CN107566270A (en) | The processing method and processing device that a kind of resource accesses | |
CN110826786A (en) | Method and device for predicting number of target place population and storage medium | |
CN106161389A (en) | Cheating identification method and device and terminal | |
CN104657216B (en) | The resource allocation methods and device of a kind of resource pool | |
CN106020732A (en) | Node disk space determining method and system | |
CN104750614B (en) | Method and apparatus for managing memory | |
CN107209643A (en) | SRM in virtualized environment | |
CN116074323B (en) | Edge computing node selection method, device, computer equipment and medium |
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 |