General Info About Using XVA Templates

All files on this site are provided without guarantee or warranty. Use at your own risk.

Each xva download is a bzipped xva containing a virtual machine template that can be imported to XCP or XenServer:

  • The encoded virtual disk is typically 10GB, and can be resized during or after deployment
  • The templates contain a Xen PV kernel and are pygrub bootable

The naming convention of the download tarball is:

<distribution>.<distro-version>.<arch>.<created-date>.xva.bz2

For example centos.5-6.x86-64.20110408.xva.bz2 contains a 64-bit version of CentOS 5.6 with packages updated thru Apr 8th 2011. Before importing the template you must bunzip2 the file. This will leave an uncompressed xva file (which is actually a tarball containing chunks of the virtual disk). These xva files are flagged as templates, meaning that they will become a part of your template list upon import. Numerous virtual machines can then be created using the template as a starting point.

Prerequisites

  1. Working installation of XCP or XenServer
  2. Working knowledge of the xe tools or one of the control panels (eg XenCenter, see links below for more info)
  3. Enough filesystem space to accomodate the uncompressed xva (we use sparse files to save space)
  4. Enough capacity on your deployment node to store and run VMs based on the template

Default Configuration and Networking

Each filesystem is configured to use dhcp. The disk image itself is 10GB and the memory allocation is 512MB. These settings are easy to tweak upon deploment of a VM from the template, especially if you are using a control panel like XenCenter

The root login is root/password. It is highly recommened that you change the root password immediately.

Installation

You will need to bunzip the xva to a local directory. Please use the xe tool or your preferred management tool to import the template.

The relevant xe commands are as follows (using centos as an example) :

# xe vm-import filename=centos.5-6.x86-64.20110408.xva
# xe vm-install new-name-label=XXX template=centos.5-6.x86-64.20110408
# xe vm-start vm=XXX

Replace XXX with an appropriate name for your virtual guest. You can also pass the template's uuid to the vm-install command. The generated uuid's of a template or vm can be retrieved using xe template-list or xe vm-list respectively.

Misc Info

  1. Resist the temptation to use 'xl console' to attach to the guest's console. It will not work under the default configuration of XCP/XenServer. You can attach to the console using XenCenter or similar, or just ssh to the virtual machine. More info on the xen console in XCP: Access To VM Console
  2. Install the xe tools into the guest for better integration with management tools. You can attach the xe tools iso to the virtual machine, mount it and install the relevant packages for your distro. The xe tools allow enhanced monitoring and reporting for virtual machines.

Further Reading


© 2010-2013 Stacklet LLC - Privacy