博客
关于我
强烈建议你试试无所不能的chatGPT,快点击我
VirtualBox Linux服务vbox-service-template
阅读量:6787 次
发布时间:2019-06-26

本文共 1564 字,大约阅读时间需要 5 分钟。

vbox-service-template is an init.d script template for running a VirtualBox machine as a service.

Sending a stop command to the service will either save the state of the VM (hibernate) or send the ACPI Power Button signal to the VM and wait for it to self-terminate (powerbutton).

Some more context and howto information can be found here: http://www.glump.net/howto/

下载

Installation

Make a copy of the script as /etc/init.d/vbox-NAME and follow the instructions in the comments in the script. Make sure you set the x bit on the file to make it executable.

To mark the service for automatic start at boot time:

Ubuntu: update-rc.d vbox-NAME defaults 90 (The '90' is to make sure it starts after the VirtualBox core services.

Fedora: chkconfig vbox-NAME on
To remove the service from the boot process:

Ubuntu: update-rc.d -f vbox-NAME remove

Fedora: chkconfig vbox-NAME off
Additionally, if you are going to shut down your computer while a VM is running you should tell VirtualBox how to handle shutdown. Create or edit /etc/default/virtualbox:

SHUTDOWN_USERS="user1 user2" # space-delimited list of users who might have runnings vms

SHUTDOWN=savestate # if any are found, suspend them to disk
Usage
Start
service vbox-NAME start

Start and wait for the VM to be reachable on the network

service vbox-NAME start-wait

Stop (hibernate or power button -- see config lines in script)

service vbox-NAME stop

Restart

service vbox-NAME restart

Restart and wait for the VM to be reachable on the network

service vbox-NAME restart-wait

Display status

service vbox-NAME status

 

转载地址:http://mmigo.baihongyu.com/

你可能感兴趣的文章
<正则吃饺子> :关于redis配置文件参数详解
查看>>
2018-2019-2 20165334-Exp6:信息收集与漏洞扫描
查看>>
python发邮件模板参考
查看>>
【转载】rpc.rstatd安装与配置
查看>>
bootstrap课程10 从外部引入视频到页面用什么标签
查看>>
m_Orchestrate learning system---二十一、怎样写算法比较轻松
查看>>
LIUNX-Centos 7 编译GDAL
查看>>
日志、命名查询
查看>>
Google Chrome调试常用快捷键
查看>>
发送邮件那些事
查看>>
loadrunner参数化
查看>>
dom树改变监听
查看>>
【后缀数组】poj3581 Sequence
查看>>
【kd-tree】bzoj1176 [Balkan2007]Mokia
查看>>
CodeBlocks中使用中文字符问题
查看>>
SQL plus连接远程Oralce数据库
查看>>
C#泛型详解
查看>>
PDMS RvmTranslator
查看>>
第一天使用博客园 ----与肝胆人共事,于无字句处读书
查看>>
20172318 2018-2019-1 《程序设计与数据结构》第4周学习总结
查看>>