cinder-manage volume reattach is broken

Bug #1167931 reported by stephen mulcahy
8
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Cinder
Fix Released
Undecided
Thang Pham

Bug Description

It has two problems that I can see,

1. It is using volume['instance_id'] instead of volume['instance_uuid'] which is trivial to fix

but

2. It relies on db.instance_get which is not available in cinder db but in nova db but I don't think we want to create a dependency between cinder-manage and nova db so unsure how to proceed here. Is there an api which calls like this from cinder to nova should be using?

Revision history for this message
Michael Kerrin (michael-kerrin-w) wrote :

volume reattach should be in nova-manage, and should be removed from cinder-manage

Revision history for this message
John Griffith (john-griffith) wrote :

Michael is correct on that. Although Cinder will need something on it's side as well to ensure/fix and DB cruft.

Changed in cinder:
status: New → Invalid
Revision history for this message
Ray Chen (chenrano2002) wrote :

db.instance_get is missing.

Changed in cinder:
status: Invalid → Confirmed
Revision history for this message
Thang Pham (thang-pham) wrote :

I ran into this while implement my blueprint: https://blueprints.launchpad.net/cinder/+spec/unit-test-cases-for-cinder-scripts. I will look into fixing it.

Changed in cinder:
assignee: nobody → Thang Pham (thang-pham)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to cinder (master)

Fix proposed to branch: master
Review: https://review.openstack.org/109784

Changed in cinder:
status: Confirmed → In Progress
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to cinder (master)

Reviewed: https://review.openstack.org/109784
Committed: https://git.openstack.org/cgit/openstack/cinder/commit/?id=2581edd8e45deed7e43530e5890925f9fc81e143
Submitter: Jenkins
Branch: master

commit 2581edd8e45deed7e43530e5890925f9fc81e143
Author: Thang Pham <email address hidden>
Date: Fri Jul 25 20:37:06 2014 -0400

    Remove reattach function in cinder-manage

    The reattach function in cinder-manage depends on
    db.instance_get, which is not available in cinder db.
    db.instance_get is only available in nova db. Hence, the
    reattach function should be removed from cinder-manage.

    Change-Id: If33bf2f281735bd530641c1e6d15e9645f38b4b4
    Closes-Bug: #1167931

Changed in cinder:
status: In Progress → Fix Committed
Thierry Carrez (ttx)
Changed in cinder:
milestone: none → juno-3
status: Fix Committed → Fix Released
Thierry Carrez (ttx)
Changed in cinder:
milestone: juno-3 → 2014.2
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.