Comment 2 for bug 1871759

Revision history for this message
Christian Rohmann (christian-rohmann) wrote :

I just attempted to use the documented command from https://review.opendev.org/c/openstack/cinder/+/746929 but that failed with a syntax error on the OpenStack client to select a microversion of the

1) List volumes
--- cut ---
# openstack volume list -f csv -c ID -c Status -c Size

"ID","Status","Size"
"0f92d1d8-456b-41b9-a53e-b8cdb959a42e","in-use",10
"d9bbb60b-0b83-45d4-8088-70160cd1d12d","in-use",10
--- cut ---

As you can see two attached volumes with 10G size each.

2) Attempt to extend one volume to 20G
--- cut ---
# openstack volume set d9bbb60b-0b83-45d4-8088-70160cd1d12d --size 20
Failed to set volume size: Volume is in in-use state, it must be available before size can be extended
One or more of the set operations failed
--- cut ---

3) Now try to extend using the api-version option as documented by your patch

--- cut ---
# openstack volume --os-volume-api-version 3.42 set d9bbb60b-0b83-45d4-8088-70160cd1d12d --size 20

volume version 3.42 is not in supported versions: 1, 2, 3
Invalid volume client version '3.42'. must be one of: 2, 3

# openstack volume --os-volume-api-version 3 set d9bbb60b-0b83-45d4-8088-70160cd1d12d --size 20

volume version 3.42 is not in supported versions: 1, 2, 3
Invalid volume client version '3.42'. must be one of: 2, 3
--- cut ---

Maybe just setting the major version to 3 is enough?

--- cut ---
# openstack volume --os-volume-api-version 3 set d9bbb60b-0b83-45d4-8088-70160cd1d12d --size 20
Failed to set volume size: Volume is in in-use state, it must be available before size can be extended
One or more of the set operations failed
--- cut ---

4) Using the cinder client to extend the volume just works

--- cut ---
# cinder extend d9bbb60b-0b83-45d4-8088-70160cd1d12d 20

# openstack volume list -f csv -c ID -c Status -c Size

"ID","Status","Size"
"0f92d1d8-456b-41b9-a53e-b8cdb959a42e","in-use",10
"d9bbb60b-0b83-45d4-8088-70160cd1d12d","in-use",20
--- cut ---

FYI the supported versions in my OpenStack Train environment are ...

--- cut ---
# openstack versions show -f csv

"Region Name","Service Type","Version","Status","Endpoint","Min Microversion","Max Microversion"
"fra","block-storage","2.0","DEPRECATED","https://volume.cloud.redacted/v2/","",""
"fra","block-storage","3.0","CURRENT","https://volume.cloud.redacted/v3/","3.0","3.59"
--- cut ---