CN102567075A - Virtual machine context setting method in cloud computing environment - Google Patents

Virtual machine context setting method in cloud computing environment Download PDF

Info

Publication number
CN102567075A
CN102567075A CN2011103972069A CN201110397206A CN102567075A CN 102567075 A CN102567075 A CN 102567075A CN 2011103972069 A CN2011103972069 A CN 2011103972069A CN 201110397206 A CN201110397206 A CN 201110397206A CN 102567075 A CN102567075 A CN 102567075A
Authority
CN
China
Prior art keywords
virtual machine
context
configuration
machine context
cdrom
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
Application number
CN2011103972069A
Other languages
Chinese (zh)
Other versions
CN102567075B (en
Inventor
兰雨晴
赵敬锋
宋潇豫
夏颖
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
China Standard Software Co Ltd
Original Assignee
China Standard Software Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by China Standard Software Co Ltd filed Critical China Standard Software Co Ltd
Priority to CN201110397206.9A priority Critical patent/CN102567075B/en
Publication of CN102567075A publication Critical patent/CN102567075A/en
Application granted granted Critical
Publication of CN102567075B publication Critical patent/CN102567075B/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Landscapes

  • Stored Programmes (AREA)

Abstract

The invention discloses a virtual machine context setting method in a cloud computing environment, which includes the steps: firstly, making a virtual machine context configuration file into an ISO (isolation) mapping; next, mounting the ISO mapping by taking the ISO mapping as a CDROM (compact disc read-only memory) device of a virtual machine when the virtual machine is started; and then configuring the virtual machine by means of a virtual machine context configuration strategy. The virtual machine context refers to environment configuration information when the user uses the virtual machine, and can comprise network configuration, a user name, a password, a host name and other personalized settings. The virtual machine context configuration strategy refers to that the virtual machine context is configured as needed by adopting a uniform virtual machine context configuration file definition format according to different virtual machine context configuration items. In the method, the virtual machine context is configured by adopting the uniform virtual machine context configuration strategy and can be configured as needed, and a virtual machine context configuration process can be simplified, so that user experience is improved.

Description

Virtual machine context method to set up in a kind of cloud computing environment
Technical field
The present invention relates to Virtual Machine Manager field and cloud computing field in the cloud computing, specifically is a kind of virtual machine context method to set up.
Background technology
In cloud computing environment, a large amount of virtual machines is arranged in operation.A good cloud management platform needs and can carry out perfect management to the life cycle of virtual machine, comprises the establishment, deletion, migration, switching on and shutting down of virtual machine etc.For ease for use (the concealing technology details of promptly trying one's best that improves the cloud management platform; Reduce user's learning cost; Improve user's experience), need after creating virtual machine of completion, carry out pre-configured (promptly the context to virtual machine carries out initialization) to virtual machine; So that the user has just obtained available, easy-to-use, a friendly virtual machine after creating virtual machine of completion.
Carrying out pre-configured to virtual machine mainly is that context to virtual machine carries out initialization.Virtual machine context is meant some configuration informations when user uses virtual machine; Can comprise: the network configuration of virtual machine (IP, MAC Address, gateway, subnet mask, DNS etc.); Virtual machine user name, password; Virtual machine operation login relevant information, host name setting, and other personal settings.
At present, the virtual machine context initial work physically is divided into two parts, and a part is accomplished by operating system, and a part is manually accomplished by the user.Because the singularity of cloud computing, the initial work difficulty of manually being accomplished virtual machine context by the user is bigger, and user experience is very poor.Main cause is following: 1. the virtual machine quantity in the cloud computing environment is a lot, possibly once can create tens, up to a hundred virtual machine, if all manually carry out contextual initial work by the user, then workload is very big; 2. the virtual machine in the cloud computing environment is all long-range, not in this locality, can not as physical machine easily through local keyboard, mouse just can the complete operation system pre-configured.
At present, in cloud computing, also have certain methods can realize the context of virtual machine is carried out initialization, but these methods all can only be provided with the configuration of a part, do not have a kind of unified method to be accomplished to the virtual machine context entire arrangement.To simply introduce the whole bag of tricks of present existence below.
1. for network configuration, can adopt the mode of DHCP to come the network configuration of virtual machine is provided with, shortcoming is that the IP of virtual machine does not fix, if this virtual machine is to be used to do server, then possibly need static IP; Therefore, the method has certain limitation;
2. for user name, password are set, can adopt a kind of method of virtual machine dynamic password setting at present, this method has security preferably, but because dynamic password is at random, therefore inconvenient user's memory;
3. exempt from the password login for ssh; Can in virtual machine template, configure; After create accomplishing virtual machine, the user can use pre-configured mode to login, but for this mode of creating in batches of virtual machine safety inadequately;
4. host name setting: have at present through territory or template dual mode dual modes such as host name are set.The mode that wherein is provided with through template can have problems when creating virtual machine in batches; Mode through the territory is provided with host name and then requires virtual machine must be added in the territory, has influenced the dirigibility of virtual machine.
Summary of the invention
For solving the problems of the technologies described above, fundamental purpose of the present invention be to provide a kind of unification, virtual machine context method to set up flexibly, simplify the configuration complicated problems of newly-built a plurality of virtual machines; Simultaneously, method provided by the invention also can be simplified the problem that disposes after the virtual machine context to a great extent.
Based on above-mentioned target, the present invention proposes a kind of unified virtual machine context method to set up, with the unification inadequately, underaction that solve current distributing virtual machine context method to set up, the problem that is difficult to expand.
As shown in Figure 1, a kind of unified virtual machine context setting and implementation method of the present invention may further comprise the steps:
1) makes virtual machine context configuration ISO file (S1);
Defining virtual machine context configuration file form; Configuring virtual machine context configuration item content, and generate virtual machine context configuration ISO file, upgrade virtual machine context configuration item content; The configuration file that generates can generate configuration file in bulk to a plurality of virtual machines; Can have identical context configuration item and content in these configuration files, also can have different context configuration item and content, the content in the different context configuration file can have not regulation; In addition, have regular configuration information, thereby also can the configuration information of non-regularity be converted into configuration information, and then handle with regularity because the configuration information of non-regularity can have multiple mode to be converted into.
2) make virtual machine image (S2);
Create virtual machine, realize the virtual machine context collocation strategy, and the virtual machine context starting up is set;
3) configuring virtual machine context (S3);
Realization is configured virtual machine context according to user configured virtual machine context deploy content.
Setting by above-mentioned steps; Realized on virtual machine, using unified virtual machine context collocation method that virtual machine context is configured; Can carry out the virtual machine context configuration in bulk to a plurality of virtual machines; Simplify the manual step of carrying out of user of virtual machine context configuration, solved the problem of poor user experience when the user is configured a plurality of virtual machine context in cloud computing environment.
As shown in Figure 2, the making virtual machine context configuration ISO file in the step 1) need comprise following step:
(1) defining virtual machine context configuration format (S101);
(2) configuring virtual machine context configuration item (S102);
(3) generate the service data item (S103) that virtual machine context disposes as required, comprise this configuration identifier whether of virtual machine unique identification and virtual machine context;
(4) make virtual machine context configuration ISO file (S104).
As shown in Figure 3, step 2) the making virtual machine image in need comprise following step:
(1) creates new virtual machine (S201);
(2) the virtual machine context configuration file is put into (S202) in the virtual machine image;
(3) start of virtual machine context configuration file is set and carries out (S203).
As shown in Figure 4, the configuring virtual machine context procedures in the step 3) need comprise following step:
(1) context disposes the CDROM equipment (S301) that CD is set to virtual machine;
(2) start virtual machine (S302);
(3) carry CDROM equipment (S303) in VME operating system;
(4) resolve configuration file content (S304);
(5) relatively the virtual machine sign vmid among the CDROM whether with virtual machine in virtual machine sign vmid identical (S305), difference, then execution in step (6) is identical, then execution in step (7);
(6) value of the sign of the virtual machine in virtual machine vmid is set to the value (S306) of the virtual machine sign vmid among the CDROM; And the context in the virtual machine whether the value of configuration identifier passnum be set to the context value (S307) of configuration identifier passnum whether among the CDROM, execution in step (8);
(7) if value whether identical with the value of configuration identifier passnum among the CDROM (S309) of configuration identifier passnum whether of the context in the virtual machine relatively identical, then no longer is provided with virtual machine context, withdraws from (S310); If inequality, then the context in the virtual machine whether the value of configuration identifier passnum be set to the context value of configuration identifier passnum whether among the CDROM, execution in step (8);
(8) carry out virtual machine setting up procedure (S308) up and down.
With respect to the virtual machine context method to set up of current scattered formula, the virtual machine context method to set up of unified formula of the present invention has following characteristics:
1) the present invention can automatically be provided with virtual machine context when virtual machine creating;
2) the present invention can adopt uniform way that the various configurations (as: virtual machine network, virtual machine user name and password, virtual machine host name etc.) in the virtual machine context are set, and does not need different context configurations to adopt diverse ways;
3) virtual machine context configuration mode of the present invention is easy to expansion, has very strong dirigibility, and the developer only need just can support new configuration item according to the processing capacity that rule is added different configuration items, and the final user does not have learning cost;
4) the present invention not only is supported in when creating virtual machine to virtual machine context configuration and carries out initialization, also supports when needed virtual machine context to be upgraded;
5) the present invention does not need the user to sign in to that virtual machine is inner just can to carry out various configurations to virtual machine context;
6) the present invention does not need to configure network to virtual machine in advance and just can carry out various contextual configurations to virtual machine.
The present invention is particularly suitable for being applied to guarantee the ease for use of the virtual machine context setting under following two kinds of application scenarioss:
1) the privately owned cloud scene of cloud computing; Enterprise provides virtual desktop to the employee; So that unified virtual machine applied environment to be provided, under this application scenarios, a plurality of similar virtual machine context configured virtual machines that have need be provided once; Like this; Can generate the virtual machine context configuration information according to employee's personal information, use the contextual information that the present invention comes to be provided with uniformly virtual machine then, be one and need not dispose the virtual machine that just can carry out the work with what reach that virtual machine distributes to the user.
2) the publicly-owned cloud scene of cloud computing; Enterprise provides virtual machine to the user; Each user has personalized configuration needs, and in this case, the user only need fill in the configuration item of the personalization of controlling oneself; Use the present invention just just user's personalized configuration item when creating virtual machine, automatically carry out initialization for virtual machine context, do not need the user to carry out individual event ground again after signing in on the virtual machine and dispose.
The present invention can improve the availability and the standardization of virtual machine context configuration to a great extent, has higher utility and commercial value.
Description of drawings
Fig. 1 is the flowchart of virtual machine context collocation method of the present invention;
Fig. 2 makes virtual machine context configuration ISO file process flow diagram flow chart for the present invention;
Fig. 3 makes virtual machine context configuration disk image process flow diagram flow chart for the present invention;
Fig. 4 is provided with the process flow diagram of context procedures in virtual machine for the present invention.
Embodiment
For letting above-mentioned and other purposes, characteristic and the advantage of the present invention can be more obviously understandable, hereinafter is special lifts the preferred embodiments of the present invention, and conjunction with figs., elaborates as follows:
In order to solve unification inadequately, underaction, the extendability defect of bad in the current virtual machine context method to set up, the inventor intends and adopts unified virtual machine context method to set up to solve these technical matterss.
The unified virtual machine context method to set up that the present invention proposes has solved the distinctive problem of some in the cloud computing environment.
In present embodiment; Be to be host with rhel6.0; And use its kvm that carries to be virtual machine monitor; Libvirt is the Virtual Machine Manager program; The target virtual machine that ubuntu9.04 and windows2003 operating system are implemented as the present invention program can be installed respectively; And on ubuntu9.04 and windows2003, realized the contextual setting (in present embodiment, virtual machine context is to be example with the user name password of virtual machine and IP address configuration information) of virtual machine of the present invention respectively, it comprises that specifically the formal definition of virtual machine context configuration, virtual machine context configuration import strategy, virtual machine context configurator, virtual machine context configurator starting up, the virtual machine context realization of collocation strategy as required into.Wherein, Because text directly imports relatively difficulty of virtual machine into usually; So importing strategy into, the virtual machine context configuration is preferably employing with virtual machine context configuration file making becoming ISO reflection; Be mounted to the strategy in the virtual machine with the CDROM DeviceMode again, that adopts among the present invention saidly imports strategy into through CDROM and has and be simple and easy to realize, do not need pre-configured virtual machine network, be easy to characteristics such as renewal; And these configuration items in contextual setting of virtual machine can be divided into Basic Configuration Items and safeguard, wherein, safeguard to be the setting option that increases for the realization system automatically performs some configurations, under simple situation, can not contain this.Basic Configuration Items is with username and password in present embodiment; And the IP address information is an example; Safeguard it is that the contextual configured number that is provided with virtual machine unique identification and user name password setting number of times and virtual machine is an example, safeguard that wherein the number of times parameter in the item can be used for being provided with or revising the Basic Configuration Items of variation.Virtual machine sign: be used for whether configuration identifier of virtual machine context of unique identification: whether certain Basic Configuration Items that is used to identify virtual machine context needs configuration, all Basic Configuration Items in the virtual machine that whether configuration identifier of a context can be arranged when this starts at virtual machine.
The execution flow process of the unified virtual machine context collocation method that the present invention proposes in present embodiment is (as shown in Figure 1) as follows:
1) at first, makes virtual machine context configuration ISO file (S1);
Be to make virtual machine context configuration ISO file: context.iso in present embodiment;
It comprises following steps (as shown in Figure 2):
(1) defining virtual machine context configuration format (S101)
In present embodiment, the virtual machine context configuration format of definition is to elect the form into KEY=VALUE as, certainly, also can adopt the definition scheme of other virtual machine context configuration format, and this process those skilled in the art all can understand, and do not repeat them here.
The configuration item (S102) that (2) will be provided with in the configuring virtual machine context, configuration item can be divided into Basic Configuration Items and safeguard item usually, and in present embodiment, Basic Configuration Items is a username and password, and the IP address information.
A) username and password of configuring virtual machine;
username=testuser
password=qwe123
B) the IP address information of configuring virtual machine.
Because when many virtual machines are provided with; Some configuration item has nothing in common with each other, but is clocklike between these configuration items, in present embodiment; Batch configuration the contextual information of 6 virtual machines; Wherein, the IP address of every virtual machine all is inequality, but because IP address configuration scope is 192.168.0.2---192.168.0.7; Thereby can adopt following configuration script generator program to generate the relevant Basic Configuration Items in IP address, and write in the virtual machine context configuration file of each virtual machine.
#!/bin/bash
Vmdir?=?/root/vmdir/
Vmconfig?=?config.sh
Ipadress?=?“192.168.0.”
Netmask?=?“255.255.255.0”
Gateway?=?“192.168.0.1”
DNS?=?“192,168.0,254”
for?vmnum?in?[$1,$2]
do
mkdir?–p?“$Vmdir/$vmnum”
configfile?=?“$Vmdir/$vmnum/$Vmconfig”
echo?$Netmask?>>?$configfile
echo?$Gateway?>>?$configfile
echo?$DNS?>>?$configfile
echo?“$Ipadress$vmnum”?>>?$configfile
done
(3) generate virtual machine context configuring maintenance item (S103)
The context configuring maintenance item that in present embodiment, defines comprises three, and one is virtual machine unique identification, i.e. vmid; One is user name password setting number of times, i.e. passnum; Contextual configured number (in present embodiment, the virtual machine context configuration is meant that the user name with virtual machine is a virtual machine IP address configuration number of times with last), the i.e. nicnum of being provided with of virtual machine;
What the vmid in the present embodiment got is the current Unix timestamp of system, promptly
vmid=1318486624396124
Present embodiment is owing to being for the first time virtual machine to be carried out the context initial configuration, promptly
passnum=1;
nicnum=1;
(4) make context configuration ISO file (S104)
Be to use the mkisofs order to make corresponding context.iso file respectively in the present embodiment to all 6 virtual machines; Can also have additive method to generate the context.iso image file, be that it is the most simply, is easy to the mode created in batches most but be to use mkisofs order.
2) make virtual machine image (S2), specifically as shown in Figure 3, may further comprise the steps:
(1) creates new virtual machine (S201);
In present embodiment, be to use libvirt to create two kinds of virtual machines, i.e. ubuntu9.04 and windows2003;
The present invention supports the virtual machine of all systems in theory, and can use the disk image of existing virtual machine, and this process those skilled in the art all can understand, and is that disk image with newly-built virtual machine is the example explanation at this.
(2) the virtual machine context configuration file is put into (S202) in the virtual machine image;
Present embodiment is that the virtual machine context configurator is placed under the virtual machine root directory, at ubuntu9.04 be to be placed into/the root catalogue under; And be to be placed into C: under the catalogue at windows2003;
(3) start of virtual machine context configuration file is set and carries out (S203).
Ubuntu9.04 in the present embodiment has added the startup command that starts the virtual machine context configuration file at rc.local; Be to have utilized group policy to have realized the starting up of virtual machine context configurator in windows2003;
3) configuring virtual machine context (S3);
Be in ubuntu9.04 and windows2003 virtual machine, to carry out the context setting up procedure in present embodiment:
Referring to Fig. 4, in present embodiment, create good ubuntu9.04 and windows2003 virtual machine context disk configuration image above the use respectively and created 6 virtual machines, wherein based on ubuntu9.04 and windows2003 3 virtual machines respectively; Below will be to explain based on ubuntu9.04 and each virtual machine instance of windows2003; The context layoutprocedure of other the virtual machine context layoutprocedure of virtual machine therewith is identical; This process those skilled in the art all can understand, and do not repeat them here.
(1) context disposes the CDROM equipment (S301) that CD is set to virtual machine;
In the present embodiment, ubuntu9.04 is to use the virtual machine defined file of revising libvirt to add the equipment that has suffered a CDROM to 6 virtual machines;
(2) start virtual machine (S301);
In the present embodiment, be to use virsh among the libvirt to order and start two kinds of virtual machines;
(3) carry CDROM equipment (S303) in VME operating system;
In the present embodiment, in ubuntu9.04, be to use mount to order carry CDROM equipment, and be the automatic carry CDROM of operating system equipment in windows2003;
(4) resolve configuration file content (S304);
Be to have parsed following eight context deploy contents in the present embodiment, explain with one of them virtual machine instance:
username=testuser
password=qwe123
vmid=1318486624396124
passnum=1
nicnum=1
Netmask=255.255.255.0
Gateway=192.168.0.1
DNS=192.168.0.254
Ipadress=192.168.0.2?(ubuntu9.04)
Ipadress=192.168.0.2?(windows2003)
(5) relatively the virtual machine sign vmid among the CDROM and virtual machine in the virtual machine identify vmid whether identical (S305); Different; Then the value of the sign of the virtual machine in virtual machine vmid is set to the value (S306) of the virtual machine sign vmid among the CDROM, execution in step (6); Identical, execution in step (7) then;
Vmid in the present embodiment among virtual machine ubunut9.04 and the windows2003 is " "; Inequality with the value 1318486624396124 of virtual machine among CDROM sign vmid; Vmid=1318486624396124 among virtual machine ubunut9.04 and the windows2003 then is set, and execution in step (6);
In present embodiment, if virtual machine is when restarting, its value is identical, and this moment is direct execution in step (7) then
(6) context in the virtual machine whether the value of configuration identifier passnum and nicnum be set to the context value (S307) of configuration identifier passnum and nicnum whether among the CDROM, execution in step (8);
Passnum=1 among ubuntu9.04 and the windows2003 will be set, nicnum=1 in the present embodiment; Execution in step (8)
(7) relatively the context in the virtual machine whether configuration identifier passnum value whether with CDROM in the context value identical (S309) of configuration identifier passnum whether, if identical, virtual machine context is set no longer then, withdraw from (S310); If inequality, then the context in the virtual machine whether the value of configuration identifier passnum be set to the context value (S307) of configuration identifier passnum whether among the CDROM, execution in step (8);
In the present embodiment, the passnum=1 among the CDROM, the passnum=1 in the virtual machine; Nicnum=1 among the CDROM, the nicnum=1 in the virtual machine; Then no longer virtual machine is carried out the context configuration, withdraw from layoutprocedure;
(8) carry out virtual machine setting up procedure (S308) up and down
The password that testuser among ubunut9.04 and the windows2003 is set in the present embodiment is qwe123; And corresponding IP address information is set.
Be that different virtual machines is provided with different IP address informations is that example has explained that the present invention is applicable to the layoutprocedure to the regular variation of the context configuration information of a plurality of virtual machines more than the present embodiment; Described regular variation is meant is preserving under the constant situation of identical Basic Configuration Items; Confirm the initial value of the Basic Configuration Items of variation earlier; Confirm Changing Pattern-each variable quantity of the configuration item of variation then, the initial value+variable quantity according to the Basic Configuration Items that changes just can generate whole regular configuration files that changes that has at last.
Because of also can being non-regularity, some configuration informations change in addition; But; Have regular configuration information because the configuration information of non-regularity can have multiple mode to be converted into, in fact the present invention is equally applicable to the layoutprocedure to the context configuration information non-regularity variation of a plurality of virtual machines.Be that example is explained the information that how erratic configuration information is converted into rule different ciphers is set for three different virtual machines below.
1) generates three random ciphers, and 3 passwords are written in the password.txt file;
abcdefsgeh
123dfsdf43
2342352232
Used the simplest mode to generate random cipher in the present embodiment, can also adopt other mode to generate random cipher, the present invention is unrestricted to the content of the Basic Configuration Items of generation.
2) obtain random cipher with the mode of regularity;
With the line number of random cipher in password.txt is that preface generates the virtual machine context configurator:
Vm1_password=abcdefsgeh
Vm2_password=123dfsdf43
Vm3_password=2342352232
Promptly accomplished the regularization of random arrangement information, can adopt the virtual machine context collocation method of regularization above-mentioned to come to carry out context with that and dispose to virtual machine.Also exist other method that irregular virtual machine context configuration information is carried out regularization, present embodiment has just been enumerated wherein a kind of more typical mode.It is understandable that the present invention is applicable to that the virtual machine context configuration information to irregularization carries out batch setting, this process those skilled in the art all can understand, and do not repeat them here.
The process that present embodiment only is provided with the unified virtual machine context of the virtual machine instance explanation of ubuntu9.04 and windows2003 system; In fact the present invention is applicable to the virtual machine of any system; Wherein, most typical application scenarios is the virtual machine of Linux and Windows system.It more than is the process that the bright virtual machine context of as an exampleBSEMGVR takeN-PSVSEMOBJ that user name, password and IP address information that virtual machine is set is provided with as context is provided with; In fact the present invention is applicable to any virtual machine context setting option, is that virtual machine network setting, host name are provided with etc. than typical application.It more than is the setting of the virtual machine context information in batches of having carried out to a plurality of virtual machines; The contextual information of these virtual machines can be identical; Also can be different; Come example the present invention both to be applicable to this a plurality of virtual machines are carried out the identical contextual information of batch setting, also be applicable to a plurality of virtual machines are carried out the different virtual machine context information of batch setting.More than be that virtual machine instance with new installation describes; It is understandable that; The present invention also can implement on already installed virtual machine; At this moment can create the laggard single stepping of advancing of new virtual machine with original virtual machine image, this process those skilled in the art all can understand, and do not repeat them here.
The present embodiment example description the present invention virtual machine context is carried out pre-configured initialized process; In fact the present invention also virtual support machine context carry out the initialized process of back configuration; Promptly after virtual machine is successfully created and is carried out the context initialization; In the virtual machine use, the present invention also can dispose the virtual machine context Basic Configuration Items once more.The configuring virtual machine username and password is that example is come layoutprocedure (difference of layoutprocedure is embodied in following two processes with the first time) after the example description virtual machine context after the present embodiment:
(1) configuration file generation phase
1) generate new context config option, the password of user name testuser is revised as qwe1234 from qwe123:
username=testuser;
password=qwe1234;
2) revise virtual machine user name password configuration item switch, passnum originally is 1, on original passnum basis, adds 1, is revised as 2:
passnum=2
3) other configuration items remain unchanged.
(2) the automatic configuration phase of virtual machine context,
Can automatically perform the virtual machine context configurator during virtual machine activation; After resolving the completion configuration file; Passnum=2 in the configuration file, the passnum=1 in the virtual machine internal profile, it is inequality to judge both; Then virtual machine user name and password are reconfigured, and revise the passnum=2 in the virtual machine internal profile; Because other configuration item is all identical, then can not be configured virtual machine IP address information;
That is to say; In present embodiment; Two signs are set in the configuration file capable of using: the configuration item switch is " value of sign " (passnum); Wherein, in the context of virtual machine internal profile whether the value of configuration identifier be passnum0, and the value of the sign of the virtual machine among the CDROM is passnum1;
When the 1st configuration: passnum1=1, passnum0 does not have assignment,
After the 1st configuration accomplished, passnum0=1 is set;
When generating new context config option, passnum1 changes 2 into by 1, at this moment passnum1=2;
Passnum1 (being 2) and passnum0 (being 1) are compared, judge difference, then reconfigure;
After the 2nd configuration accomplished, passnum0=2 is set; ... by that analogy.By the setting of such hereinafter maintenance item, can be able to dispose once more the part or all of project of virtual machine context configuration item.
The above person; Be merely explanation preferred implementation of the present invention, and unrestricted scope of the present invention, any those skilled in the art; Do not breaking away from the spirit and scope of the present invention; When doing a little change and retouching, promptly all according to equalization variation and modification that the present invention did, should be claim of the present invention and contain.

