Virtual Machine Creation
Following your set up of a VM Server, log into the VM server as root using ssh and the root password you created at set-up.
Preparation
VM Server check
Once you have access to the VM Server:
Check the number of running virtual machines using the 'xm list' command.
If there are more than 4 virtual machines running, use a different VM Server. (the number of VM's allowed will change depending on the resources of the server. The server I already created has 756 megs of ram, 256 is needed by the server and 128 for each vm, so 4 is max.)
VM Resource management
Now go to a separate web-browser window to choose your virtual machine hostname.
Creation
Returning to the terminal window, which is logged into the VM Serrver you're going to use.
-
Use the command 'xen-create-image –hostname=vm## –mac=##:##:##:##:##:## –role=udev'
If you have no errors in /etc/xen/xend-config.sxp or /etc/xen-tools/xen-tools.conf it should proceed.
If everything goes according to plan you have actually create some files, images to be more exact. You have a 2 gigabyte image that has a fresh copy of squeeze on it, and a swap partition image of 128 megs.
Booting your Virtual Machine
If your Virtual Machine was created successfully you can now 'boot' it. When you are ready to boot your virtual machine use the following command:
root@vmserver##:~# xm create -c /xen/conf/vm##.cfg
Where ## is the number of the virtual machine you created in the creation section.
the -c connects to the console, in the future you wont do that too often, but for initial setup or any issues you will wish to connect.
root@vmserver##:~# xm create /xen/conf/vm##.cfg
Accessing Your Virtual Machine
You can now access your virtual machine from lab46 using SSH without having to connect to the VM server first.
Managing your virtual machine can be done utilizing the XM tool on the VMServer you created the virtual machine on.
Resources