小编Ram*_*aes的帖子

如何使用 VBoxManager 作为 Windows 服务运行无头 VM

客观的

我想像VBoxManage startvm MyVM --type headless服务(postgres、apache)一样在引导系统上运行这个命令。

我试过的

1. 我尝试使用sc命令创建服务

我在互联网上发现这可能是解决方案,所以我尝试了所有这些版本:

  • sc create "vboxMyVMService" binPath= "C:\Progman Files\Oracle\VirtualBox\VBoxManage.exe startvm MyVM --type headless"

  • sc create "vboxMyVMService" binPath= "C:\Progman Files\Oracle\VirtualBox\VBoxManage startvm MyVM --type headless"

没有成功,所以我试图抑制命令的详细输出

  • sc create "vboxMyVMService" binPath= "C:\Progman Files\Oracle\VirtualBox\VBoxManage.exe startvm MyVM --type headless > NUL"

  • sc create "vboxMyVMService" binPath= "C:\Progman Files\Oracle\VirtualBox\VBoxManage startvm MyVM --type headless"

还是没有结果。所有这个版本都给我返回了1053错误。所以最后调用是在Path中添加Virtualbox命令


  • sc create "vboxMyVMService" binPath= "VBoxManage.exe startvm MyVM --type headless"

  • sc create "vboxMyVMService" binPath= "VBoxManage startvm MyVM --type headless"

抑制输出 …

windows-7 virtualbox services

7
推荐指数
2
解决办法
2万
查看次数

标签 统计

services ×1

virtualbox ×1

windows-7 ×1