create snapshot success by error status volume

Bug #1283338 reported by lirenke
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Cinder
Fix Released
High
lirenke

Bug Description

I create a LVM volume with too large size, my cinder-volumes VG's free space is insufficient. so, the volume's status is "error".
But, when I try to create a snapshot by this error volume, it' ok, and the snapshot' status is "available", progress is "100%".

I find that in cinder.volume.manager.py, create_shapshot, self.driver.create_snapshot return false, but only exception would be hanlde and set to error status.So, after that, the snapshot is ok in db.

some logs show that:

"""
2014-02-22 10:55:07.439 29737 ERROR cinder.brick.local_dev.lvm [req-6d37df28-1cb6-444c-a1e9-26654905acb9 ca7015d9004a41528498c114e0a6ebf1 55a50a99a42441e585b7a5c34214ecef] Unable to find LV: volume-8cb6eb05-6bfa-4422-a683-2cceb4c4ff1f
2014-02-22 10:55:07.498 29737 INFO cinder.volume.manager [req-6d37df28-1cb6-444c-a1e9-26654905acb9 ca7015d9004a41528498c114e0a6ebf1 55a50a99a42441e585b7a5c34214ecef] snapshot 9e2e363b-a0ed-4be8-9874-ced1c8705fde: created successfully
"""

Changed in cinder:
status: New → Confirmed
importance: Undecided → High
assignee: nobody → John Griffith (john-griffith)
Revision history for this message
lirenke (lvhancy) wrote :

Let me try fixing it.

Changed in cinder:
assignee: John Griffith (john-griffith) → lirenke (lvhancy)
lirenke (lvhancy)
Changed in cinder:
status: Confirmed → In Progress
Revision history for this message
lirenke (lvhancy) wrote :

Here is my review link (I don't know why it can't paste by openstack fru):

https://review.openstack.org/#/c/77875/

Mike Perez (thingee)
Changed in cinder:
milestone: none → icehouse-rc1
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to cinder (master)

Reviewed: https://review.openstack.org/77875
Committed: https://git.openstack.org/cgit/openstack/cinder/commit/?id=379273925517e8b9bf971e018a1dc41f809c4814
Submitter: Jenkins
Branch: master

commit 379273925517e8b9bf971e018a1dc41f809c4814
Author: lirenke <lvhancy@163.com>
Date: Tue Mar 4 04:59:07 2014 -0800

    Can't force-create snapshot by an non-exist error volume

    If we create an LVM volume whose size larger than
    rest space in VG, the volume would not exist with
    error status.
    But then we still can force create a snapshot
    by this volume, and the snapshot's status is available.
    In the code,I found in create_lv_snapshot,
    it return False when fail to get the volume.
    However, raising an exception is only way to be
    handle outside.
    So, we should raise exception instead of return False.

    Closes-Bug: #1283338

    Change-Id: I80256f19d66da460c95ff23834abb79a557763bf

Changed in cinder:
status: In Progress → Fix Committed
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to cinder (stable/havana)

Fix proposed to branch: stable/havana
Review: https://review.openstack.org/83261

Thierry Carrez (ttx)
Changed in cinder:
status: Fix Committed → Fix Released
lirenke (lvhancy)
Changed in cinder:
assignee: lirenke (lvhancy) → nobody
assignee: nobody → lirenke (lvhancy)
Thierry Carrez (ttx)
Changed in cinder:
milestone: icehouse-rc1 → 2014.1
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.