Page 1 of 1

HOWTO: Setup a VirtualBox VMs Service Script

Posted: 12. May 2009, 09:52
by quadir
Starting and Stopping a VirtualBox Virtual Machine (VM) is easy. But what if your host machine shutdowns abruptly, or you forget to shutdown the VMs or save their state? It would also be nice to have a service which would automatically shutdown/startup VMs when the host machine shutdowns or starts. I googled around for a VirtualBox service script and found one at http://www.glump.net/howto/virtualbox_as_a_service. Thanks to Brendan Kidwell for sharing this script. The script provided by Brendan works only for one VM. One needs to install this script multiple times for each VM. I enhanced this script so that it works for multiple VMs. You can download it from http://docs.google.com/Doc?id=dgptztxf_28fwksg4cw and follow the instructions at http://quadirspace.blogspot.com/2009/05 ... linux.html

Please let me know if you have any questions, found this script useful, know a better solution or have feature requests.

Re: HOWTO: Setup a VirtualBox VMs Service Script

Posted: 13. May 2009, 19:56
by TerryE
Thanks for this quadir. However, I think that I should add as a codicil that there are many other topics covering this general issue, as well as OS specific guidelines on how to install daemon services in /etc/init.d and on debian systems the use of update-rc.d. If you google search the forum for this as a search phrase then you will find a few.