Ask Your Question
0

VMwareESXDriver: Failed to spawn instance [closed]

asked 2014-01-03 04:34:24 -0500

Mathias Ewald gravatar image

updated 2014-01-03 04:35:05 -0500

Hi, I have trouble getting OpenStack to work with VMware ESXi 5.1 hosts without a vCenter instance.

nova-compute node: /etc/nova/nova.conf

root@compute1:~# cat /etc/nova/nova.conf 
[DEFAULT]

# GENERAL
state_path=/var/lib/nova
lock_path=/var/lock/nova
root_helper=sudo nova-rootwrap /etc/nova/rootwrap.conf
verbose=True
debug=True
my_ip=192.168.0.11

# API
ec2_private_dns_show_ip=True
api_paste_config=/etc/nova/api-paste.ini
enabled_apis=ec2,osapi_compute,metadata

# LOGGING
logdir=/var/log/nova

# NETWORKING
dhcpbridge_flagfile=/etc/nova/nova.conf
dhcpbridge=/usr/bin/nova-dhcpbridge
#libvirt_use_virtio_for_bridges=True
network_manager=nova.network.manager.FlatDHCPManager
#firewall_driver=nova.virt.libvirt.firewall.IptablesFirewallDriver
#network_size=254
#allow_same_net_traffic=False
#send_arp_for_ha=True
#share_dhcp_address=True
#force_dhcp_release=True
flat_network_bridge=br100

# QUEUE
rabbit_host = controller
rabbit_port = 5672
rabbit_use_ssl = false
rabbit_userid = guest
rabbit_password = guest
rabbit_virtual_host = /

#AUTH
auth_strategy=keystone

# STORAGE
iscsi_helper=tgtadm
volumes_path=/var/lib/nova/volumes

# HYPERVISOR
connection_type=libvirt
compute_driver=vmwareapi.VMwareESXDriver
multi_host=True

# VNC
vnc_enabled=True
vncserver_listen=0.0.0.0
vncserver_proxyclient_address=192.168.0.11
novncproxy_base_url=http://controller:6080/vnc_auto.html

# GLANCE
glance_host=controller

# METADATA
metadata_host=192.168.0.10

# DATABASE
[database]
connection = mysql://nova:nova@controller/nova

# VMWARE
[vmware]
host_ip=192.168.0.50
host_username=root
host_password=*********
#wsdl_location=https://192.168.0.50/sdk/vimService.wsdl

root@compute1:~#

I cleared /etc/nova/nova-compute.conf so nothing of the above gets overwritten. On the controller node, I can see that the connection to my ESXi node seems to work:

root@controller:~# nova hypervisor-list
+----+---------------------+
| ID | Hypervisor hostname |
+----+---------------------+
| 4  | 192.168.0.50        |
+----+---------------------+
root@controller:~# nova hypervisor-show 4
+----------------------+---------------------------------------------------------------------------------------------------------------------------------------+
| Property             | Value                                                                                                                                 |
+----------------------+---------------------------------------------------------------------------------------------------------------------------------------+
| hypervisor_hostname  | 192.168.0.50                                                                                                                          |
| cpu_info             | {"model": "Intel(R) Xeon(R) CPU E5-2603 0 @ 1.80GHz", "vendor": "VMware, Inc.", "topology": {"cores": 2, "threads": 2, "sockets": 2}} |
| free_disk_gb         | 71                                                                                                                                    |
| hypervisor_version   | 51                                                                                                                                    |
| disk_available_least | None                                                                                                                                  |
| local_gb             | 75                                                                                                                                    |
| free_ram_mb          | 3583                                                                                                                                  |
| id                   | 4                                                                                                                                     |
| vcpus_used           | 4                                                                                                                                     |
| hypervisor_type      | VMware ESXi                                                                                                                           |
| local_gb_used        | 4                                                                                                                                     |
| memory_mb_used       | 2560                                                                                                                                  |
| memory_mb            | 6143                                                                                                                                  |
| current_workload     | 0                                                                                                                                     |
| vcpus                | 2                                                                                                                                     |
| running_vms          | 4                                                                                                                                     |
| service_id           | 6                                                                                                                                     |
| service_host         | compute1                                                                                                                              |
+----------------------+---------------------------------------------------------------------------------------------------------------------------------------+
root@controller:~#

I uploaded an Image of Cirros in VMDK format and used qemu-img to convert it.

root@controller:~# nova image-list
+--------------------------------------+---------------------+--------+--------+
| ID                                   | Name                | Status | Server |
+--------------------------------------+---------------------+--------+--------+
| 4cc6b146-0a18-43f8-83f4-f90381f6e521 | Cirros 0.3.1 x86_64 | ACTIVE |        |
+--------------------------------------+---------------------+--------+--------+
root@controller:~# nova image-show 4cc6b146-0a18-43f8-83f4-f90381f6e521
+----------------------+--------------------------------------+
| Property             | Value                                |
+----------------------+--------------------------------------+
| status               | ACTIVE                               |
| updated              | 2013-12-28T11:35:20Z                 |
| name                 | Cirros 0.3.1 x86_64                  |
| created              | 2013-12-28T11:35:20Z                 |
| minDisk              | 0                                    |
| progress             | 100                                  |
| minRam               | 0                                    |
| OS-EXT-IMG-SIZE:size | 13565952                             |
| id                   | 4cc6b146-0a18-43f8-83f4-f90381f6e521 |
+----------------------+--------------------------------------+
root@controller:~#
root@controller:/var/lib/glance/images# file 4cc6b146-0a18-43f8-83f4-f90381f6e521 
4cc6b146-0a18-43f8-83f4-f90381f6e521: VMware4 disk image
root@controller:/var/lib/glance/images#

