Fail to launch an instance from volume by legacy bdm

Bug #1322180 reported by Feodor Tersin
14
This bug affects 3 people
Affects Status Importance Assigned to Milestone
OpenStack Compute (nova)
Fix Released
Undecided
Feodor Tersin

Bug Description

Launting an instance from bootable volume passing legacy bdm is available only using vda (no /dev/ prefix) as root device name. This is weird restriction. It prevents to create consistent instance data, because root_device_name instance attribute has /dev/ prefix, but device_name bdm attribute doesn't.

Environment: DevStack

Steps to reproduce:
1 Create bootable volume
$ cinder create --image-id xxx 1
Note: I used cirros-0.3.2-x86_64-uec ami image.

2 Boot instance from the volume by legacy bdm.
$ nova boot --flavor m1.nano --block-device-mapping /dev/vda=yyy:::1 inst

3 Wait instance status Active, go to instance console and look to 'No bootable device' message.

The reason is in _get_bdm_image_metadata in nova/compute/api.py. There only 'vda' devices are processed as root device for legacy bdm.

Feodor Tersin (ftersin)
Changed in nova:
assignee: nobody → Feodor Tersin (ftersin)
status: New → Confirmed
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to nova (master)

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

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

Reviewed: https://review.openstack.org/95568
Committed: https://git.openstack.org/cgit/openstack/nova/commit/?id=00ac56a100ac7329a01b5f1fa336b99e64778eaf
Submitter: Jenkins
Branch: master

commit 00ac56a100ac7329a01b5f1fa336b99e64778eaf
Author: ftersin <email address hidden>
Date: Mon May 26 20:07:55 2014 +0400

    Run instance root device determination fix.

    Legacy bdm in incoming parameters contains a number of devices
    specified by their names (e.g. "vdb" or "/dev/vdc").
    Current code considers "vda" as root device and doesn't work on
    "/dev/vda", for example.
    This fix extracts the last significant character (digits
    are skipped in "..sda1") from the name like "a", "b", "c" and
    selects the root device by checking for "a".

    Change-Id: Iebaa117bb747d30ac9ceabd8805740dec9d1355c
    Closes-Bug: #1322180

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