[Pkg-libvirt-maintainers] Bug#512773: Bug#512773: [virt-manager] Unable to create a non-sparse image file from the VM creation wizard

Laurent Léonard laurent at open-minds.org
Fri Jan 23 17:24:51 UTC 2009


Le vendredi 23 janvier 2009 à 17:28, Guido Günther a écrit :
> On Fri, Jan 23, 2009 at 04:43:09PM +0100, Laurent Léonard wrote:
> > Package: virt-manager
> > Version: 0.6.0-6
> > Severity: normal
> >
> > --- Please enter the report below this line. ---
> > The VM creation wizard is unable to create a non-sparse image file, even
> > if the checkbox "Allocate entire virtual disk now?" is checked (default
> > state). The problem comes from the virtinst package, in the file
> > /usr/share/python- support/virtinst/virtinst/VirtualDisk.py, line 342-348
> > :
> >                     if self.sparse:
> >                         alloc = 0
> >                     else:
> >                         #alloc = cap
> >                         # XXX: disable setting managed storage as
> > nonsparse # XXX: since it hoses libvirtd (for now) alloc = 0
>
> Does setting alloc = 1 work for you?
>  -- Guido

cap = capacity size
alloc = allocation size

So to have a non-sparse image, "alloc" should have the same value as "cap". 
But in the current version of virtinst, the line "alloc = cap" is commented 
out and replaced by "alloc = 0", so the behaviour is the same as an sparse 
image file, but I don't know the reason of this (I don't understand the 
comment)...

If I put "alloc = cap" back, the non-sparse image file is correctly created 
when "Allocate entire virtual disk now?" is checked, but I get the following 
error message at the end of the VM creation wizard :

Impossible de finir l'installation : « Couldn't create storage 
volume 'test.img': 'unknown procedure (received 6, expected 5d)' »

Unable to complete install '<type 'exceptions.RuntimeError'> Couldn't create 
storage volume 'test_wiz.img': 'unknown procedure (received 6, expected 5d)'
Traceback (most recent call last):
  File "/usr/share/virt-manager/virtManager/create.py", line 728, in 
do_install
    dom = guest.start_install(False, meter = meter)
  File "/var/lib/python-support/python2.5/virtinst/Guest.py", line 735, in 
start_install
    return self._do_install(consolecb, meter, removeOld, wait)
  File "/var/lib/python-support/python2.5/virtinst/Guest.py", line 765, in 
_do_install
    self._create_devices(meter)
  File "/var/lib/python-support/python2.5/virtinst/Guest.py", line 630, in 
_create_devices
    disk.setup(progresscb)
  File "/var/lib/python-support/python2.5/virtinst/VirtualDisk.py", line 450, 
in setup
    self._set_vol_object(self.vol_install.install(meter=progresscb),
  File "/var/lib/python-support/python2.5/virtinst/Storage.py", line 893, in 
install
    (self.name, str(e)))
RuntimeError: Couldn't create storage volume 'test_wiz.img': 'unknown 
procedure (received 6, expected 5d)'
'

I suppose the image creation method is different in the storage pool manager 
because it works great.

-- 
Laurent Léonard
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 197 bytes
Desc: This is a digitally signed message part.
Url : http://lists.alioth.debian.org/pipermail/pkg-libvirt-maintainers/attachments/20090123/0efb83af/attachment.pgp 


More information about the Pkg-libvirt-maintainers mailing list