Now I try and boot an instance:

root@controller:~# nova boot --flavor 1 --key-name mykey --image 4cc6b146-0a18-43f8-83f4-f90381f6e521 --security_groups default cirros08
...

On the Controller node not much happens. I can see a status of "BUILD" and task state of "spawning" for a while before it changes to "ERROR" and "none.

+--------------------------------------+-----------+--------+------------+-------------+----------+
| ID                                   | Name      | Status | Task State | Power State | Networks |
+--------------------------------------+-----------+--------+------------+-------------+----------+
...
| a3a13387-b6a2-4db8-baa3-500be470a95f | cirros08  | ERROR  | None       | NOSTATE     |          |
+--------------------------------------+-----------+--------+------------+-------------+----------+

I already set nova-compute to debug and verbose mode to get as much logging information as possible, but I cannot see anything from this. I pastebined that for you as I thought it's probably not a good idea to paste 832 lines here :D

http://pastebin ... (more)

edit retag flag offensive reopen merge delete

Closed for the following reason the question is answered, right answer was accepted by dheeru
close date 2014-01-03 09:13:14.441838

1 answer

Sort by ยป oldest newest most voted
0

answered 2014-01-03 05:46:53 -0500

dheeru gravatar image

updated 2014-01-03 08:33:08 -0500

It is failing at network setup. Can you check your network configuration ? You can paste your configuration in pastebin as well.

Please verify your configuration with one suggested here.

When creating the instance it is trying to get the network info i.e calling method allocate_for_instance. There is no further info beyond this. This occurs due to two reasons. 
1. Your nova-network service is down or 
2. Some network configuration in nova.conf is causing this issue. 
Also I saw the following descrepancy in nova.conf configuration file
connection_type=libvirt 
compute_driver=vmwareapi.VMwareESXDriver 
Why it is libvirt here ?. 
What is the entry you made nova-compute.conf for compute_driver ? Can you check that ? 
Nova.conf has my_ip=192.168.0.11 
Where as hypervisor says that compute is following. 4 | 192.168.0.50 Hope compute IP addresses are right. 
Check the following question as well https://ask.openstack.org/en/question/6494/vmwareesxdriver-novaconf-in-havana/
edit flag offensive delete link more

Comments

Hi, thanks for the quick reply! Can you be more specific about what to check? I pastebined nova network-list and network-show and ESXi network configuration: http://pastebin.com/CpX0Pyc6 and http://pastebin.com/gtVBruKk%3C/p%3E (http://pastebin.com/gtVBruKk)

Mathias Ewald gravatar imageMathias Ewald ( 2014-01-03 05:54:08 -0500 )edit
1

When creating the instance it is trying to get the network info i.e calling method allocate_for_instance. There is no further info beyond this. This occurs due to two reasons. 1. Your nova-network service is down or 2. Some network configuration in nova.conf is causing this issue. Also I saw the following descrepancy connection_type=libvirt compute_driver=vmwareapi.VMwareESXDriver Why it is libvirt here ?. What is the entry you made nova-compute.conf for compute_driver ? Can you check that ? Nova.conf has my_ip=192.168.0.11 Where as hypervisor says that compute is following. 4 | 192.168.0.50 Hope compute IP addresses are right. Check the following question as well https://ask.openstack.org/en/question/6494/vmwareesxdriver-novaconf-in-havana/

dheeru gravatar imagedheeru ( 2014-01-03 05:58:46 -0500 )edit

I can confirm nova-network is running: http://pastebin.com/rYsFUQTX and also commented out connection_type=libvirt as I agree it doesnt make any sense. nova-compute.conf is entirely empty so it does not overwrite any configuration made in nova.conf. I restarted all the services after that change and now it seems to be working fine! First instance deployed -- buujaaa!

Mathias Ewald gravatar imageMathias Ewald ( 2014-01-03 08:17:41 -0500 )edit

cool. Shall we close the request now ? Also can you accept the my ans by clicking on the right tick mark. Please click only once. Once you do that I will close the request.

dheeru gravatar imagedheeru ( 2014-01-03 08:34:18 -0500 )edit

done :) :)

Mathias Ewald gravatar imageMathias Ewald ( 2014-01-03 08:36:25 -0500 )edit

Get to know Ask OpenStack

Resources for moderators

Question Tools

1 follower

Stats

Asked: 2014-01-03 04:34:24 -0500

Seen: 708 times

Last updated: Jan 03 '14