LVM brick instantiation fails on volume_migration

Bug #1258128 reported by Flavio Percoco on 2013-12-05
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Cinder
High
Flavio Percoco
Havana
Undecided
Unassigned

Bug Description

The lvm driver uses positional arguments to create a new instance for the LVM brick. Some of those arguments are being passed in the wrong position. Kwargs should be used in this case instead.

http://git.openstack.org/cgit/openstack/cinder/tree/cinder/volume/drivers/lvm.py#n711

Changed in cinder:
assignee: nobody → Flavio Percoco (flaper87)

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

Changed in cinder:
status: New → In Progress

Reviewed: https://review.openstack.org/60264
Committed: http://github.com/openstack/cinder/commit/69ce114232f9102220b45c8242eda3e78872a3e6
Submitter: Jenkins
Branch: master

commit 69ce114232f9102220b45c8242eda3e78872a3e6
Author: Flavio Percoco <email address hidden>
Date: Thu Dec 5 13:48:24 2013 +0100

    LVM migrate: Use keywords for the brick instance

    In the `migrate_volume` method a new instance is created when the
    dest_vg is not equal to the source vg. This new brick instance is
    created using positional arguments instead of keywords. However, some of
    those arguments are passed in the wrong positions.

    This patch uses keywords for the misplaced arguments.

    The patch also changes `test_lvm_migrate_volume_proceed` in order to
    fully test the happy path and catch things like this.

    Closes-bug: #1258128
    Change-Id: I75cf91171709554053fd5b52a4aae4e176e8364e

Changed in cinder:
status: In Progress → Fix Committed
Eric Harney (eharney) on 2013-12-09
Changed in cinder:
importance: Undecided → High

Reviewed: https://review.openstack.org/60956
Committed: https://git.openstack.org/cgit/openstack/cinder/commit/?id=f39441662d1b6ffee65fe2e485d6e0034682c5aa
Submitter: Jenkins
Branch: stable/havana

commit f39441662d1b6ffee65fe2e485d6e0034682c5aa
Author: Flavio Percoco <email address hidden>
Date: Thu Dec 5 13:48:24 2013 +0100

    LVM migrate: Use keywords for the brick instance

    In the `migrate_volume` method a new instance is created when the
    dest_vg is not equal to the source vg. This new brick instance is
    created using positional arguments instead of keywords. However, some of
    those arguments are passed in the wrong positions.

    This patch uses keywords for the misplaced arguments.

    The patch also changes `test_lvm_migrate_volume_proceed` in order to
    fully test the happy path and catch things like this.

    Closes-bug: #1258128
    (cherry picked from commit 69ce114232f9102220b45c8242eda3e78872a3e6)

    Conflicts:
     cinder/volume/drivers/lvm.py

    Change-Id: I75cf91171709554053fd5b52a4aae4e176e8364e

tags: added: in-stable-havana
Thierry Carrez (ttx) on 2014-01-22
Changed in cinder:
milestone: none → icehouse-2
status: Fix Committed → Fix Released
Thierry Carrez (ttx) on 2014-04-17
Changed in cinder:
milestone: icehouse-2 → 2014.1
To post a comment you must log in.
This report contains Public information  Edit
Everyone can see this information.

Other bug subscribers