On Fri, Aug 20, 2010 at 1:00 PM, Brian Roberg <robergb@dm.org> wrote:
When provisioning new VMs, is it possible to enable virtio for the guest's storage at the time of the installation? When I try to do so, the Ubuntu installer says, "No root file system is defined" when it gets to the partitioning step.

This turned out to be a silly mistake on my part. (Note: The problem and solution I'll describe here are not libvirt-specific, but since I asked the question here I thought it best to provide the answer too.)

In the preseed file I was using for the installer, I had placed a line I'd copied from Ubuntu's example configuration:

  d-i partman-auto/disk string /dev/sda 

The virtio_blk driver was ready to be used, but I was still telling the installer to use the non-virtio device. Installation to the virtio block device succeeded after I replaced that line with this one:

  d-i partman/early_command string debconf-set partman-auto/disk "$(list-devices disk | head -n1)"

--
Brian