VMware ESX and vSphere drivers do not support config drive

Bug #1206584 reported by Davanum Srinivas (DIMS)
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
OpenStack Compute (nova)
Fix Released
High
Davanum Srinivas (DIMS)

Bug Description

KVM, Xen and Hyper-v drivers support the force_config_drive option to generate an ISO with the metadata needed by the guest vm. Can we please add that to the vmware drivers too?

Tags: vmware
Revision history for this message
Shawn Hartsock (hartsock) wrote :
Changed in nova:
importance: Undecided → High
importance: High → Wishlist
status: New → Confirmed
Revision history for this message
Davanum Srinivas (DIMS) (dims-v) wrote :
Changed in nova:
status: Confirmed → In Progress
assignee: nobody → Davanum Srinivas (DIMS) (dims-v)
Revision history for this message
Shawn Hartsock (hartsock) wrote :

Thanks for your effort around this. This seems to be higher priority than I had believed.

Changed in nova:
importance: Wishlist → High
milestone: none → havana-3
tags: added: grizzly-backport-potential
Revision history for this message
Tracy Jones (tjones-i) wrote :
Download full text (4.4 KiB)

i was able to make this work by changing the cdrom unit # to 1. When it was 0 i got the following error

2013-08-12 16:18:19.241 DEBUG nova.virt.vmwareapi.vmware_images [req-782c73c0-d1a2-4d1b-8032-759abfe0e8a8 demo demo] Uploading iso of size : 419840 from (pid=47436) upload_iso_to_datastore /opt/stack/nova/nova/virt/vmwareapi/vmware_images.py:106
2013-08-12 16:18:19.760 DEBUG nova.virt.vmwareapi.vmware_images [req-782c73c0-d1a2-4d1b-8032-759abfe0e8a8 demo demo] [instance: 7298cc19-aa0e-45ac-94d0-f28f3719ca09] Uploaded iso /tmp/tmpwzTgVN/configdrive.iso to datastore from (pid=47436) upload_iso_to_datastore /opt/stack/nova/nova/virt/vmwareapi/vmware_images.py:115
2013-08-12 16:18:19.761 DEBUG nova.virt.vmwareapi.read_write_util [req-782c73c0-d1a2-4d1b-8032-759abfe0e8a8 demo demo] Exception during HTTP connection close in VMwareHTTPWrite. Exception is from (pid=47436) close /opt/stack/nova/nova/virt/vmwareapi/read_write_util.py:147
2013-08-12 16:18:19.791 DEBUG nova.virt.vmwareapi.volumeops [req-782c73c0-d1a2-4d1b-8032-759abfe0e8a8 demo demo] Reconfiguring VM instance instance-00000013 to attach cdrom [Datastore_60G] 7298cc19-aa0e-45ac-94d0-f28f3719ca09/configdrive.iso from (pid=47436) attach_cdrom_to_vm /opt/stack/nova/nova/virt/vmwareapi/volumeops.py:55
2013-08-12 16:18:24.902 WARNING nova.virt.vmwareapi.driver [-] Task [ReconfigVM_Task] (returnval){
   value = "task-468"
   _type = "Task"
 } status: error Invalid configuration for device '0'.
