Bug 1659264
| Summary: | [RHOS 13] cinder ignores errors from glanceclient when creating volumes | |||
|---|---|---|---|---|
| Product: | Red Hat OpenStack | Reporter: | Eric Harney <eharney> | |
| Component: | openstack-cinder | Assignee: | Brian Rosmaita <brian.rosmaita> | |
| Status: | CLOSED ERRATA | QA Contact: | Tzach Shefi <tshefi> | |
| Severity: | high | Docs Contact: | Kim Nylander <knylande> | |
| Priority: | medium | |||
| Version: | 13.0 (Queens) | CC: | abishop, amcleod, tshefi | |
| Target Milestone: | --- | Keywords: | Triaged, ZStream | |
| Target Release: | 13.0 (Queens) | |||
| Hardware: | Unspecified | |||
| OS: | Unspecified | |||
| Whiteboard: | ||||
| Fixed In Version: | openstack-cinder-12.0.4-7.el7ost | Doc Type: | Bug Fix | |
| Doc Text: |
Previously, a code change in the Pike release introduced a regression, causing Cinder to ignore some IOError exceptions that the glanceclient raised when downloading an image. If one of these ignored exceptions occurred, a volume could be created with truncated or corrupt data.
With this update, the code was modified and these exceptions are no longer ignored. As a result, when an IOError occurs during image download, Cinder logs and handles the exception correctly.
|
Story Points: | --- | |
| Clone Of: | ||||
| : | 1664687 (view as bug list) | Environment: | ||
| Last Closed: | 2019-03-14 13:47:53 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: | ||||
| Bug Depends On: | 1664687 | |||
| Bug Blocks: | ||||
|
Description
Eric Harney
2018-12-13 22:51:58 UTC
Upstream patch has been submitted by someone else, so we need to track its progress and handle the backports. This isn't going to be a simple backport from Rocky to Queens upstream. See https://bugs.launchpad.net/cinder/+bug/1799221/comments/12 for more info. Tip to self for verification steps follow: https://bugzilla.redhat.com/show_bug.cgi?id=1664687#c10 Minor note: there's no 'multihash' (os_hash_algo + os_hash_value) in Queens Glance, so you'll have to just modify the 'checksum' field. Verified on: openstack-cinder-12.0.4-8.el7ost.noarch Thanks Brian per your tip :) Uploaded image to glance: #glance image-create --disk-format qcow2 --container-format bare --name cirros.bad --file cirros-0.3.5-i386-disk.img I then changed checksum via SQL access Before change: | a43dba56-4732-4ca0-9050-c849cb6252ed | cirros.bad | 40602 | active | 2019-02-28 13:19:52 | 2019-02-28 13:19:53 | NULL | 0 | qcow2 | bare | 0e4128f7bacfd887b8dbf450b46357bc | e7979f642cfa40e8872bdd11ce912505 | 0 | 0 | 0 | NULL | shared | MariaDB [glance]> update images set checksum="0e4128f7bacfd887b8dbf450b4635zzz" where name="cirros.bad"; | a43dba56-4732-4ca0-9050-c849cb6252ed | cirros.bad | 40602 | active | 2019-02-28 13:19:52 | 2019-02-28 13:19:53 | NULL | 0 | qcow2 | bare | 0e4128f7bacfd887b8dbf450b4635zzz | e7979f642cfa40e8872bdd11ce912505 | 0 | 0 | 0 | NULL | shared | Now try to create a volume to said image, should fail #cinder create 1 --image cirros.bad -> | id | c034d180-b04a-4927-8b89-5b605603e41f Cinder list -> c034d180-b04a-4927-8b89-5b605603e41f | error | - | 1 | - | false | | Cinder create fails as expected. logs reports the expected error, so were good to verify -> /var/log/containers/cinder/cinder-volume.log:1313:2019-02-28 13:27:14.599 70 ERROR oslo_messaging.rpc.server ImageDownloadFailed: Failed to download image a43dba56-4732-4ca0-9050-c849cb6252ed, reason: IOError: 32 Corrupt image download. Checksum was 0e4128f7bacfd887b8dbf450b46357bc expected 0e4128f7bacfd887b8dbf450b4635zzz 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-2019:0560 |