How to run application on virtual machine in python script. unknown file suffix

890 Views Asked by At

How to run application on virtual machine in python script

 db_tool = os.path.join(r'C:\Program Files\VMware\VMware VIX\vmrun.exe')
 db_name=r"-T esx -h https://10.10.10.10/sdk -u user -p password -gu user -gp password runProgramInGuest '[datastore1] datastore1/datastore1.vmx' -interactive notepad.exe"
 p = subprocess.Popen([db_tool, '-T' ,'server', '-h', 'https://10.10.10.10/sdk', '-u', 'user', '-p', 'password', '-gu', 'user', '-gp', 'password', 'runProgramInGuest', '"[datastore1]"', 'datastore1/datastore1.vmx','-interactive' ,'notepad.exe']
 p.communicate()

I receive following error: Unable to connect to host. Error: Cannot open VM: "[datastore1]", unknown file suffix

0

There are 0 best solutions below