[HyperV]: Config drive is not attached to instance after resized or migrated

Bug #1321640 reported by Feng Ju
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Compute (nova)
Fix Released
Medium
Matt Riedemann
Icehouse
Fix Released
Medium
Feng Ju

Bug Description

If we use config-drive (whether set --config-drive=true in boot command or set force_config_drive=always in nova.conf), there is bug for config-drive when resize or migrate instances on hyperv.

You can see from current nova codes:
https://github.com/openstack/nova/blob/master/nova/virt/hyperv/migrationops.py#L269
when finished migration, there is no code to attach configdrive.iso or configdrive.vhd to the resized instance. compared to boot instance (https://github.com/openstack/nova/blob/master/nova/virt/hyperv/vmops.py#L226). Although this commit https://review.openstack.org/#/c/55975/ handled coping configdrive to resized or migrated instance, there is no code to attach it after resized or migrated.

Feng Ju (jufeng)
Changed in nova:
assignee: nobody → Feng Ju (jufeng)
Changed in nova:
status: New → In Progress
Revision history for this message
Lance Bragstad (lbragstad) wrote :
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to nova (stable/icehouse)

Fix proposed to branch: stable/icehouse
Review: https://review.openstack.org/96660

tags: added: hyper-v
Changed in nova:
importance: Undecided → Medium
Changed in nova:
assignee: Feng Ju (jufeng) → Matt Riedemann (mriedem)
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to nova (master)

Reviewed: https://review.openstack.org/94556
Committed: https://git.openstack.org/cgit/openstack/nova/commit/?id=513c6bbd36563e57a85d33f9c94f4a20ab7c00f4
Submitter: Jenkins
Branch: master

commit 513c6bbd36563e57a85d33f9c94f4a20ab7c00f4
Author: jufeng <email address hidden>
Date: Wed May 21 16:24:53 2014 +0800

    Fix attaching config drive issue on Hyper-V when migrate instances

    After instance resized or migrated on Hyper-V hypervisor.
    The configdrive iso or vhd is copied to resized or migrated
    instance, but is not attached to instance.

    Because there are configurations for config drive like
    config_drive_cdrom, config_drive_format, and the configurations
    on different Hyper-V compute node may be different. it will need
    to convert configdrive format after resized or migrated.
    It is easy to convert from iso9660 or vfat to vhd, but it seems
    impossible to convert from vhd to iso9660 or vfat.
    So this commit just ignore the target Hyper-V compute node's
    config drive configurations, leave the original config drive format.

    Change-Id: I349e3b2221fff0ae217a71a91895afd21ff7d18d
    Closes-Bug: #1321640

Changed in nova:
status: In Progress → Fix Committed
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Change abandoned on nova (stable/icehouse)

Change abandoned by Thierry Carrez (<email address hidden>) on branch: stable/icehouse
Review: https://review.openstack.org/96660
Reason: Abandoned on Matt and Alessandro's request

Thierry Carrez (ttx)
Changed in nova:
milestone: none → juno-3
status: Fix Committed → Fix Released
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to nova (stable/icehouse)

Reviewed: https://review.openstack.org/96660
Committed: https://git.openstack.org/cgit/openstack/nova/commit/?id=7523ab4d1956c024647e8106de88e34b2d999d50
Submitter: Jenkins
Branch: stable/icehouse

commit 7523ab4d1956c024647e8106de88e34b2d999d50
Author: jufeng <email address hidden>
Date: Wed May 21 16:24:53 2014 +0800

    Fix attaching config drive issue on Hyper-V when migrate instances

    After instance resized or migrated on Hyper-V hypervisor.
    The configdrive iso or vhd is copied to resized or migrated
    instance, but is not attached to instance.

    Because there are configurations for config drive like
    config_drive_cdrom, config_drive_format, and the configurations
    on different Hyper-V compute node may be different. it will need
    to convert configdrive format after resized or migrated.
    It is easy to convert from iso9660 or vfat to vhd, but it seems
    impossible to convert from vhd to iso9660 or vfat.
    So this commit just ignore the target Hyper-V compute node's
    config drive configurations, leave the original config drive format.

    Closes-Bug: #1321640
    (cherry picked from commit 513c6bbd36563e57a85d33f9c94f4a20ab7c00f4)

    Conflicts:
     nova/virt/hyperv/pathutils.py

    Change-Id: I349e3b2221fff0ae217a71a91895afd21ff7d18d

tags: added: in-stable-icehouse
Thierry Carrez (ttx)
Changed in nova:
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.