From: Jonah Palmer <jonah.palmer@oracle.com>
To: Markus Armbruster <armbru@redhat.com>
Cc: qemu-devel@nongnu.org, peterx@redhat.com, farosas@suse.de,
eblake@redhat.com, jasowang@redhat.com, mst@redhat.com,
si-wei.liu@oracle.com, eperezma@redhat.com,
boris.ostrovsky@oracle.com
Subject: Re: [RFC 1/6] migration: Add virtio-iterative capability
Date: Mon, 11 Aug 2025 08:18:17 -0400 [thread overview]
Message-ID: <5a8bb5ef-c500-4fac-b5fc-566408ae8ffc@oracle.com> (raw)
In-Reply-To: <874iuihyxd.fsf@pond.sub.org>
On 8/8/25 6:48 AM, Markus Armbruster wrote:
> I apologize for the lateness of my review.
>
> Jonah Palmer <jonah.palmer@oracle.com> writes:
>
>> Adds a new migration capability 'virtio-iterative' that will allow
>> virtio devices, where supported, to iteratively migrate configuration
>> changes that occur during the migration process.
>
> Why is that desirable?
>
To be frank, I wasn't sure if having a migration capability, or even
have it toggleable at all, would be desirable or not. It appears though
that this might be better off as a per-device feature set via
--device virtio-net-pci,iterative-mig=on,..., for example.
And by "iteratively migrate configuration changes" I meant more along
the lines of the device's state as it continues running on the source.
But perhaps actual configuration changes (e.g. changing the number of
queue pairs) could also be supported mid-migration like this?
>> This capability is added to the validated capabilities list to ensure
>> both the source and destination support it before enabling.
>
> What happens when only one side enables it?
>
The migration stream breaks if only one side enables it.
This is poor wording on my part, my apologies. I don't think it's even
possible to know the capabilities between the source & destination.
>> The capability defaults to off to maintain backward compatibility.
>>
>> To enable the capability via HMP:
>> (qemu) migrate_set_capability virtio-iterative on
>>
>> To enable the capability via QMP:
>> {"execute": "migrate-set-capabilities", "arguments": {
>> "capabilities": [
>> { "capability": "virtio-iterative", "state": true }
>> ]
>> }
>> }
>>
>> Signed-off-by: Jonah Palmer <jonah.palmer@oracle.com>
>> ---
>> migration/savevm.c | 1 +
>> qapi/migration.json | 7 ++++++-
>> 2 files changed, 7 insertions(+), 1 deletion(-)
>>
>> diff --git a/migration/savevm.c b/migration/savevm.c
>> index bb04a4520d..40a2189866 100644
>> --- a/migration/savevm.c
>> +++ b/migration/savevm.c
>> @@ -279,6 +279,7 @@ static bool should_validate_capability(int capability)
>> switch (capability) {
>> case MIGRATION_CAPABILITY_X_IGNORE_SHARED:
>> case MIGRATION_CAPABILITY_MAPPED_RAM:
>> + case MIGRATION_CAPABILITY_VIRTIO_ITERATIVE:
>> return true;
>> default:
>> return false;
>> diff --git a/qapi/migration.json b/qapi/migration.json
>> index 4963f6ca12..8f042c3ba5 100644
>> --- a/qapi/migration.json
>> +++ b/qapi/migration.json
>> @@ -479,6 +479,11 @@
>> # each RAM page. Requires a migration URI that supports seeking,
>> # such as a file. (since 9.0)
>> #
>> +# @virtio-iterative: Enable iterative migration for virtio devices, if
>> +# the device supports it. When enabled, and where supported, virtio
>> +# devices will track and migrate configuration changes that may
>> +# occur during the migration process. (Since 10.1)
>
> When and why should the user enable this?
>
Well if all goes according to plan, always (at least for virtio-net).
This should improve the overall speed of live migration for a virtio-net
device (and vhost-net/vhost-vdpa).
> What exactly do you mean by "where supported"?
>
I meant if both source's Qemu and destination's Qemu support it, as well
as for other virtio devices in the future if they decide to implement
iterative migration (e.g. a more general "enable iterative migration for
virtio devices").
But I think for now this is better left as a virtio-net configuration
rather than as a migration capability (e.g. --device
virtio-net-pci,iterative-mig=on/off,...)
> docs/devel/qapi-code-gen.rst:
>
> For legibility, wrap text paragraphs so every line is at most 70
> characters long.
>
> Separate sentences with two spaces.
>
Ack - thank you.
>> +#
>> # Features:
>> #
>> # @unstable: Members @x-colo and @x-ignore-shared are experimental.
>> @@ -498,7 +503,7 @@
>> { 'name': 'x-ignore-shared', 'features': [ 'unstable' ] },
>> 'validate-uuid', 'background-snapshot',
>> 'zero-copy-send', 'postcopy-preempt', 'switchover-ack',
>> - 'dirty-limit', 'mapped-ram'] }
>> + 'dirty-limit', 'mapped-ram', 'virtio-iterative'] }
>>
>> ##
>> # @MigrationCapabilityStatus:
>
next prev parent reply other threads:[~2025-08-11 12:19 UTC|newest]
Thread overview: 66+ messages / expand[flat|nested] mbox.gz Atom feed top
2025-07-22 12:41 [RFC 0/6] virtio-net: initial iterative live migration support Jonah Palmer
2025-07-22 12:41 ` [RFC 1/6] migration: Add virtio-iterative capability Jonah Palmer
2025-08-06 15:58 ` Peter Xu
2025-08-07 12:50 ` Jonah Palmer
2025-08-07 13:13 ` Peter Xu
2025-08-07 14:20 ` Jonah Palmer
2025-08-08 10:48 ` Markus Armbruster
2025-08-11 12:18 ` Jonah Palmer [this message]
2025-08-25 12:44 ` Markus Armbruster
2025-08-25 14:57 ` Jonah Palmer
2025-08-26 6:11 ` Markus Armbruster
2025-08-26 18:08 ` Jonah Palmer
2025-08-27 6:37 ` Markus Armbruster
2025-08-28 15:29 ` Jonah Palmer
2025-08-29 9:24 ` Markus Armbruster
2025-09-01 14:10 ` Jonah Palmer
2025-07-22 12:41 ` [RFC 2/6] virtio-net: Reorder vmstate_virtio_net and helpers Jonah Palmer
2025-07-22 12:41 ` [RFC 3/6] virtio-net: Add SaveVMHandlers for iterative migration Jonah Palmer
2025-07-22 12:41 ` [RFC 4/6] virtio-net: iter live migration - migrate vmstate Jonah Palmer
2025-07-23 6:51 ` Michael S. Tsirkin
2025-07-24 14:45 ` Jonah Palmer
2025-07-25 9:31 ` Michael S. Tsirkin
2025-07-28 12:30 ` Jonah Palmer
2025-07-22 12:41 ` [RFC 5/6] virtio, virtio-net: skip consistency check in virtio_load for iterative migration Jonah Palmer via
2025-07-28 15:30 ` [RFC 5/6] virtio,virtio-net: " Eugenio Perez Martin
2025-07-28 16:23 ` Jonah Palmer
2025-07-30 8:59 ` Eugenio Perez Martin
2025-08-06 16:27 ` Peter Xu
2025-08-07 14:18 ` Jonah Palmer
2025-08-07 16:31 ` Peter Xu
2025-08-11 12:30 ` Jonah Palmer
2025-08-11 13:39 ` Peter Xu
2025-08-11 21:26 ` Jonah Palmer
2025-08-11 21:55 ` Peter Xu
2025-08-12 15:51 ` Jonah Palmer
2025-08-13 9:25 ` Eugenio Perez Martin
2025-08-13 14:06 ` Peter Xu
2025-08-14 9:28 ` Eugenio Perez Martin
2025-08-14 16:16 ` Dragos Tatulea
2025-08-14 20:27 ` Peter Xu
2025-08-15 14:50 ` Jonah Palmer
2025-08-15 19:35 ` Si-Wei Liu
2025-08-18 6:51 ` Eugenio Perez Martin
2025-08-18 14:46 ` Jonah Palmer
2025-08-18 16:21 ` Peter Xu
2025-08-19 7:20 ` Eugenio Perez Martin
2025-08-19 7:10 ` Eugenio Perez Martin
2025-08-19 15:10 ` Jonah Palmer
2025-08-20 7:59 ` Eugenio Perez Martin
2025-08-25 12:16 ` Jonah Palmer
2025-08-27 16:55 ` Jonah Palmer
2025-09-01 6:57 ` Eugenio Perez Martin
2025-09-01 13:17 ` Jonah Palmer
2025-09-02 7:31 ` Eugenio Perez Martin
2025-07-22 12:41 ` [RFC 6/6] virtio-net: skip vhost_started assertion during " Jonah Palmer
2025-07-23 5:51 ` [RFC 0/6] virtio-net: initial iterative live migration support Jason Wang
2025-07-24 21:59 ` Jonah Palmer
2025-07-25 9:18 ` Lei Yang
2025-07-25 9:33 ` Michael S. Tsirkin
2025-07-28 7:09 ` Jason Wang
2025-07-28 7:35 ` Jason Wang
2025-07-28 12:41 ` Jonah Palmer
2025-07-28 14:51 ` Eugenio Perez Martin
2025-07-28 15:38 ` Eugenio Perez Martin
2025-07-29 2:38 ` Jason Wang
2025-07-29 12:41 ` Jonah Palmer
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=5a8bb5ef-c500-4fac-b5fc-566408ae8ffc@oracle.com \
--to=jonah.palmer@oracle.com \
--cc=armbru@redhat.com \
--cc=boris.ostrovsky@oracle.com \
--cc=eblake@redhat.com \
--cc=eperezma@redhat.com \
--cc=farosas@suse.de \
--cc=jasowang@redhat.com \
--cc=mst@redhat.com \
--cc=peterx@redhat.com \
--cc=qemu-devel@nongnu.org \
--cc=si-wei.liu@oracle.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).