If I set glance_api_version=2 I get the following in cinder-volume.log when I do a upload-to-image:
2013-08-09 11:41:14.333 ERROR cinder.openstack.common.rpc.amqp [req-5e1cd5b0-18df-4ab6-a7bd-0a2050558be4 7680199f420d4e2a9c9527896b2550fe 5f827bafd54145959c7ea00f4eeae47a] Exception during message handling
2013-08-09 11:41:14.333 TRACE cinder.openstack.common.rpc.amqp Traceback (most recent call last):
2013-08-09 11:41:14.333 TRACE cinder.openstack.common.rpc.amqp File "/opt/stack/cinder/cinder/openstack/common/rpc/amqp.py", line 433, in _process_data
2013-08-09 11:41:14.333 TRACE cinder.openstack.common.rpc.amqp **args)
2013-08-09 11:41:14.333 TRACE cinder.openstack.common.rpc.amqp File "/opt/stack/cinder/cinder/openstack/common/rpc/dispatcher.py", line 148, in dispatch
2013-08-09 11:41:14.333 TRACE cinder.openstack.common.rpc.amqp return getattr(proxyobj, method)(ctxt, **kwargs)
2013-08-09 11:41:14.333 TRACE cinder.openstack.common.rpc.amqp File "/opt/stack/cinder/cinder/volume/manager.py", line 458, in copy_volume_to_image
2013-08-09 11:41:14.333 TRACE cinder.openstack.common.rpc.amqp payload['message'] = unicode(error)
2013-08-09 11:41:14.333 TRACE cinder.openstack.common.rpc.amqp File "/usr/lib/python2.7/contextlib.py", line 24, in __exit__
2013-08-09 11:41:14.333 TRACE cinder.openstack.common.rpc.amqp self.gen.next()
2013-08-09 11:41:14.333 TRACE cinder.openstack.common.rpc.amqp File "/opt/stack/cinder/cinder/volume/manager.py", line 452, in copy_volume_to_image
2013-08-09 11:41:14.333 TRACE cinder.openstack.common.rpc.amqp image_meta)
2013-08-09 11:41:14.333 TRACE cinder.openstack.common.rpc.amqp File "/opt/stack/cinder/cinder/volume/drivers/rbd.py", line 569, in copy_volume_to_image
2013-08-09 11:41:14.333 TRACE cinder.openstack.common.rpc.amqp image_meta, tmp_file)
2013-08-09 11:41:14.333 TRACE cinder.openstack.common.rpc.amqp File "/opt/stack/cinder/cinder/image/image_utils.py", line 294, in upload_volume
2013-08-09 11:41:14.333 TRACE cinder.openstack.common.rpc.amqp image_service.update(context, image_id, {}, image_file)
2013-08-09 11:41:14.333 TRACE cinder.openstack.common.rpc.amqp File "/opt/stack/cinder/cinder/image/glance.py", line 276, in update
2013-08-09 11:41:14.333 TRACE cinder.openstack.common.rpc.amqp _reraise_translated_image_exception(image_id)
2013-08-09 11:41:14.333 TRACE cinder.openstack.common.rpc.amqp File "/opt/stack/cinder/cinder/image/glance.py", line 274, in update
2013-08-09 11:41:14.333 TRACE cinder.openstack.common.rpc.amqp **image_meta)
2013-08-09 11:41:14.333 TRACE cinder.openstack.common.rpc.amqp File "/opt/stack/cinder/cinder/image/glance.py", line 149, in call
2013-08-09 11:41:14.333 TRACE cinder.openstack.common.rpc.amqp return getattr(client.images, method)(*args, **kwargs)
2013-08-09 11:41:14.333 TRACE cinder.openstack.common.rpc.amqp File "/opt/stack/python-glanceclient/glanceclient/v2/images.py", line 133, in update
2013-08-09 11:41:14.333 TRACE cinder.openstack.common.rpc.amqp setattr(image, key, value)
2013-08-09 11:41:14.333 TRACE cinder.openstack.common.rpc.amqp File "/usr/local/lib/python2.7/dist-packages/warlock/model.py", line 72, in __setattr__
2013-08-09 11:41:14.333 TRACE cinder.openstack.common.rpc.amqp self.__setitem__(key, value)
2013-08-09 11:41:14.333 TRACE cinder.openstack.common.rpc.amqp File "/usr/local/lib/python2.7/dist-packages/warlock/model.py", line 48, in __setitem__
2013-08-09 11:41:14.333 TRACE cinder.openstack.common.rpc.amqp raise exceptions.InvalidOperation(msg)
2013-08-09 11:41:14.333 TRACE cinder.openstack.common.rpc.amqp InvalidOperation: Unable to set 'purge_props' to 'True'
This operation works fine with glance_api_ver=1
ok so having now looked into this, it looks like the problem is that the Glance V2 image schema does not contain purge_props. I think this is actually a bug in Glance since as a result, there is now no way to purge properties (actually default in Glance is True so there is no way to disable pure_properties). I think we should disable this property for v2 call in cinder for now and I will raise a separate issue on Glance.