2013-08-12 16:18:24.904 ERROR nova.compute.manager [req-782c73c0-d1a2-4d1b-8032-759abfe0e8a8 demo demo] [instance: 7298cc19-aa0e-45ac-94d0-f28f3719ca09] Instance failed to spawn
2013-08-12 16:18:24.904 TRACE nova.compute.manager [instance: 7298cc19-aa0e-45ac-94d0-f28f3719ca09] Traceback (most recent call last):
2013-08-12 16:18:24.904 TRACE nova.compute.manager [instance: 7298cc19-aa0e-45ac-94d0-f28f3719ca09] File "/opt/stack/nova/nova/compute/manager.py", line 1353, in _spawn
2013-08-12 16:18:24.904 TRACE nova.compute.manager [instance: 7298cc19-aa0e-45ac-94d0-f28f3719ca09] block_device_info)
2013-08-12 16:18:24.904 TRACE nova.compute.manager [instance: 7298cc19-aa0e-45ac-94d0-f28f3719ca09] File "/opt/stack/nova/nova/virt/vmwareapi/driver.py", line 209, in spawn
2013-08-12 16:18:24.904 TRACE nova.compute.manager [instance: 7298cc19-aa0e-45ac-94d0-f28f3719ca09] admin_password, network_info, block_device_info)
2013-08-12 16:18:24.904 TRACE nova.compute.manager [instance: 7298cc19-aa0e-45ac-94d0-f28f3719ca09] File "/opt/stack/nova/nova/virt/vmwareapi/vmops.py", line 437, in spawn
2013-08-12 16:18:24.904 TRACE nova.compute.manager [instance: 7298cc19-aa0e-45ac-94d0-f28f3719ca09] uploaded_iso_path)
2013-08-12 16:18:24.904 TRACE nova.compute.manager [instance: 7298cc19-aa0e-45ac-94d0-f28f3719ca09] File "/opt/stack/nova/nova/virt/vmwareapi/volumeops.py", line 60, in attach_cdrom_to_vm
2013-08-12 16:18:24.904 TRACE nova.compute.manager [instance: 7298cc19-aa0e-45ac-94d0-f28f3719ca09] self._session._wait_for_task(instance_uuid, reconfig_task)
2013-08-12 16:18:24.904 TRACE nova.compute.manager [instance: 7298cc19-aa0e-45ac-94d0-f28f3719ca09] File "/opt/stack/nova/nova/virt/vmwareapi...

Read more...

Revision history for this message
Tracy Jones (tjones-i) wrote :

and by "this work" i meant the patch https://review.openstack.org/#/c/40029/13

Revision history for this message
Davanum Srinivas (DIMS) (dims-v) wrote :

Tracy, i changed the default unitNumber from 0 to 1. Hopefully that should be enough. In the future we may want to be able to discover the controller key and the device number (OR) be able to configure the values in nova.conf. Let's leave that for later

Revision history for this message
Tracy Jones (tjones-i) wrote :

better to make a config (i see you did). should that be an instance specific param though??

Revision history for this message
Davanum Srinivas (DIMS) (dims-v) wrote :

Tracy, yes, i made it a config. it's global for now. I am not sure we need it to be install specific, we may end up querying controller to figure out what the unit number should be for a specific esx. we probably have to ask folks with more knowledge of various esxi/vcenter versions and configurations.

Revision history for this message
Davanum Srinivas (DIMS) (dims-v) wrote :

Tracy,

this cdrom unit number is bugging me! Can you please let me know which vmdk you used to test? is it the default debian vmdk? did you use "ide" as the vmware_adaptertype when register the image to glance?

thanks,
dims

Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix merged to nova (master)

Reviewed: https://review.openstack.org/40029
Committed: http://github.com/openstack/nova/commit/3c59d998c5e6b80549053b01f919ac318cd31b13
Submitter: Jenkins
Branch: master

commit 3c59d998c5e6b80549053b01f919ac318cd31b13
Author: Davanum Srinivas <email address hidden>
Date: Fri Aug 2 20:07:02 2013 -0400

    VMware: Config Drive Support

    Create the config drive iso, upload it to the correct location,
    then create a VirtualMachineConfigSpec with appropriate contents
    and run the ReconfigVM_Task to enable the iso.

    DocImpact

    Fixes LP# 1206584
    Fixes BP vmware-config-drive-support

    Change-Id: I1df1e61edbff9f3a68940d3e3e87fea3be838d11

Changed in nova:
status: In Progress → Fix Committed
Thierry Carrez (ttx)
Changed in nova:
status: Fix Committed → Fix Released
Revision history for this message
OpenStack Infra (hudson-openstack) wrote : Fix proposed to nova (stable/grizzly)

Fix proposed to branch: stable/grizzly
Review: https://review.openstack.org/50594

Thierry Carrez (ttx)
Changed in nova:
milestone: havana-3 → 2013.2
Alan Pevec (apevec)
tags: removed: grizzly-backport-potential
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.