VBoxManage [-q|--nologo] startvm <uuid>|<name> [--type gui|sdl|headless] The following values are allowed: gui - Starts a VM showing a GUI window. This is the default. headless - Starts a VM without a window for remote display only.
启动虚拟机的脚本(虚拟机的名称为XP): @echo off :: by oicu cd /d "D:\Program Files\Oracle\VirtualBox" VBoxHeadless --startvm "XP" :: VBoxManage startvm "XP" --type headless
关闭虚拟机的脚本: @echo off :: by oicu cd /d "D:\Program Files\Oracle\VirtualBox" VBoxManage controlvm "XP" acpipowerbutton :: send {Enter} to VM, for Windows Guest OS only. VBoxManage controlvm "XP" keyboardputscancode 1c
评论