VM cannot attach volume with multiattach attribute

asked 2018-05-22 03:42:18 -0500

yafeng gravatar image

updated 2018-05-22 03:43:10 -0500

Create multiattach volume:

$ cinder type-create multiattach

$ cinder type-key multiattach set multiattach="<is> True"

$ cinder create <volume_size> --name <volume_name> --volume-type <volume_type_uuid>

When attaching volume to VM, error log is printed: ERROR oslo_messaging.rpc.server MultiattachNotSupportedByVirtDriver: Volume 5189e65a-6573-4823-9061-2e9bd08df272 has 'multiattach' set, which is not supported for this instance.

edit retag flag offensive close merge delete

Comments

MultiattachNotSupportedByVirtDriverindicates that the compute node hosting the instance doesn't support multiattach volumes. Multiattach is supported by libvirt, starting with Queens (https://specs.openstack.org/openstack...).

Bernd Bausch gravatar imageBernd Bausch ( 2018-05-22 04:18:50 -0500 )edit

You also need to specify Nova microversion 2.60 when attaching (see http://git.openstack.org/cgit/opensta...).

Bernd Bausch gravatar imageBernd Bausch ( 2018-05-22 04:23:37 -0500 )edit

I'm new to openstack. Could you tell me how to check if Nova microversion 2.60 already exists? If not, how to upgrade?

yafeng gravatar imageyafeng ( 2018-05-22 21:39:35 -0500 )edit

It exists in Queens. You have to explicitly request it with the openstack client’s command line option --os-compute-api-version 2.60, or by setting the environment variable OS_COMPUTE_API_VERSION to 2.60. If you think this should be better documented, I agree.

Bernd Bausch gravatar imageBernd Bausch ( 2018-05-22 21:53:08 -0500 )edit

I installed openstack on one single VM with packstack.

rpm -qa | grep nova

openstack-nova-api-17.0.3-1.el7.noarch

It's not Queen? the latest openstack version?

yafeng gravatar imageyafeng ( 2018-05-22 22:36:57 -0500 )edit