VirtualBox Python API - remote access -


i'm trying run virtual machine set on computer windows 7 (my main laptop) netbook (ubuntu system). on ubuntu i've prepared python script:

from vboxapi import virtualboxmanager import sys sys.path.append("/home/mylogin/downloads/sdk/bindings/webservice/python/lib")  mgr = virtualboxmanager("webservice", {'url':'myip', 'user':'myserverlogin', 'password':'mypassthere'}) vbox = mgr.vbox name = "muszelek" mach = vbox.findmachine(name) session = mgr.mgr.getsessionobject(vbox) progress = mach.launchvmprocess(session, "gui", "") progress.waitforcompletion(-1) mgr.closemachinesession(session) 

i'm getting error:

installation problem: check appropriate libs in place traceback (most recent call last):   file "/usr/local/lib/python2.7/dist-packages/vboxapi/__init__.py", line 981, in __init__     self.vbox = self.platform.getvirtualbox()   file "/usr/local/lib/python2.7/dist-packages/vboxapi/__init__.py", line 856, in getvirtualbox     return self.connect(self.url, self.user, self.password)   file "/usr/local/lib/python2.7/dist-packages/vboxapi/__init__.py", line 910, in connect     self.vbox = self.wsmgr.logon(self.user, self.password)   file "/home/karolinka/downloads/sdk/bindings/webservice/python/lib/virtualbox_wrappers.py", line 11790, in logon     req=iwebsessionmanager_logonrequestmsg() nameerror: global name 'iwebsessionmanager_logonrequestmsg' not defined traceback (most recent call last):   file "vmmach.py", line 5, in <module>     mgr = virtualboxmanager("webservice", {'url':'myip', 'user':'mycomputerlogin', 'password':'mypass'})   file "/usr/local/lib/python2.7/dist-packages/vboxapi/__init__.py", line 985, in __init__     raise ne nameerror: global name 'iwebsessionmanager_logonrequestmsg' not defined 

any idea how solve issue? problem libs on windows machine?

i had exact same problem on mac. issue virtualbox_wrappers.py imports virtualbox_client.py (which defines global name in question) in try block , continues (pass) if can not imported

try: virtualbox_client import * except: pass

the issue virtualbox_client.py depends on zsi, not installed, import failed. once did

easy_install zsi

everything worked expected.


Comments

Popular posts from this blog

javascript - jquery or ashx not working -

opencv - DataType<cv::detail::deriv_type>::depth what is it used for -

python 3.x - Mapping specific letters onto a list of words -