CN107045452A - Dispatching method of virtual machine and device - Google Patents
Dispatching method of virtual machine and device Download PDFInfo
- Publication number
- CN107045452A CN107045452A CN201610083785.2A CN201610083785A CN107045452A CN 107045452 A CN107045452 A CN 107045452A CN 201610083785 A CN201610083785 A CN 201610083785A CN 107045452 A CN107045452 A CN 107045452A
- Authority
- CN
- China
- Prior art keywords
- list
- frame
- server
- business
- virtual machine
- 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.)
- Granted
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/44—Arrangements for executing specific programs
- G06F9/455—Emulation; Interpretation; Software simulation, e.g. virtualisation or emulation of application or operating system execution engines
- G06F9/45533—Hypervisors; Virtual machine monitors
-
- 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/48—Program initiating; Program switching, e.g. by interrupt
- G06F9/4806—Task transfer initiation or dispatching
- G06F9/4843—Task transfer initiation or dispatching by program, e.g. task dispatcher, supervisor, operating system
- G06F9/485—Task life-cycle, e.g. stopping, restarting, resuming execution
- G06F9/4856—Task life-cycle, e.g. stopping, restarting, resuming execution resumption being on a different machine, e.g. task migration, virtual machine migration
Landscapes
- Engineering & Computer Science (AREA)
- Software Systems (AREA)
- Theoretical Computer Science (AREA)
- Physics & Mathematics (AREA)
- General Engineering & Computer Science (AREA)
- General Physics & Mathematics (AREA)
- Computer And Data Communications (AREA)
Abstract
This application discloses dispatching method of virtual machine and device.One embodiment of methods described includes:Obtain Servers-all list and all frame lists;The corresponding request for creating N number of virtual machine of acquisition business;The server list that the business has been used is obtained according to the business;The server list used according to the business obtains the frame list that the business has been used;The frame list used according to all frame lists and the business obtains the untapped frame list of business;According to the untapped frame list of the business, carry out n times scheduling with by N number of virtual machine creating in corresponding server.The embodiment is realized in the case where frame is enough, it is ensured that virtual machine is scheduled in different frames;In the case where frame is not enough, it can preferentially ensure that existing frame can all be used, then random schedule is in available frame for remaining virtual machine, so as to cause the disabled situation of business to occur when avoiding some frame from going wrong.
Description
Technical field
The application is related to field of computer technology, and in particular to Internet technical field, especially relates to
And dispatching method of virtual machine and and device.
Background technology
With continuing to develop for computer hardware and Internet technology, server is increasingly inclined to
In a variety of separate business of carrying, and virtual machine technique has just adapted to this demand.It is empty
Plan machine refer to by software simulate have complete hardware system function, operate in one completely
Complete computer in isolation environment.Scheduling virtual machine refers to that virtualization services provider is
User provides and meets resource requirement (if user is to CPU, internal memory, hard disk, the network bandwidth etc.
Demand) virtual machine, and by the virtual machine set up on hosts server, by the host
Server runs the virtual machine, is that this service provider needs to carry out effectively hosts server
Management and running, so as to ensure the service quality of virtual machine.
However, existing virtual machine scheduling policy can only be according to CPU, internal memory, hard disk, network
Bandwidth etc. carries out some basic scheduling.When user needs to create a collection of virtual machine for disposing certain
During individual business, these virtual machines are possible on the server that can be created in same frame, and one
The denier frame breaks down, and the virtual machine that may result in above is unavailable, so as to have influence on industry
The stability of business, seriously endangers the interests to user.
The content of the invention
The purpose of the application is to propose a kind of improved dispatching method of virtual machine and device, to solve
The technical problem that certainly background section above is mentioned.
In a first aspect, this application provides a kind of dispatching method of virtual machine, methods described includes:
Obtain Servers-all list and all frame lists;Acquisition business is corresponding to create N number of virtual
The request of machine;The server list that the business has been used is obtained according to the business;According to institute
State the server list that business used and obtain the frame list that the business has been used;According to institute
Stating the frame list that all frame lists and the business used, to obtain the business untapped
Frame list;According to the untapped frame list of the business, n times scheduling is carried out with will be N number of
Virtual machine creating is in corresponding server.
In certain embodiments, it is described according to the untapped frame list of the business, carry out N
Secondary scheduling is so that by N number of virtual machine creating, in corresponding server, each of which time scheduling includes:
Obtain virtual machine;Whether judge the untapped frame list of the business is empty, if it is,:
Servers-all in the Servers-all list is added in candidate server list;If
It is no, then:To Servers-all in the Servers-all list, frame where server is judged
Whether in the frame list that the business has been used, if it is not, then server is added into marquis
In election server list;If it is, continuing to judge next server;Taken according to the candidate
The status information of candidate server in device list of being engaged in sets weight side by side for each candidate server
Sequence, wherein, the status information of the candidate server is including at least one of following:CPU makes
With rate, memory usage, hard disk utilization rate;By weight highest in the candidate server list
Candidate server be used as optimal service device;The virtual machine is created in the optimal service device;
In the server list that the optimal service device has been used added to the business;By described in most
Frame where excellent server is deleted from the untapped frame list of the business.
In certain embodiments, the acquisition Servers-all list and all frame lists, bag
Include:All available server lists are obtained as Servers-all list, wherein, it is described can
Server is addressable server;Obtain each in all available server lists
The list of frame where individual server is used as all frame lists.
In certain embodiments, the server list used according to the business obtains institute
The frame list that business has been used is stated, including:Obtain the server list that the business has been used
In frame where each server the frame list that has been used as the business of list.
In certain embodiments, the machine used according to all frame lists and the business
Frame list obtains the untapped frame list of business, including:Acquisition has made the business
Frame list deleted from all frame lists after frame list, be used as the industry
It is engaged in untapped frame list.
Second aspect, this application provides a kind of scheduling virtual machine device, described device includes:
Servers-all and frame acquiring unit, are configured to obtain Servers-all list and institute are organic
Frame list;Business and virtual machine acquisition request unit, are configured to the corresponding establishment of acquisition business
The request of N number of virtual machine;Server acquiring unit is used, is configured to according to the business
Obtain the server list that the business has been used;Frame acquiring unit is used, is configured to
The server list used according to the business obtains the frame list that the business has been used;
Frame acquiring unit is not used, is configured to according to all frame lists and the business
The frame list used obtains the untapped frame list of business;Scheduling unit, configuration is used
Dispatch to create N number of virtual machine according to the untapped frame list of the business, carrying out n times
It build in corresponding server.
In certain embodiments, the scheduling unit performs scheduling each time and included:Virtual machine is obtained
Modulus block, is configured to obtain virtual machine;Candidate server List Generating Module, is configured to
Whether judge the untapped frame list of the business is empty, if it is,:Will be described all
Servers-all is added in candidate server list in server list;If it is not, then:It is right
Servers-all in the Servers-all list, whether frame is described where judging server
In the frame list that business has been used, if it is not, then server is arranged added to candidate server
In table;If it is, continuing to judge next server;Candidate server weight sets and sorted
Module, be configured to be according to the status information of candidate server in the candidate server list
Each candidate server sets weight and sorted, wherein, the status information of the candidate server
Including at least one of following:CPU usage, memory usage, hard disk utilization rate;It is optimal
Server determining module, is configured to weight highest candidate in the candidate server list
Server is used as optimal service device;Virtual machine creating module, is configured in the optimal service
The virtual machine is created in device;Add module, is configured to the optimal service device being added to
In the server list that the business has been used;Removing module, is configured to the optimal clothes
Frame where business device is deleted from the untapped frame list of the business.
In certain embodiments, the Servers-all and frame acquiring unit, including:It can use
Server list acquisition module, is configured to obtain all available server lists as all
Server list, wherein, the available server is addressable server;Institute's organic frame
List acquisition module, is configured to obtain the service of each in all available server lists
The list of frame where device is used as all frame lists.
In certain embodiments, it is described to be included using frame acquiring unit:Obtain the business
The list of frame in the server list used where each server as the business
The frame list used.
In certain embodiments, the unused frame acquiring unit includes:Obtain the industry
Be engaged in the frame list that has used deleted from all frame lists after frame list, as
The untapped frame list of business.
Dispatching method of virtual machine and device that the application is provided, by obtaining the corresponding establishment of business
The virtual machine request and the untapped frame list of business of N number of virtual machine, and enter on this basis
Row n times are dispatched, so that N number of virtual machine is created on corresponding optimal service device, are improved
The reliability of scheduling virtual machine.In the case where frame is enough, it is ensured that virtual machine is scheduled for
In different frames;In the case where frame is not enough, it can preferentially ensure that existing frame can all be made
With, remaining virtual machine, then random schedule is in available frame, so as to avoid some frame from going out
The disabled situation of business is caused to occur during existing problem.
Brief description of the drawings
Retouched by reading with reference to the detailed of being made to non-limiting example of being made of the following drawings
State, other features, objects and advantages will become more apparent upon:
Fig. 1 is that the application can apply to exemplary system architecture figure therein;
Fig. 2 is the flow chart of one embodiment of the dispatching method of virtual machine according to the application;
During Fig. 3 is the dispatching method of virtual machine according to the application, the once scheduling in n times scheduling
Flow chart;
Fig. 4 is the structural representation of one embodiment of the scheduling virtual machine device according to the application
Figure;
Fig. 5 is adapted for the structure of the computer system of the server for realizing the embodiment of the present application
Schematic diagram.
Embodiment
The application is described in further detail with reference to the accompanying drawings and examples.It is appreciated that
, specific embodiment described herein is used only for explaining related invention, rather than to the hair
Bright restriction.It also should be noted that, illustrate only for the ease of description, in accompanying drawing with
About the related part of invention.
It should be noted that in the case where not conflicting, embodiment and embodiment in the application
In feature can be mutually combined.Describe this in detail below with reference to the accompanying drawings and in conjunction with the embodiments
Application.
Fig. 1, which is shown, can apply the dispatching method of virtual machine or scheduling virtual machine device of the application
Embodiment exemplary system architecture 100.
As shown in figure 1, system architecture 100 can include frame 101,102,103, service
Device 1011,1012,1013,1021,1022,1031,1032, network 104 and virtual machine
Dispatch server 105.Network 104 be used to server 1011,1012,1013,1021,
The 1022nd, the medium of communication link is provided between 1031,1032 and scheduling virtual machine server 105.
Network 104 can include various connection types, such as wired, wireless communication link or optical fiber
Cable etc..
Server 1011,1012,1013 is located in frame 101, server 1021,1022
In frame 102, server 1031,1032 is located in frame 103.
Scheduling virtual machine server 105 by network 104 and server 1011,1012,1013,
1021st, 1022,1031,1032 interaction, to receive or send information, creates virtual machine etc..
Server 1011,1012,1013,1021,1022,1031,1032 can be had
It is the various electronic equipments of processor, including but not limited to smart mobile phone, tablet personal computer, on knee
Pocket computer and desktop computer etc..Above-mentioned server can receive scheduling virtual machine service
The message for the establishment virtual machine that device 105 is sent, and according to message establishing virtual machine.Above-mentioned service
Device can also be the database server for storage server, frame, business information etc..
Scheduling virtual machine server 105 can be to provide the server of various services, such as to clothes
Business device 1011,1012,1013,1021,1022,1031,1032, which is sent, creates virtual machine
Message, is dispatched between server 1011,1012,1013,1021,1022,1031,1032
Virtual machine, and the reception server 1011,1012,1013,1021,1022,1031,1032
The message of return.
It should be noted that the dispatching method of virtual machine that the embodiment of the present application is provided is general by void
Plan machine dispatch server 105 is performed, correspondingly, and scheduling virtual machine device is generally positioned at virtually
In machine dispatch server 105.
It should be understood that frame, server, network, scheduling virtual machine server in Fig. 1
Number is only schematical.According to needs are realized, can have any number of frame, clothes
Business device, network and scheduling virtual machine server.
With continued reference to Fig. 2, an implementation of the dispatching method of virtual machine according to the application is shown
The flow 200 of example.Described dispatching method of virtual machine, comprises the following steps:
Step 201, Servers-all list and all frame lists are obtained.
In the present embodiment, the electronic equipment of dispatching method of virtual machine operation thereon (is for example schemed
Scheduling virtual machine server 105 shown in 1) Servers-all row can be obtained from local data base
Table and all frame lists, can also be by wired connection mode or radio connection from depositing
Store up server (such as server 1011 shown in Fig. 1,1012,1013,1021,1022,
1031st, database 1032) obtains Servers-all list and all frame lists, wherein,
Above-mentioned server list includes server ID, server ip address, server performance and matches somebody with somebody confidence
Breath.As an example, above-mentioned server performance configuration includes the CPU, internal memory, hard disk of server
And network configuration information.Above-mentioned frame list includes frame id information.
In some optional implementations of the present embodiment, above-mentioned Servers-all list can be with
It is all available server lists, wherein, available server refers to addressable server,
Above-mentioned all frame lists are each server place in all available server lists accordingly
Frame list.
Step 202, the corresponding request for creating N number of virtual machine of business is obtained.
In the present embodiment, business it is corresponding create N number of virtual machine request can be from void
The user terminal of plan machine dispatch server (such as 105 in Fig. 1) connection is (in Fig. 1 not
Show) receive.Wherein, business includes traffic ID and business tine.Virtual machine request bag
The quantity N for creating virtual machine, each virtual machine are included on CPU, internal memory, hard disk and network
Demand information, wherein, N is positive integer.As an example, such as one purchases by group service request wound
Build 10 virtual machines.
Step 203, the server list that business has been used is obtained according to business.
In the present embodiment, the electronic equipment of dispatching method of virtual machine operation thereon can basis
The corresponding traffic ID of business obtained in step 202 is obtained from locally or remotely database should
The list for the server that business has been used.
Step 204, the server list used according to business obtains the frame that business has been used
List.
In the present embodiment, above-mentioned electronic equipment can be inquired about in locally or remotely database
Frame in the server list that the business obtained in step 203 has been used where each server
List, the frame list used as above-mentioned business.
Step 205, the frame list used according to all frame lists and business obtains business
Untapped frame list.
In the present embodiment, above-mentioned electronic equipment can be by the institute's organic frame obtained in step 201
The frame list that the business obtained in list in delete step 204 has been used, obtaining business does not make
Frame list.
Step 206, according to the untapped frame list of business, n times scheduling is carried out with will be N number of
Virtual machine creating is in corresponding server.
In the present embodiment, above-mentioned electronic equipment can be according to the business obtained in step 205 not
The frame list used, carry out n times scheduling, be scheduling to every time a virtual machine find it is suitable
Hosts server and the demand letter according to the virtual machine on CPU, internal memory, hard disk and network
Breath, by the virtual machine creating in above-mentioned suitable hosts server.
With further reference to Fig. 3, it illustrates in step 206 in dispatching method of virtual machine 200 one
The flow 300 of secondary scheduling.The flow 300 of the single dispatching method comprises the following steps:
Step 301, virtual machine is obtained.
In the present embodiment, the electronic equipment of dispatching method of virtual machine operation thereon (is for example schemed
Scheduling virtual machine server 105 shown in 1) virtual machine to be created is obtained every time and above-mentioned
Demand information of the virtual machine on CPU, internal memory, hard disk and network.
Step 302, whether judge the untapped frame list of business is empty.
In the present embodiment, the electronic equipment of dispatching method of virtual machine operation thereon (is for example schemed
Scheduling virtual machine server 105 shown in 1) judge the untapped frame list of business whether be
Sky, if sky, then goes to step 303;If being not sky, step 304 is gone to.
In some optional implementations of the present embodiment, dispatching method of virtual machine is run thereon
Electronic equipment (such as the scheduling virtual machine server 105 shown in Fig. 1) every time scheduling in
The candidate server list that last scheduling is produced can be all emptied before step 302 first, to treat
This dispatches assignment again.
Step 303, Servers-all in Servers-all list is arranged added to candidate server
In table.
In the present embodiment, the electronic equipment of dispatching method of virtual machine operation thereon (is for example schemed
Scheduling virtual machine server 105 shown in 1) by all clothes in the Servers-all list of acquisition
Business device goes to step 308 after adding in candidate server list.
Step 304, a server is taken from Servers-all list.
In the present embodiment, the electronic equipment of dispatching method of virtual machine operation thereon (is for example schemed
Scheduling virtual machine server 105 shown in 1) it can also sequentially can be arranged at random from Servers-all
A server is taken in table, however, which kind of mode all must assure that acquired server not using
Repeat and got the Servers-all in Servers-all list.
Step 305, judge frame where server whether the frame list used in business
In.
In the present embodiment, the electronic equipment of dispatching method of virtual machine operation thereon (is for example schemed
Scheduling virtual machine server 105 shown in 1) judge frame where server whether in business
In the frame list used.If going to step 306;If it was not then going to step
Rapid 307.
Step 306, step 305 is gone to after removing a server from Servers-all list.
In the present embodiment, the electronic equipment of dispatching method of virtual machine operation thereon (is for example schemed
Scheduling virtual machine server 105 shown in 1) removed from Servers-all list after a server
Step 305 is gone to, whether the frame where next server acquired by continuation judgement is in business
In the frame list used.
Step 307, server is added in candidate server list.
In the present embodiment, the electronic equipment of dispatching method of virtual machine operation thereon (is for example schemed
Scheduling virtual machine server 105 shown in 1) the place frame that judges step 305 is in business
Added using the server in frame list in candidate server list.
Step 308, it is each according to the status information of candidate server in candidate server list
Candidate server sets weight and sorted.
In the present embodiment, above-mentioned electronic equipment is according to candidate server in candidate server list
Status information set and weight and sort for each candidate server, wherein, candidate server
Status information includes at least one of following:CPU usage, memory usage, hard disk are used
Rate.In some optional implementations of the present embodiment, the status information of candidate server may be used also
With including:The network bandwidth, maximum memory, free memory, can with CPU numbers, can be empty with storage
Between, the VCPU of operation VCPU sums thereon and operation current virtual machine thereon
Number.It is that candidate server sets weight should also in some optional implementations of the present embodiment
Consider demand information of the virtual machine to be created on CPU, internal memory, hard disk and network.
Step 309, using weight highest candidate server in candidate server list as optimal
Server.
In the present embodiment, the electronic equipment of dispatching method of virtual machine operation thereon (is for example schemed
Scheduling virtual machine server 105 shown in 1) according to the ranking results of step 308, from candidate's clothes
Selection weight highest candidate server is used as optimal service device in business device list.
Step 310, virtual machine is created in optimal service device.
In the present embodiment, the virtual machine to be created that above-mentioned electronic equipment is obtained according to step 301
Demand information on CPU, internal memory, hard disk and network creates virtual machine in optimal service device.
It should be noted that the various methods of above-mentioned establishment virtual machine are widely studied at present and application
Known technology, will not be repeated here.
Step 311, in server list optimal service device used added to business.
In the present embodiment, the electronic equipment of dispatching method of virtual machine operation thereon (is for example schemed
Scheduling virtual machine server 105 shown in 1) by the optimal service device obtained in above-mentioned steps 309
In the server list used added to business.
Step 312, by the frame where optimal service device from the untapped frame list of business
Delete.
In the present embodiment, the electronic equipment of dispatching method of virtual machine operation thereon (is for example schemed
Scheduling virtual machine server 105 shown in 1) by the optimal service device obtained in above-mentioned steps 309
The frame at place is deleted from the untapped frame list of business.
With further reference to Fig. 4, as the realization to method shown in above-mentioned each figure, the application is provided
A kind of one embodiment of scheduling virtual machine device, the device embodiment and the side shown in Fig. 2
Method embodiment is corresponding, and the device specifically can apply in various electronic equipments.
As shown in figure 4, the scheduling virtual machine device 400 described in the present embodiment includes:
Servers-all and frame acquiring unit 401, business and virtual machine acquisition request unit
402nd, use frame acquiring unit 404 using server acquiring unit 403,, be not used
Frame acquiring unit 405 and scheduling unit 406.Wherein, Servers-all and frame obtain single
Member 401 is configured to obtain Servers-all list and all frame lists;Business and virtual machine
Acquisition request unit 402 is configured to the corresponding request for creating N number of virtual machine of acquisition business;
It is configured to made according to the above-mentioned business of above-mentioned business acquisition using server acquiring unit 403
Server list;It is configured to using frame acquiring unit 404 according to above-mentioned business
The server list used obtains the frame list that above-mentioned business has been used;Frame is not used to obtain
Unit 405 is configured to the row of racks used according to above-mentioned all frame lists and above-mentioned business
Table obtains the above-mentioned untapped frame list of business;Scheduling unit 406 is configured to according to above-mentioned
The untapped frame list of business, carry out n times scheduling with by N number of virtual machine creating corresponding
In server.
In the present embodiment, the Servers-all of scheduling virtual machine device 400 and frame obtain single
Member 401 can obtain Servers-all list and all frame lists from local data base, also may be used
With by wired connection mode or radio connection from the database for being stored in other servers
Servers-all list and all frame lists are obtained, wherein, above-mentioned server list includes clothes
Business device ID, server ip address, server performance configuration information.As an example, above-mentioned clothes
Business device performance configuration includes CPU, internal memory, hard disk and the network configuration information of server.It is above-mentioned
Frame list includes frame id information.
In the present embodiment, the business of scheduling virtual machine device 400 and virtual machine acquisition request list
Member 402 (can for example be schemed from scheduling virtual machine device 500 applied to electronic equipment therein
Scheduling virtual machine server 105 in 1) connection user terminal (not shown in Fig. 1) connect
Receipts business and virtual machine request.Wherein, business includes traffic ID and business tine.Virtual machine please
The quantity N including establishment virtual machine, each virtual machine are asked on CPU, internal memory, hard disk and net
The demand information of network, wherein, N is positive integer.
In the present embodiment, scheduling virtual machine device 400 use server acquiring unit 403
The corresponding traffic ID of business that can be obtained according to business and virtual machine acquisition request unit 402 from
The list for the server that the business has been used locally or remotely is obtained in database.
In the present embodiment, scheduling virtual machine device 400 use frame acquiring unit 404
It can be inquired about in locally or remotely database using acquisition in server acquiring unit 403
The server list that has used of business in frame where each server list, as upper
State the frame list that business has been used.
In the present embodiment, the unused frame acquiring unit 405 of scheduling virtual machine device 400
Being deleted in all frame lists that will be obtained in Servers-all and frame acquiring unit 401 has made
The frame list used with the business obtained in frame acquiring unit 404, obtaining business does not make
Frame list.
In the present embodiment, the scheduling unit 406 of scheduling virtual machine device 400 can be according to not
The untapped frame list of business obtained using frame acquiring unit 405, carries out n times scheduling,
Every time be scheduling to a virtual machine find suitable hosts server and according to the virtual machine on
CPU, internal memory, the demand information of hard disk and network, by the virtual machine creating above-mentioned suitable
In hosts server.
It will be understood by those skilled in the art that above-mentioned scheduling virtual machine device 400 also includes
Other known features, such as processor, memory, in order to unnecessarily obscure the disclosure
Embodiment, these known structures are not shown in Fig. 4.
Below with reference to Fig. 5, it illustrates suitable for for realizing the server of the embodiment of the present application
The structural representation of computer system 500.
As shown in figure 5, computer system 500 includes CPU (CPU) 501, its
Can according to the program being stored in read-only storage (ROM) 502 or from storage part 508
The program that is loaded into random access storage device (RAM) 503 and perform various appropriate actions
And processing.In RAM 503, the system that is also stored with 500 operates required various program sums
According to.CPU 501, ROM 502 and RAM 503 are connected with each other by bus 504.Input
/ output (I/O) interface 505 is also connected to bus 504.
I/O interfaces 505 are connected to lower component:Importation 506 including keyboard, mouse etc.;
Including cathode-ray tube (CRT), liquid crystal display (LCD) etc. and loudspeaker etc.
Output par, c 507;Storage part 508 including hard disk etc.;And including such as LAN card,
The communications portion 509 of the NIC of modem etc..Communications portion 509 is via such as
The network of internet performs communication process.Driver 510 is also according to needing to be connected to I/O interfaces
505.Detachable media 511, such as disk, CD, magneto-optic disk, semiconductor memory etc.,
Be arranged on as needed on driver 510, in order to the computer program that reads from it according to
Need to be mounted into storage part 508.
Especially, in accordance with an embodiment of the present disclosure, the process described above with reference to flow chart can be with
It is implemented as computer software programs.For example, embodiment of the disclosure includes a kind of computer journey
Sequence product, it includes being tangibly embodied in the computer program on machine readable media, the meter
Calculation machine program bag, which contains, is used for the program code of the method shown in execution flow chart.Implement such
In example, the computer program can be downloaded and installed by communications portion 509 from network,
And/or be mounted from detachable media 511.In the computer program by CPU
(CPU) during 501 execution, the above-mentioned functions limited in the present processes are performed.
Flow chart and block diagram in accompanying drawing, it is illustrated that according to the system of the various embodiments of the application,
Architectural framework in the cards, function and the operation of method and computer program product.This point
On, each square frame in flow chart or block diagram can represent a module, program segment or code
A part, the part of the module, program segment or code is used for comprising one or more
The executable instruction of logic function as defined in realizing.It should also be noted that being used as replacement at some
In realization, the function of being marked in square frame can also be with different from the order marked in accompanying drawing hair
It is raw.For example, two square frames succeedingly represented can essentially be performed substantially in parallel, they
Sometimes it can also perform in the opposite order, this is depending on involved function.It is also noted that
It is, each square frame in block diagram and/or flow chart and the square frame in block diagram and/or flow chart
Combination, can be realized with the special hardware based system of defined function or operation is performed,
Or can be realized with the combination of specialized hardware and computer instruction.
Being described in unit involved in the embodiment of the present application can be real by way of software
It is existing, it can also be realized by way of hardware.Described unit can also be arranged on processing
In device, for example, can be described as:A kind of processor includes Servers-all and frame obtains single
Member, business and virtual machine acquisition request unit, using server acquiring unit, use machine
Frame acquiring unit, unused frame acquiring unit and scheduling unit.Wherein, the name of these units
Claim not constituting the restriction to the unit in itself under certain conditions, for example, scheduling unit may be used also
To be described as " unit of scheduling virtual machine ".
As on the other hand, present invention also provides a kind of nonvolatile computer storage media,
The nonvolatile computer storage media can be described in above-described embodiment included in device
Nonvolatile computer storage media;Can also be individualism, without non-in supplying terminal
Volatile computer storage medium.Above-mentioned nonvolatile computer storage media be stored with one or
The multiple programs of person, when one or more of programs are performed by an equipment so that described
Equipment:Obtain Servers-all list and all frame lists;The corresponding establishment N of acquisition business
The request of individual virtual machine;The server list that the business has been used is obtained according to the business;
The server list used according to the business obtains the frame list that the business has been used;
The frame list used according to all frame lists and the business obtains the business not
The frame list used;According to the untapped frame list of the business, carry out n times scheduling with
By N number of virtual machine creating in corresponding server.
Above description is only the preferred embodiment of the application and saying to institute's application technology principle
It is bright.It will be appreciated by those skilled in the art that invention scope involved in the application, is not limited
In the technical scheme of the particular combination of above-mentioned technical characteristic, do not departed from while should cover yet
In the case of the inventive concept, it is combined by above-mentioned technical characteristic or its equivalent feature
Formed by other technical schemes.Such as features described above and (but not limited to) disclosed herein
Technical characteristic with similar functions carries out technical scheme formed by replacement mutually.
Claims (10)
1. a kind of dispatching method of virtual machine, it is characterised in that methods described includes:
Obtain Servers-all list and all frame lists;
The corresponding request for creating N number of virtual machine of acquisition business;
The server list that the business has been used is obtained according to the business;
The server list used according to the business obtains the row of racks that the business has been used
Table;
The frame list used according to all frame lists and the business obtains the industry
It is engaged in untapped frame list;
According to the untapped frame list of the business, n times scheduling is carried out with by N number of virtual machine
Create in corresponding server.
2. dispatching method of virtual machine according to claim 1, it is characterised in that described
According to the untapped frame list of the business, carry out n times scheduling N number of virtual machine creating exists
In corresponding server, each of which time scheduling includes:
Obtain virtual machine;
Whether judge the untapped frame list of the business is empty, if it is,:
Servers-all in the Servers-all list is added in candidate server list;
If it is not, then:
To Servers-all in the Servers-all list, whether frame where judging server
In the frame list that the business has been used, if it is not, then server is taken added to candidate
It is engaged in device list;If it is, continuing to judge next server;
Taken according to the status information of candidate server in the candidate server list for each candidate
Business device sets weight and sorted, wherein, the status information of the candidate server is included below extremely
One item missing:CPU usage, memory usage, hard disk utilization rate;
It regard weight highest candidate server in the candidate server list as optimal service
Device;
The virtual machine is created in the optimal service device;
In the server list that the optimal service device has been used added to the business;
Frame where the optimal service device is deleted from the untapped frame list of the business
Remove.
3. dispatching method of virtual machine according to claim 1, it is characterised in that described to obtain
Servers-all list and all frame lists are taken, including:
All available server lists are obtained as Servers-all list, wherein, it is described can
Server is addressable server;
Obtain the list of the frame in all available server lists where each server
It is used as all frame lists.
4. dispatching method of virtual machine according to claim 1, it is characterised in that described
The server list used according to the business obtains the frame list that the business has been used, bag
Include:
Obtain the row of the frame in the server list that the business has been used where each server
The frame list that table has been used as the business.
5. dispatching method of virtual machine according to claim 1, it is characterised in that described
The frame list used according to all frame lists and the business, which obtains the business, not to be made
Frame list, including:
After the frame list that acquisition has used the business is deleted from all frame lists
Frame list, be used as the untapped frame list of the business.
6. a kind of scheduling virtual machine device, it is characterised in that described device includes:
Servers-all and frame acquiring unit, are configured to obtain Servers-all list and institute
Organic frame list;
Business and virtual machine acquisition request unit, are configured to the corresponding establishment of acquisition business N number of
The request of virtual machine;
Server acquiring unit is used, is configured to obtain the business according to the business
The server list used;
Frame acquiring unit is used, is configured to the server row used according to the business
Table obtains the frame list that the business has been used;
Frame acquiring unit is not used, is configured to according to all frame lists and the industry
The frame list for being engaged in having used obtains the untapped frame list of business;
Scheduling unit, is configured to, according to the untapped frame list of the business, carry out n times
Scheduling with by N number of virtual machine creating in corresponding server.
7. scheduling virtual machine device according to claim 6, it is characterised in that the tune
Degree unit, which performs scheduling each time, to be included:
Virtual machine acquisition module, is configured to obtain virtual machine;
Candidate server List Generating Module, is configured to judge the untapped frame of the business
Whether list is empty, if it is,:
Servers-all in the Servers-all list is added in candidate server list;
If it is not, then:
To Servers-all in the Servers-all list, whether frame where judging server
In the frame list that the business has been used;If it is not, then server is taken added to candidate
It is engaged in device list;If it is, continuing to judge next server;
Candidate server weight is set and order module, is configured to according to the candidate server
The status information of candidate server is that each candidate server sets weight and sorted in list, its
In, the status information of the candidate server is including at least one of following:CPU usage,
Memory usage, hard disk utilization rate;
Optimal service device determining module, is configured to weight in the candidate server list most
High candidate server is used as optimal service device;
Virtual machine creating module, is configured to create the virtual machine in the optimal service device;
Add module, is configured to used the optimal service device added to the business
In server list;
Removing module, be configured to by the frame where the optimal service device from the business not
Deleted in the frame list used.
8. scheduling virtual machine device according to claim 6, it is characterised in that the institute
There are server and frame acquiring unit, including:
Available server list acquisition module, is configured to obtain all available server lists
As Servers-all list, wherein, the available server is addressable server;
All frame list acquisition modules, are configured to obtain all available server row
The list of frame where the server of each in table is used as all frame lists.
9. scheduling virtual machine device according to claim 6, it is characterised in that it is described
Included using frame acquiring unit:
Obtain the row of the frame in the server list that the business has been used where each server
The frame list that table has been used as the business.
10. scheduling virtual machine device according to claim 6, it is characterised in that described
Frame acquiring unit, which is not used, to be included:
After the frame list that acquisition has used the business is deleted from all frame lists
Frame list, be used as the untapped frame list of the business.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610083785.2A CN107045452B (en) | 2016-02-06 | 2016-02-06 | Virtual machine scheduling method and device |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
CN201610083785.2A CN107045452B (en) | 2016-02-06 | 2016-02-06 | Virtual machine scheduling method and device |
Publications (2)
Publication Number | Publication Date |
---|---|
CN107045452A true CN107045452A (en) | 2017-08-15 |
CN107045452B CN107045452B (en) | 2019-12-31 |
Family
ID=59543030
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
CN201610083785.2A Active CN107045452B (en) | 2016-02-06 | 2016-02-06 | Virtual machine scheduling method and device |
Country Status (1)
Country | Link |
---|---|
CN (1) | CN107045452B (en) |
Cited By (3)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN109656683A (en) * | 2018-12-10 | 2019-04-19 | 郑州云海信息技术有限公司 | A kind of virtual machine management system and method |
CN110515693A (en) * | 2019-07-26 | 2019-11-29 | 浪潮电子信息产业股份有限公司 | A kind of method and system that the virtual machine based on rack perception is extending transversely |
CN111836274A (en) * | 2019-04-17 | 2020-10-27 | 大唐移动通信设备有限公司 | Service processing method and device |
Citations (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102843418A (en) * | 2012-07-03 | 2012-12-26 | 广东电网公司信息中心 | Resource dispatching system |
CN102981907A (en) * | 2011-06-30 | 2013-03-20 | 国际商业机器公司 | System and method for virtual machine allocation |
CN103797462A (en) * | 2013-10-23 | 2014-05-14 | 华为技术有限公司 | Method, system, and device for creating virtual machine |
CN103812789A (en) * | 2013-09-18 | 2014-05-21 | 广东电网公司佛山供电局 | Cloud service resource automatic allocating method and system |
CN104639594A (en) * | 2013-11-15 | 2015-05-20 | 中国电信股份有限公司 | System and method for allocating physical resources and virtual resources |
CN104660690A (en) * | 2015-02-06 | 2015-05-27 | 中国农业大学 | Cloud video service monitoring system |
CN105242990A (en) * | 2015-10-28 | 2016-01-13 | 浪潮(北京)电子信息产业有限公司 | Cloud platform based data backup method and apparatus |
-
2016
- 2016-02-06 CN CN201610083785.2A patent/CN107045452B/en active Active
Patent Citations (7)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN102981907A (en) * | 2011-06-30 | 2013-03-20 | 国际商业机器公司 | System and method for virtual machine allocation |
CN102843418A (en) * | 2012-07-03 | 2012-12-26 | 广东电网公司信息中心 | Resource dispatching system |
CN103812789A (en) * | 2013-09-18 | 2014-05-21 | 广东电网公司佛山供电局 | Cloud service resource automatic allocating method and system |
CN103797462A (en) * | 2013-10-23 | 2014-05-14 | 华为技术有限公司 | Method, system, and device for creating virtual machine |
CN104639594A (en) * | 2013-11-15 | 2015-05-20 | 中国电信股份有限公司 | System and method for allocating physical resources and virtual resources |
CN104660690A (en) * | 2015-02-06 | 2015-05-27 | 中国农业大学 | Cloud video service monitoring system |
CN105242990A (en) * | 2015-10-28 | 2016-01-13 | 浪潮(北京)电子信息产业有限公司 | Cloud platform based data backup method and apparatus |
Cited By (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
CN109656683A (en) * | 2018-12-10 | 2019-04-19 | 郑州云海信息技术有限公司 | A kind of virtual machine management system and method |
CN111836274A (en) * | 2019-04-17 | 2020-10-27 | 大唐移动通信设备有限公司 | Service processing method and device |
CN111836274B (en) * | 2019-04-17 | 2022-01-25 | 大唐移动通信设备有限公司 | Service processing method and device |
CN110515693A (en) * | 2019-07-26 | 2019-11-29 | 浪潮电子信息产业股份有限公司 | A kind of method and system that the virtual machine based on rack perception is extending transversely |
Also Published As
Publication number | Publication date |
---|---|
CN107045452B (en) | 2019-12-31 |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
CN107846465A (en) | Update the method and apparatus of client resource bag | |
CN106708537A (en) | Application updating method and application updating device | |
CN108182111A (en) | Task scheduling system, method and apparatus | |
CN106331150A (en) | Method and device for scheduling cloud servers | |
CN106201661A (en) | Method and apparatus for elastic telescopic cluster virtual machine | |
CN109685301A (en) | Method for managing resource, device, equipment and readable storage medium storing program for executing | |
CN107369055A (en) | The picking distribution method and device of order messages | |
CN104765609B (en) | Software context resource recommendation method, acquisition methods and corresponding device | |
CN110532059B (en) | Quota management method and device for K8s cluster management software | |
CN109635986A (en) | Shops's method for pushing, device, equipment and storage medium | |
CN107919971A (en) | Method, apparatus and system for audio/video communication connection disaster tolerance | |
CN108256006A (en) | A kind of direct broadcasting room badge picture loading method and system | |
CN107291769A (en) | The method and apparatus for handling concurrent order | |
CN107045452A (en) | Dispatching method of virtual machine and device | |
CN106101256A (en) | Method and apparatus for synchrodata | |
CN110288276A (en) | Method and apparatus for generating information | |
CN115994079A (en) | Test method, test device, electronic apparatus, storage medium, and program product | |
CN107368407A (en) | Information processing method and device | |
CN112364005A (en) | Data synchronization method and device, computer equipment and storage medium | |
CN111428463A (en) | Short message processing method and device, electronic equipment and storage medium | |
CN110764911A (en) | Resource scheduling method, device and control system based on order | |
CN107679871B (en) | List management method, device, system and computer readable storage medium | |
CN108228355A (en) | Task processing method and device, method for scheduling task and device | |
CN107770227A (en) | The distribution processing method and device of service request | |
CN103534681A (en) | Method, device and system for deploying application process |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
PB01 | Publication | ||
PB01 | Publication | ||
SE01 | Entry into force of request for substantive examination | ||
SE01 | Entry into force of request for substantive examination | ||
GR01 | Patent grant | ||
GR01 | Patent grant |