1

嗨,我想在 python 中使用 RunProgramInGuest 函数在 vm_ware 工作站中运行应用程序,但我不能,因为我不知道参考。我想要函数的简单代码,谢谢。

4

1 回答 1

1

您可能会发现 vix 很有用(可以在 @ https://github.com/naim94a/vix或 with中找到pip install vix)。这个库以安全的方式 (RAII) 封装了 VIX API,并且是面向对象的。

import vix

host = vix.VixHost()
host.connect()

vm = host.open_vm("C:\\Virtual Machines\\MyVM.vmx")
vm.login(username="GuestUserName", password="GuestPassword")

vm.proc_run("C:\\GuestExecutable.exe")

当然,如果您想自己打包调用,可以在此处找到官方文档:https ://www.vmware.com/support/developer/vix-api/vix115_reference/index2.html

于 2018-01-18T01:16:00.467 回答