Note: This bug is displayed in read-only format because the product is no longer active in Red Hat Bugzilla.

Bug 1135075

Summary: Ceph - failed to create volume with extra_specs
Product: Red Hat OpenStack Reporter: bkopilov <bkopilov>
Component: openstack-cinderAssignee: Eric Harney <eharney>
Status: CLOSED NOTABUG QA Contact: nlevinki <nlevinki>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 5.0 (RHEL 7)CC: bkopilov, eharney, yeylon
Target Milestone: ---   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-08-28 19:35:03 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
var/log/cinder none

Description bkopilov 2014-08-28 19:14:34 UTC
Description of problem:
openstack on rhel 7.0  rhos 5 . 
When we configure volume type with extra_spec , new volume creation with this type fails .

Example:
We create volume type and set  ( from tempest) volume spec :
resp, body = self.client.create_volume_type(
            vol_type_name,
            extra_specs=extra_specs)

The extra spec contains : 
'storage_protocol' : 'iSCSI'
'vendor_name' :'Open Source'

Version-Release number of selected component (if applicable):


How reproducible:


Steps to Reproduce:
Tempest code to reproduce :
volume = {}
        vol_name = data_utils.rand_name("volume-")
        vol_type_name = data_utils.rand_name("volume-type-")
        proto = CONF.volume.storage_protocol
        vendor = CONF.volume.vendor_name
        extra_specs = {"storage_protocol": proto,
                       "vendor_name": vendor}
        body = {}
        resp, body = self.client.create_volume_type(
            vol_type_name,
            extra_specs=extra_specs)
        self.assertEqual(200, resp.status)
        self.assertIn('id', body)
        self.addCleanup(self._delete_volume_type, body['id'])
        self.assertIn('name', body)
        resp, volume = self.volumes_client.create_volume(
            size=1, display_name=vol_name,
            volume_type=vol_type_name)

Actual results:


Expected results:


Additional info:

Comment 1 Eric Harney 2014-08-28 19:25:13 UTC
Please attach the Cinder API and volume logs.

Comment 2 bkopilov 2014-08-28 19:26:08 UTC
Created attachment 932453 [details]
var/log/cinder

Comment 4 Eric Harney 2014-08-28 19:35:03 UTC
This looks like expected behavior.  The request has storage_protocol 'iSCSI' but your only volume service node is using the RBD driver which only supports storage_protocol 'ceph'.

Therefore the scheduler shows:
2014-08-28 21:53:33.109 10899 DEBUG cinder.openstack.common.scheduler.filters.capabilities_filter [req-921abe80-001e-4337-9991-0d9af37659ff 1ee4f072978f48d7a45895c865f1d06c e11ccd93e986401e87197a91ee16e651 - - -] extra_spec requirement 'iSCSI' does not match 'ceph' _satisfies_extra_specs /usr/lib/python2.7/site-packages/cinder/openstack/common/scheduler/filters/capabilities_filter.py:55

2014-08-28 21:53:33.109 10899 DEBUG cinder.openstack.common.scheduler.filters.capabilities_filter [req-921abe80-001e-4337-9991-0d9af37659ff 1ee4f072978f48d7a45895c865f1d06c e11ccd93e986401e87197a91ee16e651 - - -] host 'test7920': free_capacity_gb: 488 fails resource_type extra_specs requirements host_passes /usr/lib/python2.7/site-packages/cinder/openstack/common/scheduler/filters/capabilities_filter.py:68

2014-08-28 21:53:33.110 10899 ERROR cinder.scheduler.flows.create_volume [req-921abe80-001e-4337-9991-0d9af37659ff 1ee4f072978f48d7a45895c865f1d06c e11ccd93e986401e87197a91ee16e651 - - -] Failed to schedule_create_volume: No valid host was found.