Skip to content

Conversation

@hsiangkao
Copy link

Also see: containerd/nerdbox#30

Currently, it's mainly used for EROFS to merge hundreds of sub-blobs (container image layers) into one block device to avoid having too many block devices (and it would even be impossible for virtio-mmio since legacy IRQs is much limited in libkrun).

Why VMDK is useful? Since it seems to be the only standard and simple way to support one-single block device that consists of a collection of multiple file parts among popular virtualization products such as QEMU and VirtualBox.

Update the krun_add_disk2 API to specify the VMDK format:

  • KRUN_DISK_FORMAT_VMDK

Currently, it's mainly used for EROFS to merge hundreds of sub-blobs
(container image layers) into one block device to avoid having too
many block devices (and it would even be impossible for virtio-mmio
since legacy IRQs is much limited in libkrun).

Why VMDK is useful?  Since it seems to be the only standard and simple
way to support one-single block device that consists of a collection of
multiple file parts among popular virtualization products such as QEMU
and VirtualBox.

Update the `krun_add_disk2` API to specify the VMDK format:
 - KRUN_DISK_FORMAT_VMDK

Signed-off-by: Gao Xiang <hsiangkao@linux.alibaba.com>
polly = { path = "../polly" }
rutabaga_gfx = { path = "../rutabaga_gfx", features = ["virgl_renderer", "virgl_renderer_next"], optional = true }
imago = { version = "0.1.5", features = ["sync-wrappers", "vm-memory"] }
imago = { features = ["sync-wrappers", "vm-memory"], git = "https://gitlab.com/hreitz/imago.git", branch = "main" }
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We can only consume dependencies published on crates.io. The stable branch of imago doesn't have vmdk support, so we need to wait a bit for 0.2.0 to be released.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Currently nerdbox will directly rely on this but libkrun doesn't support virtio-pci so the total number of virtio-blk device is much limited (even support it still ineffencient compared to this way.

BTW, vmdk support is much seperate from the main raw and qcow2 support, I wonder if it might be fine for 0.1.x? or is there some timeline to release 0.2.0? Cc @XanClic

Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I’m working on 0.2.0, it should be doable by next week. If I can’t get it done, I’ll make at least an 0.1.7 with it.

Copy link
Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

That is awesome, Thank you all!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants