Hi, it's very interesting patchset.

I also research reconnecting issue for vhost-user-blk and SPDK.
Did you support a case when vhost backend is not started but QEMU does?

Regards,
Yury

06.12.2018, 09:37, "elohi...@gmail.com" <elohi...@gmail.com>:
> From: Xie Yongji <xieyon...@baidu.com>
>
> This patchset is aimed at supporting qemu to reconnect
> vhost-user-blk backend after vhost-user-blk backend crash or
> restart.
>
> The patch 1 tries to implenment the sync connection for
> "reconnect socket".
>
> The patch 2 introduces a new message VHOST_USER_SET_VRING_INFLIGHT
> to support offering shared memory to backend to record
> its inflight I/O.
>
> The patch 3,4 are the corresponding libvhost-user patches of
> patch 2. Make libvhost-user support VHOST_USER_SET_VRING_INFLIGHT.
>
> The patch 5 supports vhost-user-blk to reconnect backend when
> connection closed.
>
> The patch 6 tells qemu that we support reconnecting now.
>
> To use it, we could start qemu with:
>
> qemu-system-x86_64 \
>         -chardev socket,id=char0,path=/path/vhost.socket,reconnect=1,wait \
>         -device vhost-user-blk-pci,chardev=char0 \
>
> and start vhost-user-blk backend with:
>
> vhost-user-blk -b /path/file -s /path/vhost.socket
>
> Then we can restart vhost-user-blk at any time during VM running.
>
> Xie Yongji (6):
>   char-socket: Enable "wait" option for client mode
>   vhost-user: Add shared memory to record inflight I/O
>   libvhost-user: Introduce vu_queue_map_desc()
>   libvhost-user: Support recording inflight I/O in shared memory
>   vhost-user-blk: Add support for reconnecting backend
>   contrib/vhost-user-blk: enable inflight I/O recording
>
>  chardev/char-socket.c | 5 +-
>  contrib/libvhost-user/libvhost-user.c | 215 ++++++++++++++++++++----
>  contrib/libvhost-user/libvhost-user.h | 19 +++
>  contrib/vhost-user-blk/vhost-user-blk.c | 3 +-
>  hw/block/vhost-user-blk.c | 169 +++++++++++++++++--
>  hw/virtio/vhost-user.c | 69 ++++++++
>  hw/virtio/vhost.c | 8 +
>  include/hw/virtio/vhost-backend.h | 4 +
>  include/hw/virtio/vhost-user-blk.h | 4 +
>  include/hw/virtio/vhost-user.h | 8 +
>  10 files changed, 452 insertions(+), 52 deletions(-)
>
> --
> 2.17.1

Reply via email to