CN102890640A - System and method for managing virtual machine - Google Patents
System and method for managing virtual machine Download PDFInfo
- Publication number
- CN102890640A CN102890640A CN2011102003903A CN201110200390A CN102890640A CN 102890640 A CN102890640 A CN 102890640A CN 2011102003903 A CN2011102003903 A CN 2011102003903A CN 201110200390 A CN201110200390 A CN 201110200390A CN 102890640 A CN102890640 A CN 102890640A
- Authority
- CN
- China
- Prior art keywords
- virtual machine
- type
- data
- client computer
- control instruction
- 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
Images
Landscapes
- Information Retrieval, Db Structures And Fs Structures Therefor (AREA)
Abstract
一种虚拟机管理系统及方法,该方法包括步骤:向客户端电脑下达控制指令;判断该控制指令的类型,所述控制指令的类型包括第一类型和第二类型;当该控制指令的类型是第一类型且该控制指令是查询虚拟机资料时,从控制电脑的数据库中获取客户端电脑的第一类型虚拟机资料;当该控制指令的类型是第二类型时,将该第二类型的控制指令传送给客户端电脑的虚拟机管理程序;获取客户端电脑的虚拟机管理程序返回的第二类型虚拟机资料。利用本发明可以加快获取客户端电脑虚拟机资料的时间。
A virtual machine management system and method, the method comprising the steps of: issuing a control instruction to a client computer; judging the type of the control instruction, the type of the control instruction includes a first type and a second type; when the type of the control instruction is the first type and the control instruction is to query virtual machine information, obtain the first type virtual machine information of the client computer from the database of the control computer; when the type of the control instruction is the second type, the second type The control instruction is sent to the virtual machine management program of the client computer; and the second type virtual machine information returned by the virtual machine management program of the client computer is obtained. Utilizing the invention can speed up the time for obtaining the data of the virtual machine of the client computer.
Description
技术领域 technical field
本发明涉及一种虚拟机管理系统及方法。The invention relates to a virtual machine management system and method.
背景技术 Background technique
传统的虚拟机(Virtual Machine,VM)管理,通常通过服务器上安装的虚拟机管理模组,远程管理不同客户端电脑上安装的虚拟机。服务器通过该虚拟机管理模组,向指定的客户端电脑发送控制指令,并获取指定客户端电脑的虚拟机管理程序返回的虚拟机资料。Traditional virtual machine (Virtual Machine, VM) management usually remotely manages virtual machines installed on different client computers through a virtual machine management module installed on a server. Through the virtual machine management module, the server sends a control command to the designated client computer, and obtains the virtual machine data returned by the virtual machine management program of the designated client computer.
但是,当虚拟机管理模组频繁地与某客户端电脑进行指令传送,或者多个虚拟机管理模组同时对该客户端电脑进行指令操作时,可能造成该客户端电脑的虚拟机管理程序对虚拟机的管理服务停止或资源锁定,进而造成指令失效或等待时间延长等问题。However, when the virtual machine management module frequently transmits instructions to a certain client computer, or when multiple virtual machine management modules perform instruction operations on the client computer at the same time, it may cause the virtual machine management program of the client computer to The management service of the virtual machine is stopped or resources are locked, which causes problems such as command failure or extended waiting time.
发明内容 Contents of the invention
鉴于以上内容,有必要提供一种虚拟机管理系统,其可加快获取客户端电脑虚拟机资料的时间,减少对客户端电脑的指令操作。In view of the above, it is necessary to provide a virtual machine management system, which can speed up the time to obtain the data of the virtual machine of the client computer, and reduce the command operations on the client computer.
鉴于以上内容,有必要提供一种虚拟机管理方法,其可加快获取客户端电脑虚拟机资料的时间,减少对客户端电脑的指令操作。In view of the above, it is necessary to provide a virtual machine management method, which can speed up the time to obtain the data of the virtual machine of the client computer and reduce the command operations on the client computer.
一种虚拟机管理系统,该系统包括:A virtual machine management system, the system includes:
指令发送模块,用于向客户端电脑下达控制指令;The instruction sending module is used to issue control instructions to the client computer;
指令判断模块,用于判断该控制指令的类型,所述控制指令的类型包括第一类型和第二类型;An instruction judging module, configured to judge the type of the control instruction, where the types of the control instruction include a first type and a second type;
资料获取模块,用于当该控制指令的类型是第一类型且该控制指令是查询虚拟机资料时,从控制电脑的数据库中获取客户端电脑的第一类型虚拟机资料;A data acquisition module, used to obtain the first type of virtual machine data of the client computer from the database of the control computer when the type of the control command is the first type and the control command is to query virtual machine data;
所述指令发送模块,还用于当该控制指令的类型是第二类型时,将该第二类型的控制指令传送给客户端电脑的虚拟机管理程序;及The instruction sending module is further configured to send the second type of control instruction to the virtual machine management program of the client computer when the type of the control instruction is the second type; and
所述资料获取模块,还用于获取客户端电脑的虚拟机管理程序返回的第二类型虚拟机资料。The data obtaining module is also used to obtain the second type virtual machine data returned by the virtual machine management program of the client computer.
一种虚拟机管理方法,该方法包括如下步骤:A virtual machine management method, the method comprising the steps of:
指令发送步骤一,向客户端电脑下达控制指令;Instruction sending step 1, issuing control instructions to the client computer;
指令判断步骤,判断该控制指令的类型,所述控制指令的类型包括第一类型和第二类型;Instruction judging step, judging the type of the control instruction, the type of the control instruction includes the first type and the second type;
资料获取步骤一,当该控制指令的类型是第一类型且该控制指令是查询虚拟机资料时,从控制电脑的数据库中获取客户端电脑的第一类型虚拟机资料;Data acquisition step 1, when the type of the control command is the first type and the control command is to query virtual machine data, obtain the first type of virtual machine data of the client computer from the database of the control computer;
指令发送步骤二,当该控制指令的类型是第二类型时,将该第二类型的控制指令传送给客户端电脑的虚拟机管理程序;及Instruction sending step 2, when the type of the control instruction is the second type, sending the second type of control instruction to the virtual machine management program of the client computer; and
资料获取步骤二,获取客户端电脑的虚拟机管理程序返回的第二类型虚拟机资料。In the second step of obtaining data, the data of the second type virtual machine returned by the virtual machine management program of the client computer is obtained.
前述方法可以由电子设备(如电脑)执行,其中该电子设备具有附带了图形用户界面(GUI)的显示屏幕、一个或多个处理器、存储器以及保存在存储器中用于执行这些方法的一个或多个模块、程序或指令集。在某些实施例中,该电子设备提供了包括无线通信在内的多种功能。The foregoing methods can be performed by electronic equipment (such as a computer), wherein the electronic equipment has a display screen with a graphical user interface (GUI), one or more processors, memory, and one or more programs stored in the memory for performing these methods. Multiple modules, programs or sets of instructions. In some embodiments, the electronic device provides multiple functions including wireless communication.
用于执行前述方法的指令可以包含在被配置成由一个或多个处理器执行的计算机程序产品中。Instructions for performing the foregoing methods may be embodied in a computer program product configured to be executed by one or more processors.
相较于现有技术,所述的虚拟机管理系统及方法,其可加快获取客户端电脑虚拟机资料的时间,减少对客户端电脑的指令操作,从而防止由于客户端电脑指令过多造成的指令失效或等待时间延长等问题。Compared with the prior art, the virtual machine management system and method described above can speed up the time to obtain the data of the virtual machine of the client computer, reduce the instruction operations on the client computer, thereby preventing the failure caused by too many client computer instructions. Issues such as invalid order or extended waiting time.
附图说明 Description of drawings
图1是本发明控制电脑的应用环境示意图。Fig. 1 is a schematic diagram of the application environment of the control computer of the present invention.
图2是本发明控制电脑的结构示意图。Fig. 2 is a structural schematic diagram of the control computer of the present invention.
图3是虚拟机管理系统的功能模块图。Fig. 3 is a functional block diagram of the virtual machine management system.
图4是本发明虚拟机管理方法的较佳实施例的流程图。Fig. 4 is a flow chart of a preferred embodiment of the virtual machine management method of the present invention.
主要元件符号说明Description of main component symbols
具体实施方式 Detailed ways
如图1所示,是本发明控制电脑的应用环境示意图。在本实施例中,所述控制电脑2通过网络4与多个客户端电脑5相连,并通过数据库连接与数据库3相连。所述网络4可以是企业内部网(Intranet),也可以是互联网(Internet)或其它类型的通讯网络,如GPRS、Wi-Fi/WLAN、3G/WCDMA、3.5G/HSDPA等。As shown in FIG. 1 , it is a schematic diagram of the application environment of the control computer of the present invention. In this embodiment, the control computer 2 is connected to a plurality of client computers 5 through a network 4 and connected to a database 3 through a database connection. The network 4 can be an intranet, the Internet or other types of communication networks, such as GPRS, Wi-Fi/WLAN, 3G/WCDMA, 3.5G/HSDPA, etc.
所述控制电脑2用于发送控制指令给客户端电脑5,并根据该控制指令的类型从数据库3或者客户端电脑5获取虚拟机(VirtualMachine,VM)的资料。The control computer 2 is used to send a control command to the client computer 5, and obtain virtual machine (Virtual Machine, VM) information from the database 3 or the client computer 5 according to the type of the control command.
所述数据库3用于存储客户端电脑5上各虚拟机的资料及用户自定义的资料等。其中,所述虚拟机资料包括,但不限于,虚拟机的名字、标识符(Identifier,ID)、使用的操作系统(Operating System,OS)及备注信息等。所述用户自定义资料为用户自定义的文件夹,用于存储客户端电脑的标识符和描述信息等。例如,用户可以将客户端电脑Host1、Host2、Host3、Host4、Host5的标识符及描述信息存储于文件夹1(如Folder 1),将客户端电脑Host6、Host7、Host8、Host9、Host10的标识符及描述信息存储于文件夹2(如Folder2),以方便对客户端电脑的管理。The database 3 is used to store data of each virtual machine on the client computer 5 and user-defined data. Wherein, the virtual machine information includes, but is not limited to, the name of the virtual machine, an identifier (Identifier, ID), an operating system (Operating System, OS) used, and remark information. The user-defined data is a user-defined folder for storing identifiers and description information of the client computer. For example, the user can store the identifiers and description information of the client computers Host1, Host2, Host3, Host4, and Host5 in Folder 1 (such as Folder 1), and store the identifiers of the client computers Host6, Host7, Host8, Host9, and Host10 and description information are stored in folder 2 (such as Folder2) to facilitate the management of the client computer.
参阅图2所示,该控制电脑2包括通过数据总线相连的显示设备20、输入设备22、存储器23、虚拟机管理系统24和处理器25。Referring to FIG. 2 , the control computer 2 includes a
所述存储器23用于存储所述虚拟机管理系统24的程序代码等资料。所述显示设备20用于显示客户端电脑5的虚拟机资料等。所述输入设备22用于输入用户设置的各种数据,如客户端电脑的描述信息等。The
所述虚拟机管理系统24用于发送控制指令给客户端电脑5,并根据该控制指令的类型从数据库3或者客户端电脑5获取虚拟机资料,具体过程以下描述。The virtual
在本实施例中,所述虚拟机管理系统24可以被分割成一个或多个模块,所述一个或多个模块被存储在所述存储器23中并被配置成由一个或多个处理器(本实施例为一个处理器25)执行,以完成本发明。例如,参阅图3所示,所述虚拟机管理系统24被分割成指令发送模块201、指令判断模块202、资料获取模块203和资料更新模块204。本发明所称的模块是完成一特定功能的程序段,比程序更适合于描述软件在控制电脑2中的执行过程。In this embodiment, the virtual
如图4所示,是本发明虚拟机管理方法的较佳实施例的流程图。As shown in FIG. 4 , it is a flow chart of a preferred embodiment of the virtual machine management method of the present invention.
步骤S10,指令发送模块201向客户端电脑5下达控制指令。Step S10 , the instruction sending
步骤S11,指令判断模块202判断该控制指令的类型。在本实施例中,所述控制指令的类型包括第一类型和第二类型。其中,第一类型的控制指令是指,查询或更新不经常改变的虚拟机资料,如虚拟机的名字。第二类型的控制指令是指,查询随时改变的虚拟机资料,如虚拟机的CPU使用率。如果该控制指令的类型是第一类型,则执行步骤S21-S25;如果该控制指令的类型是第二类型,则执行步骤S31-S33。In step S11, the
步骤S21,如果该控制指令的类型是第一类型,则指令判断模块202判断该控制指令是查询虚拟机资料还是更新虚拟机资料。如果该控制指令是查询虚拟机资料,则执行步骤S22;如果该控制指令是更新虚拟机资料,则执行步骤S23。Step S21, if the type of the control instruction is the first type, the
步骤S22,资料获取模块203直接从数据库3中获取客户端电脑5的第一类型虚拟机资料(如虚拟机的名字),然后执行步骤S25。在本实施例中,该第一类型的虚拟机资料为不经常改变的虚拟机资料,如虚拟机名字。由于第一类型的虚拟机资料可以从数据库3中直接读取,所以能够加快获取客户端电脑5虚拟机资料的时间,并减少对客户端电脑5的指令操作。In step S22, the
步骤S23,指令发送模块201将该第一类型的控制指令传送给客户端电脑5的虚拟机管理程序(如Hypervisor程序),以执行该控制指令。客户端电脑5的虚拟机管理程序根据该第一类型控制指令,更新客户端电脑5的虚拟机资料(如虚拟机名字),并将更新后的虚拟机资料传送给控制电脑2。In step S23, the
步骤S24,资料获取模块203获取客户端电脑5的虚拟机管理程序返回的更新后的虚拟机资料。然后,资料更新模块204根据该更新后的虚拟机资料更新数据库3中对应的虚拟机资料。In step S24, the
步骤S25,资料获取模块203获取该第一类型控制指令的执行结果。在本实施例中,所述第一类型控制指令的执行结果包括执行成功或执行失败。例如,如果步骤22从数据库3中获取客户端电脑5的虚拟机名字失败,则执行结果为查询名字失败。如果步骤S24更新数据库3中的虚拟机名字失败,则执行结果为更新名字失败。In step S25, the
步骤S31,如果该控制指令的类型是第二类型,则指令发送模块201将该第二类型的控制指令传送给客户端电脑5的虚拟机管理程序,以执行该控制指令。客户端电脑5的虚拟机管理程序根据该控制指令,获取第二类型的虚拟机资料(如虚拟机的CPU使用率),并将获取的虚拟机资料传送给控制电脑2。在本实施例中,该第二类型的虚拟机资料为随时改变的虚拟机资料,如虚拟机的CPU使用率。Step S31 , if the type of the control instruction is the second type, the
步骤S32,资料获取模块203获取客户端电脑5的虚拟机管理程序返回的第二类型虚拟机资料。在本实施例中,由于第二类型虚拟机资料可能随时改变,所以不会存储在数据库3中。In step S32, the
步骤S33,资料获取模块203获取该第二类型控制指令的执行结果。在本实施例中,所述第二类型控制指令的执行结果包括执行成功或执行失败。例如,如果步骤32获取虚拟机的CPU使用率失败,则执行结果为查询CPU使用率失败。In step S33, the
最后应说明的是,以上实施例仅用以说明本发明的技术方案而非限制,尽管参照较佳实施例对本发明进行了详细说明,本领域的普通技术人员应当理解,可以对本发明的技术方案进行修改或等同替换,而不脱离本发明技术方案的精神和范围。Finally, it should be noted that the above embodiments are only used to illustrate the technical solutions of the present invention without limitation. Although the present invention has been described in detail with reference to the preferred embodiments, those of ordinary skill in the art should understand that the technical solutions of the present invention can be Modifications or equivalent replacements can be made without departing from the spirit and scope of the technical solutions of the present invention.
Claims (10)
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN2011102003903A CN102890640A (en) | 2011-07-18 | 2011-07-18 | System and method for managing virtual machine |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| CN2011102003903A CN102890640A (en) | 2011-07-18 | 2011-07-18 | System and method for managing virtual machine |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| CN102890640A true CN102890640A (en) | 2013-01-23 |
Family
ID=47534148
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| CN2011102003903A Pending CN102890640A (en) | 2011-07-18 | 2011-07-18 | System and method for managing virtual machine |
Country Status (1)
| Country | Link |
|---|---|
| CN (1) | CN102890640A (en) |
Citations (3)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN1648880A (en) * | 2004-10-19 | 2005-08-03 | 威盛电子股份有限公司 | Computer system internal data access method and related device |
| US20070130388A1 (en) * | 2005-11-21 | 2007-06-07 | Samsung Electronics Co., Ltd. | Apparatus and method to record/read data on/from recording medium |
| CN101893998A (en) * | 2009-05-18 | 2010-11-24 | 英业达股份有限公司 | Access Control Method for Motherboard and Memory |
-
2011
- 2011-07-18 CN CN2011102003903A patent/CN102890640A/en active Pending
Patent Citations (3)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| CN1648880A (en) * | 2004-10-19 | 2005-08-03 | 威盛电子股份有限公司 | Computer system internal data access method and related device |
| US20070130388A1 (en) * | 2005-11-21 | 2007-06-07 | Samsung Electronics Co., Ltd. | Apparatus and method to record/read data on/from recording medium |
| CN101893998A (en) * | 2009-05-18 | 2010-11-24 | 英业达股份有限公司 | Access Control Method for Motherboard and Memory |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| US10678601B2 (en) | Orchestration service for multi-step recipe composition with flexible, topology-aware, and massive parallel execution | |
| CN103677858B (en) | Method, system and the equipment of software virtual machine management in a kind of cloud environment | |
| CN105516266B (en) | A business monitoring method, system and related equipment | |
| WO2017008578A1 (en) | Data check method and device in network function virtualization framework | |
| WO2020133609A1 (en) | Server abnormality processing method and management device | |
| WO2019169765A1 (en) | Electronic device, method for acquiring state information in cluster environment, system, and storage medium | |
| CN105426234A (en) | Deadlock detection method and apparatus for database | |
| CN105279071A (en) | A virtual machine performance data collection method, system and cloud computing platform | |
| CN104618161A (en) | Application cluster monitoring device and method | |
| CN110278101B (en) | Resource management method and equipment | |
| TW201305912A (en) | System and method for managing virtual machines | |
| CN114721686A (en) | Configuration data updating method and device, electronic equipment and storage medium | |
| CN110688305B (en) | Test environment synchronization method, device, medium and electronic equipment | |
| CN106713042A (en) | Method and device for determination of network topology | |
| WO2019062019A1 (en) | Data list exporting method and terminal using same | |
| WO2018000878A1 (en) | Distributed task processing method and apparatus | |
| US9098334B2 (en) | Special values in oracle clusterware resource profiles | |
| CN103440146A (en) | BIOS updating method based on cloud storage | |
| CN105574195B (en) | Judge whether database answers the method and device of offline recycling | |
| CN104410511A (en) | Server management method and system | |
| WO2020000657A1 (en) | Method and apparatus for establishing operation and maintenance monitoring connection, terminal device, and medium | |
| CN108197253B (en) | Equipment query method, device and equipment of cloud monitoring platform | |
| US10019272B1 (en) | Virtual appliance manager | |
| CN102890640A (en) | System and method for managing virtual machine | |
| WO2018233365A1 (en) | Information inquiry method, terminal, device and storage medium |
Legal Events
| Date | Code | Title | Description |
|---|---|---|---|
| C06 | Publication | ||
| PB01 | Publication | ||
| C10 | Entry into substantive examination | ||
| SE01 | Entry into force of request for substantive examination | ||
| C02 | Deemed withdrawal of patent application after publication (patent law 2001) | ||
| WD01 | Invention patent application deemed withdrawn after publication |
Application publication date: 20130123 |