Thank you for your help! 

On Sun, Jul 7, 2024 at 9:24 PM <smooney@redhat.com> wrote:
On Sun, 2024-07-07 at 16:04 +0800, Jiatong Shen wrote:
> Hello,
>
>
>    I am searching whether it is possible to use both virtio-scsi and
> virtio-blk at the same time for one instance.
not offically but yes.

you can use one format for the root disk and you can technically can set the disk bus
in the block device mappings for cidner volumes

lookikg at the history of this it looks like very early in nova it was inteded to allow multiple
disk buses to be used back when nova-volumes was a feature priror to cinder but when cinder was
create the supprot was not removed but never properly supported either.


the ened result is you can do this when booting a vm using the old nova-volume code paths
but cannot do this when attaching after the vm is created.

actuuly supporting this properly for atching cinder volume includign ensureing we hotplug
the correct storage contoler ectra would be a new fauter  and require api changes.

see the block_device_mapping_v2.disk_bus filed  https://docs.openstack.org/api-ref/compute/#id11 for
details and https://docs.openstack.org/nova/latest/user/block-device-mapping.html#block-device-mapping-v2

in general this is a cose of possibel but not recommended as it only exists due to backward compatiabltiy rahter
then being an intended and supported feature.

>  I knew it was possible to use
> each of them separately. I have this requirement because virtio-blk is not
> possible to support as many as devices like virtio-scsi, but we still want
> to keep virtio-blk for performance reasons and for legacy instances.
>
>   Thank you for help.
>



--

Best Regards,

Jiatong Shen