Skip to contentSkip to conversation

Several questions about " [PATCH v3 0/5] virtio-9p: hotplug and migration support"

Qemu-devel wangyan 2 participants 2 messages Mar 5, 2019 – Mar 11, 2019 2 messages not in the archive

lore
Share & tools
lore

A message that is not in the archive (sent off-list or not yet received): [email protected]

A message that is not in the archive (sent off-list or not yet received): [email protected]

wangyan

author
#2 lore raw

I am very happy for your reply.

I am very interested in your old WIP and want to take a look.

Our project still use 9pfs, and it needs to live migrate the device while it is being used by the guest, is there any advice for us to make it come true or any WIP about this?

Quoted 45 lines · Greg Kurz
Quoted 6 lines · On Tue, 26 Feb 2019 11:17:16 +0800 wangyan <[email protected]> wrote:

Dear Kurz,

Good day.

This is Yan Wang from china. Glad to contact with you.

Hi Yan Wang,

Quoted 2 lines

I found your patch "[Qemu-devel] [PATCH v3 0/5] virtio-9p: hotplug and migration support" on the internet. Recently, our project need to use the feature of 9pfs living migration, and I want to know if you have the plan to merge the patch to the master branch of qemu, or do you have any other plans about the migration feature?

AFAIK some of these patches have already been merged.

https://git.qemu.org/?p=qemu.git;a=commitdiff;h=4652f1640e029e1f2433fa77ba6af285c7cd923a
https://git.qemu.org/?p=qemu.git;a=commitdiff;h=6cecf093735f2e5af7d0e29d957350320044e354

These are enough to live-migrate a quiescent virtio-9p device, ie, only if the 9p filesystem is NOT mounted in the guest.

If your need is to live migrate the device while it is being used by the guest, then this is a different story. Basically, this requires to quiesce the device so that its state can be captured. Also, some state belongs to the host and maybe hard to capture/migrate. For example, if the guest opens a file, write some data in it, unlinks the file but keeps the fd, it expects to be able to read the same data back, even after migration to some other host system.

9pfs is no longer a priority for anyone in the industry. I have no plan to make this go forward, an not much time to work on it. But if you want to have a look, I guess I can share some old WIP I have somewhere.

Quoted 4 lines

Sincerely,

Yan Wang

Cheers,

--
Greg

.

#3 lore raw
Quoted 8 lines · On Tue, 5 Mar 2019 19:28:37 +0800 wangyan <[email protected]> wrote:

I am very happy for your reply.

I am very interested in your old WIP and want to take a look.

Our project still use 9pfs, and it needs to live migrate the device while it is being used by the guest, is there any advice for us to make it come true or any WIP about this?

It isn't a trivial task, really. The first thing to address is to be able to drain outstanding I/O requests. Then, about migration itself, the current idea was to close files at pre-save so that they get re-open automatically on the target if migration succeeds or on the source if migration fails. Then we get to some more gory details: files open with O_EXCL and unlinked open files...

Quoted 49 lines · Greg Kurz
Quoted 45 lines
Quoted 6 lines · On Tue, 26 Feb 2019 11:17:16 +0800 wangyan <[email protected]> wrote:

Dear Kurz,

Good day.

This is Yan Wang from china. Glad to contact with you.

Hi Yan Wang,

Quoted 2 lines

I found your patch "[Qemu-devel] [PATCH v3 0/5] virtio-9p: hotplug and migration support" on the internet. Recently, our project need to use the feature of 9pfs living migration, and I want to know if you have the plan to merge the patch to the master branch of qemu, or do you have any other plans about the migration feature?

AFAIK some of these patches have already been merged.

https://git.qemu.org/?p=qemu.git;a=commitdiff;h=4652f1640e029e1f2433fa77ba6af285c7cd923a
https://git.qemu.org/?p=qemu.git;a=commitdiff;h=6cecf093735f2e5af7d0e29d957350320044e354

These are enough to live-migrate a quiescent virtio-9p device, ie, only if the 9p filesystem is NOT mounted in the guest.

If your need is to live migrate the device while it is being used by the guest, then this is a different story. Basically, this requires to quiesce the device so that its state can be captured. Also, some state belongs to the host and maybe hard to capture/migrate. For example, if the guest opens a file, write some data in it, unlinks the file but keeps the fd, it expects to be able to read the same data back, even after migration to some other host system.

9pfs is no longer a priority for anyone in the industry. I have no plan to make this go forward, an not much time to work on it. But if you want to have a look, I guess I can share some old WIP I have somewhere.

Quoted 4 lines

Sincerely,

Yan Wang

Cheers,

--
Greg

.