>>> import pyremotevbox.vbox as vbox
>>> host = vbox.VirtualBoxHost(host='10.0.2.2')
>>> bm1 = host.find_vm('baremetal1')
>>> bm1.get_power_status()
'PoweredOff'
>>> bm1.start()
>>> bm1.get_power_status()
'Running'
>>> bm1.stop()
>>> bm1.get_power_status()
'PoweredOff'
>>> bm1.get_boot_device()
'Network'
>>> bm1.set_boot_device(pyremotevbox.DEVICE_DISK)
>>> bm1.get_boot_device()
'HardDisk'
>>> bm1.set_boot_device(pyremotevbox.DEVICE_NETWORK)
>>> bm1.get_boot_device()
'Network'

pyremotevbox 官方最新的0.5.0版本還是用的以前0.1.0版本的文檔。so 我在这里更新一下

05-11 18:25