nova api v2.1 does not allow to use autodetection of volume device path
Affects | Status | Importance | Assigned to | Milestone | |
---|---|---|---|---|---|
OpenStack Compute (nova) |
Fix Released
|
Critical
|
Davanum Srinivas (DIMS) | ||
Juno |
Won't Fix
|
Undecided
|
Unassigned | ||
Kilo |
Fix Released
|
High
|
Matt Riedemann | ||
python-novaclient |
Fix Released
|
High
|
Matt Riedemann |
Bug Description
Using API v2.1 we are forced to provide device path attaching a volume to an instance.
using API v2.0 it allowed to provide 'auto' and in this case Nova calculated it by itself.
It is very useful when we do not care about exact device path.
using APi v2.1 Nova, at first verifies request body [1] and only then have logic to autodetect "device path". So, either autodetect is dead code now or request validation should be changed.
For the moment, this bug is blocker for Manila project.
We get one of two errors:
Returning 400 to user: Invalid input for field/attribute device. Value: None. None is not of type 'string' __call__
or
Returning 400 to user: Invalid input for field/attribute device. Value: auto. u'auto' does not match '(^/dev/
Where Nova client says explicitly:
$ nova help volume-attach
usage: nova volume-attach <server> <volume> [<device>]
Attach a volume to a server.
Positional arguments:
<server> Name or ID of server.
<volume> ID of the volume to attach.
<device> Name of the device e.g. /dev/vdb. Use "auto" for autoassign (if supported)
That "device" is optional and can be set to 'auto'.
tags: | added: api |
description: | updated |
description: | updated |
Changed in nova: | |
importance: | Undecided → Critical |
tags: | added: liberty-rc-blocker |
Changed in nova: | |
assignee: | Davanum Srinivas (DIMS) (dims-v) → Sean Dague (sdague) |
tags: | removed: api juno-backport-potential kilo-backport-potential liberty-rc-blocker |
Changed in python-novaclient: | |
importance: | Undecided → High |
Changed in nova: | |
assignee: | Sean Dague (sdague) → Matt Riedemann (mriedem) |
status: | Invalid → In Progress |
Changed in nova: | |
assignee: | Matt Riedemann (mriedem) → Davanum Srinivas (DIMS) (dims-v) |
Changed in python-novaclient: | |
milestone: | none → 2.28.0 |
status: | Fix Committed → Fix Released |
tags: | added: juno-backport-potential |
Changed in nova: | |
milestone: | none → liberty-rc1 |
status: | Fix Committed → Fix Released |
Changed in nova: | |
milestone: | liberty-rc1 → 12.0.0 |
Also, official docs for v2.1 says that "device" is optional, see http:// developer. openstack. org/api- ref-compute- v2.1.html# attachVolume