Claims (10)

1. a virtual machine context method to set up is characterized in that, may further comprise the steps:
1) makes virtual machine context configuration ISO file: generate configuration file with virtual machine hereinafter configuration format, and be made into the ISO file;
2) make virtual machine image: the virtual machine context collocation strategy is integrated in the virtual machine image, and is set to the starting up;
3) configuring virtual machine context: resolve the configuration file content in the ISO file, and according to virtual machine context collocation strategy configuring virtual machine context.
2. virtual machine context method to set up according to claim 1, it is characterized in that: the virtual machine context configuration format in the step 1) is to adopt unified virtual machine context configuration format.
3. like the said virtual machine context method to set up of claim 2, it is characterized in that: whether its each configuration item all has configuration identifier, so that each configuration item of virtual machine context is disposed as required.
4. virtual machine context method to set up according to claim 1, it is characterized in that: the virtual machine context configuration in the step 3) has following steps:
(1) context disposes the CDROM equipment that CD is set to virtual machine;
(2) start virtual machine;
(3) carry CDROM equipment in VME operating system;
(4) resolve configuration file content;
(5) carry out virtual machine setting up procedure up and down, the value of virtual machine sign is set to the value of the virtual machine sign among the CDROM.
5. like the said virtual machine context method to set up of claim 3, it is characterized in that: the virtual machine context configuration in the step 3) has following steps:
(1) context disposes the CDROM equipment that CD is set to virtual machine;
(2) start virtual machine;
(3) carry CDROM equipment in VME operating system;
(4) resolve configuration file content;
(5) relatively the virtual machine sign among the CDROM whether with virtual machine in the virtual machine sign whether identical, difference, then the value of the sign of the virtual machine in the virtual machine is set to the value of the virtual machine sign among the CDROM, execution in step (6); Identical, execution in step (7) then;
(6) context in the virtual machine whether the value of configuration identifier be set to the context value of configuration identifier whether among the CDROM, execution in step (8);
(7) relatively the context in the virtual machine whether configuration identifier value whether with CDROM in context the value of configuration identifier is identical, if identical, virtual machine context is set no longer then, withdraw from; If inequality, then the context in the virtual machine whether the value of configuration identifier be set to the context value of configuration identifier whether among the CDROM, execution in step (8);
(8) carry out virtual machine setting up procedure up and down.
6. like each said virtual machine context method to set up of claim 1-3, it is characterized in that: the configuration file of the generation in step 1) generates configuration file in bulk to a plurality of virtual machines.
7. like the said virtual machine context method to set up of claim 6, it is characterized in that: have identical or different context configuration item and content in the configuration file.
8. like the said virtual machine context method to set up of claim 6, it is characterized in that: the configuration item in the context configuration file is regular.
9. like the said virtual machine context method to set up of claim 6, it is characterized in that: in step 2, comprise the regular configuration information step that has that configuration information with non-regularity changes into.
10. like each said virtual machine context method to set up of claim 1-5; It is characterized in that: the environment configurations information network configuration item when this virtual machine context is used virtual machine for referring to the user, configuration item comprise user name, password, host name at least wherein partly or entirely.
CN201110397206.9A 2011-12-05 2011-12-05 Virtual machine context setting method in cloud computing environment Active CN102567075B (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
CN201110397206.9A CN102567075B (en) 2011-12-05 2011-12-05 Virtual machine context setting method in cloud computing environment

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
CN201110397206.9A CN102567075B (en) 2011-12-05 2011-12-05 Virtual machine context setting method in cloud computing environment

Publications (2)

Publication Number Publication Date
CN102567075A true CN102567075A (en) 2012-07-11
CN102567075B CN102567075B (en) 2015-01-21

Family

ID=46412573

Family Applications (1)

Application Number Title Priority Date Filing Date
CN201110397206.9A Active CN102567075B (en) 2011-12-05 2011-12-05 Virtual machine context setting method in cloud computing environment

Country Status (1)

Country Link
CN (1) CN102567075B (en)

Cited By (17)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103118108A (en) * 2013-01-30 2013-05-22 北京荣之联科技股份有限公司 Automatic virtualized system pushing method and device thereof
CN103677961A (en) * 2013-12-20 2014-03-26 国云科技股份有限公司 Method for setting host name of virtual machine
CN103685568A (en) * 2013-12-31 2014-03-26 曙光云计算技术有限公司 Platform service application deployment method and system of PAAS (Platform As A Service) platform under cloud computing environment
CN103856343A (en) * 2012-12-05 2014-06-11 北京华胜天成科技股份有限公司 Method and system for configurating virtual machine network information
CN103888420A (en) * 2012-12-20 2014-06-25 中国农业银行股份有限公司广东省分行 Virtual server system
CN104239122A (en) * 2014-09-04 2014-12-24 华为技术有限公司 VM (virtual machine) migration method and device
CN104281484A (en) * 2014-09-23 2015-01-14 华为技术有限公司 VM (virtual machine) migration method and device
CN104281482A (en) * 2014-08-19 2015-01-14 中标软件有限公司 Method and system for building virtual image model
CN105373417A (en) * 2015-11-04 2016-03-02 浪潮(北京)电子信息产业有限公司 Method and system for virtual machine management in cloud computing
CN105589722A (en) * 2015-12-23 2016-05-18 浪潮集团有限公司 Method for initializing username password of virtual machine based on virtual machine template
CN106055403A (en) * 2016-05-13 2016-10-26 深圳市青葡萄科技有限公司 Method and system for rapid terminal configuration based on USB storage equipment
CN106843905A (en) * 2017-02-22 2017-06-13 云宏信息科技股份有限公司 The implementation method and device of virtual machine initial configuration in cloud management platform
CN107168735A (en) * 2017-04-28 2017-09-15 苏州蜗牛数字科技股份有限公司 A kind of method of automatic deployment windows systems
CN107463431A (en) * 2017-08-16 2017-12-12 郑州云海信息技术有限公司 A kind of file management method and device
CN107463404A (en) * 2017-08-03 2017-12-12 浪潮(北京)电子信息产业有限公司 Increase the method and system of configuration file in a kind of system to virtual machine file
CN107579823A (en) * 2017-10-10 2018-01-12 郑州云海信息技术有限公司 A kind of virtual machine entry password remapping method and device
TWI701596B (en) * 2015-05-06 2020-08-11 香港商阿里巴巴集團服務有限公司 Virtual host and isolation method, resource access request processing method and device

Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101256495A (en) * 2007-02-27 2008-09-03 国际商业机器公司 Method and apparatus for policy-based automatic configuration of middleware component
CN101470621A (en) * 2007-12-28 2009-07-01 埃森哲环球服务有限公司 Virtual machine configuration system
US20100250907A1 (en) * 2009-03-31 2010-09-30 Dehaan Michael Paul Systems and methods for providing configuration management services from a provisioning server
CN102088367A (en) * 2010-12-10 2011-06-08 北京世纪互联工程技术服务有限公司 Method for quickly deploying in virtualization environment

Patent Citations (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN101256495A (en) * 2007-02-27 2008-09-03 国际商业机器公司 Method and apparatus for policy-based automatic configuration of middleware component
CN101470621A (en) * 2007-12-28 2009-07-01 埃森哲环球服务有限公司 Virtual machine configuration system
US20100250907A1 (en) * 2009-03-31 2010-09-30 Dehaan Michael Paul Systems and methods for providing configuration management services from a provisioning server
CN102088367A (en) * 2010-12-10 2011-06-08 北京世纪互联工程技术服务有限公司 Method for quickly deploying in virtualization environment

Cited By (21)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
CN103856343A (en) * 2012-12-05 2014-06-11 北京华胜天成科技股份有限公司 Method and system for configurating virtual machine network information
CN103888420A (en) * 2012-12-20 2014-06-25 中国农业银行股份有限公司广东省分行 Virtual server system
CN103118108A (en) * 2013-01-30 2013-05-22 北京荣之联科技股份有限公司 Automatic virtualized system pushing method and device thereof
CN103677961A (en) * 2013-12-20 2014-03-26 国云科技股份有限公司 Method for setting host name of virtual machine
CN103685568A (en) * 2013-12-31 2014-03-26 曙光云计算技术有限公司 Platform service application deployment method and system of PAAS (Platform As A Service) platform under cloud computing environment
CN104281482A (en) * 2014-08-19 2015-01-14 中标软件有限公司 Method and system for building virtual image model
CN104239122A (en) * 2014-09-04 2014-12-24 华为技术有限公司 VM (virtual machine) migration method and device
US10489183B2 (en) 2014-09-04 2019-11-26 Huawei Technologies Co., Ltd. Virtual machine migration method and apparatus
US11422843B2 (en) 2014-09-04 2022-08-23 Huawei Cloud Computing Technologies Co., Ltd. Virtual machine migration method and apparatus having automatic user registration at a destination virtual machine
CN104281484A (en) * 2014-09-23 2015-01-14 华为技术有限公司 VM (virtual machine) migration method and device
CN104281484B (en) * 2014-09-23 2018-04-10 华为技术有限公司 A kind of virtual machine migration method and device
TWI701596B (en) * 2015-05-06 2020-08-11 香港商阿里巴巴集團服務有限公司 Virtual host and isolation method, resource access request processing method and device
CN105373417A (en) * 2015-11-04 2016-03-02 浪潮(北京)电子信息产业有限公司 Method and system for virtual machine management in cloud computing
CN105589722A (en) * 2015-12-23 2016-05-18 浪潮集团有限公司 Method for initializing username password of virtual machine based on virtual machine template
CN106055403A (en) * 2016-05-13 2016-10-26 深圳市青葡萄科技有限公司 Method and system for rapid terminal configuration based on USB storage equipment
CN106055403B (en) * 2016-05-13 2019-06-28 深圳市青葡萄科技有限公司 The method and system of terminal rapid configuration are carried out based on USB storage device
CN106843905A (en) * 2017-02-22 2017-06-13 云宏信息科技股份有限公司 The implementation method and device of virtual machine initial configuration in cloud management platform
CN107168735A (en) * 2017-04-28 2017-09-15 苏州蜗牛数字科技股份有限公司 A kind of method of automatic deployment windows systems
CN107463404A (en) * 2017-08-03 2017-12-12 浪潮(北京)电子信息产业有限公司 Increase the method and system of configuration file in a kind of system to virtual machine file
CN107463431A (en) * 2017-08-16 2017-12-12 郑州云海信息技术有限公司 A kind of file management method and device
CN107579823A (en) * 2017-10-10 2018-01-12 郑州云海信息技术有限公司 A kind of virtual machine entry password remapping method and device

Also Published As

Publication number Publication date
CN102567075B (en) 2015-01-21

Similar Documents

Publication Publication Date Title
CN102567075B (en) Virtual machine context setting method in cloud computing environment
US11405274B2 (en) Managing virtual network functions
CN108536519B (en) Method for automatically building Kubernetes main node and terminal equipment
US20210072974A1 (en) Cloud Service Automation of Common Image Management
US10855537B2 (en) Methods and apparatus for template driven infrastructure in virtualized server systems
US11622010B2 (en) Virtualizing device management services on a multi-session platform
US8326972B2 (en) Methods and systems for managing network connections in a software provisioning environment
EP2823393B1 (en) Offline provisioning of virtual machines
US20180232225A1 (en) Applying update to snapshots of virtual machine
US8612968B2 (en) Methods and systems for managing network connections associated with provisioning objects in a software provisioning environment
US9124497B2 (en) Supporting multiple name servers in a software provisioning environment
US9250672B2 (en) Cloning target machines in a software provisioning environment
US9052940B2 (en) System for customized virtual machine for a target hypervisor by copying image file from a library, and increase file and partition size prior to booting
US8463882B2 (en) Server cloning in a computing-on-demand system
US9021005B2 (en) System and method to provide remote device management for mobile virtualized platforms
JP2013168140A (en) Method for deploying virtual machines
GB2516842A (en) Deployment of software images with distinct configuration logic
CN103885833A (en) Method and system for managing resources
US11385973B1 (en) High-availability for power-managed virtual desktop access
CN113419813A (en) Method and device for deploying bare engine management service based on container platform
CN111061503A (en) Cluster system configuration method and cluster system
US20240129294A1 (en) Automatically generating task-based and limited-privilege user security credentials
EP2864878B1 (en) Automated controlling of host over network
CN117724793A (en) Method and system for sharing virtualized cloud desktop software resources
CN105302585A (en) Operating system packaging method and apparatus based on virtualization technology architecture

Legal Events

Date Code Title Description
C06 Publication
PB01 Publication
C10 Entry into substantive examination
SE01 Entry into force of request for substantive examination
C14 Grant of patent or utility model
GR01 Patent grant