| Summary: | Cannot upload volume to image if volume was created from image that has custom metadata | ||
|---|---|---|---|
| Product: | Red Hat OpenStack | Reporter: | nalmond |
| Component: | openstack-cinder | Assignee: | Eric Harney <eharney> |
| Status: | CLOSED ERRATA | QA Contact: | lkuchlan <lkuchlan> |
| Severity: | medium | Docs Contact: | |
| Priority: | medium | ||
| Version: | 6.0 (Juno) | CC: | eharney, jschluet, sgotliv, srevivo, tbarron |
| Target Milestone: | async | Keywords: | ZStream |
| Target Release: | 6.0 (Juno) | ||
| Hardware: | x86_64 | ||
| OS: | Linux | ||
| Whiteboard: | |||
| Fixed In Version: | openstack-cinder-2014.2.4-7.el7ost | Doc Type: | Bug Fix |
| Doc Text: | Story Points: | --- | |
| Clone Of: | Environment: | ||
| Last Closed: | 2016-06-23 18:37:31 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: | |
Tested using: openstack-cinder-2014.2.4-7.el7ost.noarch Verification flow: 1. Upload image to glance [root@dhcp162-21 ~(keystone_admin)]# glance image-create --name image --disk-format qcow2 --container-format bare --copy-from http://download.cirros-cloud.net/0.3.4/cirros-0.3.4-x86_64-disk.img +------------------+--------------------------------------+ | Property | Value | +------------------+--------------------------------------+ | checksum | None | | container_format | bare | | created_at | 2016-06-22T12:25:24 | | deleted | False | | deleted_at | None | | disk_format | qcow2 | | id | e083f22f-9b8a-416f-9ff1-1bb054d1f270 | | is_public | False | | min_disk | 0 | | min_ram | 0 | | name | image | | owner | a5270b5b26084d68b8d7ea42fd84af78 | | protected | False | | size | 13287936 | | status | queued | | updated_at | 2016-06-22T12:25:24 | | virtual_size | None | +------------------+--------------------------------------+ [root@dhcp162-21 ~(keystone_admin)]# glance image-list +--------------------------------------+--------+-------------+------------------+----------+--------+ | ID | Name | Disk Format | Container Format | Size | Status | +--------------------------------------+--------+-------------+------------------+----------+--------+ | be863887-bf30-4b04-b682-2a265d6fd6db | cirros | qcow2 | bare | 13200896 | active | | e083f22f-9b8a-416f-9ff1-1bb054d1f270 | image | qcow2 | bare | 13287936 | active | +--------------------------------------+--------+-------------+------------------+----------+--------+ 2. Create volume from image [root@dhcp162-21 ~(keystone_admin)]# cinder create 1 --image-id e083f22f-9b8a-416f-9ff1-1bb054d1f270 +---------------------+--------------------------------------+ | Property | Value | +---------------------+--------------------------------------+ | attachments | [] | | availability_zone | nova | | bootable | false | | created_at | 2016-06-22T12:34:07.421743 | | display_description | None | | display_name | None | | encrypted | False | | id | eb35b371-79a8-4e71-9dee-17f8069f4232 | | image_id | e083f22f-9b8a-416f-9ff1-1bb054d1f270 | | metadata | {} | | size | 1 | | snapshot_id | None | | source_volid | None | | status | creating | | volume_type | None | +---------------------+--------------------------------------+ [root@dhcp162-21 ~(keystone_admin)]# cinder list +--------------------------------------+-----------+--------------+------+-------------+----------+-------------+ | ID | Status | Display Name | Size | Volume Type | Bootable | Attached to | +--------------------------------------+-----------+--------------+------+-------------+----------+-------------+ | eb35b371-79a8-4e71-9dee-17f8069f4232 | available | None | 1 | None | true | | +--------------------------------------+-----------+--------------+------+-------------+----------+-------------+ 3. Upload volume as image back to glance [root@dhcp162-21 ~(keystone_admin)]# cinder upload-to-image eb35b371-79a8-4e71-9dee-17f8069f4232 image2 +---------------------+--------------------------------------+ | Property | Value | +---------------------+--------------------------------------+ | container_format | bare | | disk_format | raw | | display_description | None | | id | eb35b371-79a8-4e71-9dee-17f8069f4232 | | image_id | 0bcf5204-0e6b-40de-8374-9eaadddcc813 | | image_name | image2 | | size | 1 | | status | uploading | | updated_at | 2016-06-22T12:34:19.000000 | | volume_type | None | +---------------------+--------------------------------------+ [root@dhcp162-21 ~(keystone_admin)]# glance image-list +--------------------------------------+--------+-------------+------------------+------------+--------+ | ID | Name | Disk Format | Container Format | Size | Status | +--------------------------------------+--------+-------------+------------------+------------+--------+ | e083f22f-9b8a-416f-9ff1-1bb054d1f270 | image | qcow2 | bare | 13287936 | active | | 0bcf5204-0e6b-40de-8374-9eaadddcc813 | image2 | raw | bare | 1073741824 | active | +--------------------------------------+--------+-------------+------------------+------------+--------+ Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://access.redhat.com/errata/RHBA-2016:1315 |
Description of problem: If a volume was created from an image that had metadata set on it, and later attempt to use cinder upload-to-image, the process fails with: /var/log/cinder/api.log:8053: INFO cinder.api.openstack.wsgi [req-fc26ad1e-04e1-41b6-b494-3c03e3fa7d3c 2fa2cef88f9742448fd8180054eeade5 396f6c55aba34d8fade57c21ae00ed5d - - -] HTTP exception thrown: Unable to set 'properties' to '{u'sgas_os': u'Ubuntu', u'sgas_usage_type': u'Ubuntu', u'sgas_product_component_name': u'PUB-CLD-WORK-SOFT-010'}' How reproducible: Always on images with custom metadata. Does not appear on Red Hat provided images, which don't have the extra metadata in place. Steps to Reproduce: 1. Upload image to glance 2. Create volume from image 3. Upload volume as image back to glance Actual results: Process fails with the error show above Expected results: Image uploads successfully Additional info: This appears to be the same issue seen here: https://bugs.launchpad.net/mos/+bug/1523457