Ask Your Question
0

how do I modify esx vms using openstack api's?

asked 2014-09-16 12:52:40 -0500

anonymous user

Anonymous

updated 2014-09-17 23:05:10 -0500

Have been looking a openstack for a few days and have been trying to find a way to control vcenter from openstack api's? Is this possible? The closest doc I can find is http://docs.openstack.org/trunk/config-reference/content/vmware.html#vmware-intro (http://docs.openstack.org/trunk/.../vmware.html#vmware-intro) which shows how to set up the driver then goes on to show how to convert images back and forth between openstack and vsphere. Nothing on how to make modifications to vsphere from the api. I've already looked at pyvmoni and pysphere . pysphere looks ok but not complete, the vmware pyvmoni api reminds me of why I have a burning dislike of java. I'd rather avoid powershell. I was really hoping openstack would / could be the answer so I pack stacked my way to an install of glance nova and keystone. the api's look sane , I just cant seem to track down the part showing how to tie it all together.

esx5.1

Just came across oslo , not sure it looks like it might do it? poking around novaclient and nova.virt.vmwareapi. Any examples would help a ton. My python-fu is serviceable for someone learning python on a need to know basis. Starting from reference doc is dicey (for me) and the tests are a bit to generic to figure out what i need. The following:

from nova.virt import virtapi
from nova.virt.vmwareapi.driver import VMwareAPISession as session_api
from nova.virt.vmwareapi.vmops import VMwareVMOps as vmo
from nova.virt.vmwareapi import volumeops
vapi = virtapi.VirtAPI
session = session_api(ip, user, pw )
volopt = volumeops.VMwareVolumeOps(session,cluster)
vmo(session, vapi, volopt)
x = vmo.list_instances()

Gets :

Traceback (most recent call last):
  File "./x", line 71, in <module>
    vmo(session, vapi, volopt)
  File "/usr/lib/python2.6/site-packages/nova/virt/vmwareapi/vmops.py", line 93, in __init__
    self.compute_api = compute.API()
  File "/usr/lib/python2.6/site-packages/nova/compute/__init__.py", line 39, in API
    return importutils.import_object(class_name, *args, **kwargs)
  File "/usr/lib/python2.6/site-packages/nova/openstack/common/importutils.py", line 38, in import_object
    return import_class(import_str)(*args, **kwargs)
  File "/usr/lib/python2.6/site-packages/nova/compute/api.py", line 248, in __init__
    self.network_api = network_api or network.API()
  File "/usr/lib/python2.6/site-packages/nova/network/__init__.py", line 39, in API
    return cls()
  File "/usr/lib/python2.6/site-packages/nova/network/api.py", line 118, in __init__
    self.network_rpcapi = network_rpcapi.NetworkAPI()
  File "/usr/lib/python2.6/site-packages/nova/network/rpcapi.py", line 92, in __init__
    self.client = rpc.get_client(target, version_cap, serializer)
  File "/usr/lib/python2.6/site-packages/nova/rpc.py", line 125, in get_client
    assert TRANSPORT is not None

nova.conf:

[DEFAULT]
allowed_rpc_exception_modules=oslo.messaging.exceptions,cinder.exception,exceptions
vncserver_listen = vncvalid-ip
vncserver_proxyclient_address = vncvalid-ip
my_ip = valid-ip
auth_strategy = keystone
#rpc_backend = qpid
#rpc_backend=nova.openstack.common.rpc.impl_qpid
qpid_protocol = tcp
qpid_hostname=controllerRunningQpid-hostname
compute_driver=vmwareapi.VMwareVCDriver
integration_bridge = br-int
#compute_driver=vmwareapi.VMwareESXDriver
network_driver=nova.network.linux_net
libvirt_vif_driver=nova.virt.libvirt.vif.LibvirtGenericVIFDriver
linuxnet_interface_driver=nova.network ...
(more)
edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted
1

answered 2014-09-17 23:16:42 -0500

SGPJ gravatar image
edit flag offensive delete link more

Comments

Reviewed those earlier. Checked my config against the referenced posts and still no luck.

admin-dev gravatar imageadmin-dev ( 2014-09-18 19:23:47 -0500 )edit

Same error with other driver.

admin-dev gravatar imageadmin-dev ( 2014-09-18 20:19:53 -0500 )edit

still fighting this. Today I came across VOVA. Installed it and exact same thing.

admin-dev gravatar imageadmin-dev ( 2014-09-19 15:44:25 -0500 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Get to know Ask OpenStack

Resources for moderators

Question Tools

1 follower

Stats

Asked: 2014-09-16 12:52:40 -0500

Seen: 207 times

Last updated: Sep 17 '14