[one-users] Let a user install its own VM

Stuart Longland stuartl at vrt.com.au
Fri Apr 4 02:30:16 PDT 2014


On 04/04/14 18:06, Christophe Duez wrote:
> Hello all,
> Is there a way to use the an ISO of CentOS, Ubuntu, Debian or Windows
> and let a user install its own VM from scratch.

I've found the easiest way to do this is to create your image as an
empty datablock, make it persistent, then create a template that mounts
it as your first disk, along with any installation media.

The VM's BIOS will see the lack of an OS on the disk, and go looking for
CD-ROMs and PXE servers to boot from.

When your OS installation is complete, you can blow away the VM, update
the template to drop the references to the images, and optionally,
toggle the persistence state of the image.  Voilá, there's your image.

For Linux, I'd recommend setting up a PXE boot server to install the
image.  We do this for deploying real PCs on our network (in fact, our
OpenNebula hosts are deployed that way: Ubuntu pre-seed scripts over
PXE), and it works equally as well for VMs.

Bonus being you don't need to edit the template at the end, you just
toggle the 'persistent' state on the image.
-- 
Stuart Longland
Systems Engineer
     _ ___
\  /|_) |                           T: +61 7 3535 9619
 \/ | \ |     38b Douglas Street    F: +61 7 3535 9699
   SYSTEMS    Milton QLD 4064       http://www.vrt.com.au





More information about the Users mailing list