Add Daniel On 10.11.25 13:39, Alexandr Moshkov wrote:
v3: - use pre_load_errp instead of pre_load in vhost.c - change vhost-user-blk property to "skip-get-vring-base-inflight-migration" - refactor vhost-user-blk.c, by moving vhost_user_blk_inflight_needed() higherv2: - rewrite migration using VMSD instead of qemufile API - add vhost-user-blk parameter instead of migration capability I don't know if VMSD was used cleanly in migration implementation, so feel free for comments. Based on Vladimir's work: [PATCH v2 00/25] vhost-user-blk: live-backend local migration which was based on: - [PATCH v4 0/7] chardev: postpone connect (which in turn is based on [PATCH 0/2] remove deprecated 'reconnect' options) - [PATCH v3 00/23] vhost refactoring and fixes - [PATCH v8 14/19] migration: introduce .pre_incoming() vmsd handler
Hi! On my series about backend-transfer migration, the final consensus (or at least, I hope that it's a consensus:) is that using device properties to control migration channel content is wrong. And we should instead use migration parameters. (discussion here: https://lore.kernel.org/qemu-devel/[email protected]/ ) So the API for backend-transfer features is a migration parameter backend-transfer = [ list of QOM paths of devices, for which we want to enable backend-transfer ] and user don't have to change device properties in runtime to setup the following migration. So I assume, similar practice should be applied here: don't use device properties to control migration. So, should it be a parameter like migrate-inflight-region = [ list of QOM paths of vhost-user devices ] ?
Based-on: <[email protected]> Based-on: <[email protected]> Based-on: <[email protected]> Based-on: <[email protected]> Based-on: <[email protected]> --- Hi! During inter-host migration, waiting for disk requests to be drained in the vhost-user backend can incur significant downtime. This can be avoided if QEMU migrates the inflight region in vhost-user-blk. Thus, during the qemu migration, the vhost-user backend can cancel all inflight requests and then, after migration, they will be executed on another host. At first, I tried to implement migration for all vhost-user devices that support inflight at once, but this would require a lot of changes both in vhost-user-blk (to transfer it to the base class) and in the vhost-user-base base class (inflight implementation and remodeling + a large refactor). Therefore, for now I decided to leave this idea for later and implement the migration of the inflight region first for vhost-user-blk. Alexandr Moshkov (3): vmstate: introduce VMSTATE_VBUFFER_UINT64 vhost: add vmstate for inflight region with inner buffer vhost-user-blk: support inter-host inflight migration hw/block/vhost-user-blk.c | 29 +++++++++++++++++++++ hw/virtio/vhost.c | 42 ++++++++++++++++++++++++++++++ include/hw/virtio/vhost-user-blk.h | 1 + include/hw/virtio/vhost.h | 6 +++++ include/migration/vmstate.h | 10 +++++++ 5 files changed, 88 insertions(+)
-- Best regards, Vladimir
