Skip to contentSkip to conversation

3.0.3rc3 qcow image created with qemu-img not usable?

DISCUSSION Timo Benk 2 participants 4 messages Oct 12, 2006

lore
Share & tools
lore

Timo Benk

author
#0 lore raw

Hi,

i am new to the qcow image format, so please forgive me if the following is just totally stupid:-)

I try to use a qcow formatted image in Xen created by qemu-img.

# qemu-img create -f qcow /tmp/test.img 1G

Then i try to attach that image to Domain-0.

# xm block-attach Domain-0 tap:qcow:/tmp/test.img /dev/xvda1 w 0

No error message so far, but ...

# mount /dev/xvda1 /mnt
mount: special device /dev/xvda1 does not exist
# xm block-list Domain-0
Vdev  BE handle state evt-ch ring-ref BE-path
51714    0    0     3      23     8
  /local/domain/0/backend/tap/0/51714
# xm block-detach Domain-0 /dev/xvda1
# xm block-list Domain-0
Vdev  BE handle state evt-ch ring-ref BE-path
51714    0    0     3      23     8
  /local/domain/0/backend/tap/0/51714

qcow images created with qcow-create are working without any problems.

And a few additional questions i have:

- Is qcow encryption supported?
- is qcow compression supported?

Greetings,
-timo

Signature · 2 lines
Timo Benk - Jabber ID: [email protected] - ICQ ID: #241877854
PGP Public Key: http://m28s01.vlinux.de/timo_benk_gpg_key.asc
#1 lore raw

You cannot attach block devices to Domain-0. Furthermore, you cannot attach non-raw file-based block devices to paravirtual domains.

Regards,

Anthony Liugoir

Quoted 40 lines · Timo Benk

Hi,

i am new to the qcow image format, so please forgive me if the following is just totally stupid:-)

I try to use a qcow formatted image in Xen created by qemu-img.

# qemu-img create -f qcow /tmp/test.img 1G

Then i try to attach that image to Domain-0.

# xm block-attach Domain-0 tap:qcow:/tmp/test.img /dev/xvda1 w 0

No error message so far, but ...

# mount /dev/xvda1 /mnt
mount: special device /dev/xvda1 does not exist
# xm block-list Domain-0
Vdev  BE handle state evt-ch ring-ref BE-path
51714    0    0     3      23     8
  /local/domain/0/backend/tap/0/51714
# xm block-detach Domain-0 /dev/xvda1
# xm block-list Domain-0
Vdev  BE handle state evt-ch ring-ref BE-path
51714    0    0     3      23     8
  /local/domain/0/backend/tap/0/51714

qcow images created with qcow-create are working without any problems.

And a few additional questions i have:

- Is qcow encryption supported?
- is qcow compression supported?

Greetings,
-timo

author
#2 lore raw
Quoted 2 lines · Anthony Liguori

You cannot attach block devices to Domain-0. Furthermore, you cannot attach non-raw file-based block devices to paravirtual domains.

I can and Xen can do so too :-)

I just followed the description in [1].

And the point is as i have explained: it works with qcow-create created images but not with qemu-img created images.

I do not know if that is by design or a bug.

IMHO the Xen qcow format is compatible with qemu so it should work.

[1]http://xenbits.xensource.com/xen-3.0.3-testing.hg/tools/blktap/README

Greetings,
-timo

Signature · 2 lines
Timo Benk - Jabber ID: [email protected] - ICQ ID: #241877854
PGP Public Key: http://m28s01.vlinux.de/timo_benk_gpg_key.asc
#3 lore raw
Quoted 7 lines · Timo Benk
Quoted 3 lines · Anthony Liguori

You cannot attach block devices to Domain-0. Furthermore, you cannot attach non-raw file-based block devices to paravirtual domains.

I can and Xen can do so too :-)

Sorry, I forgot about blktap...

blktap requires a certain cluster size for qcow images IIRC. That's probably why qemu-img doesn't work.

Regards,

Anthony Liguori

Quoted 14 lines

I just followed the description in [1].

And the point is as i have explained: it works with qcow-create created images but not with qemu-img created images.

I do not know if that is by design or a bug.

IMHO the Xen qcow format is compatible with qemu so it should work.

[1]http://xenbits.xensource.com/xen-3.0.3-testing.hg/tools/blktap/README

Greetings,
-timo