Menu

#15 Vbox 4.3 autostart feature

unassigned
open
nobody
autostart (1)
5
2016-01-11
2014-02-17
No

Virtual Box 4.3 supports autostart. This page explains how to use it in linux: http://www.vionblog.com/virtualbox-4-3-autostart-debian-wheezy/

It thik it is a long waited feature in phpvirtualbox and now it is supported by virtualbox since it is a voboxmanage option (VBoxManage modifyvm VirtualMachine1 --autostart-enabled on)

Discussion

  • Alan Latteri

    Alan Latteri - 2014-02-24

    Yes this is a good step, but upon system shutdown, it just kills the VM. There is no clean shutdown as with VBoxTool.

     
  • Alejandro Vargas

    Well... it is a virtual box problem, not phpvirtualbox. I think it should not be difficult to pause or shutdown all active virtual machines when stopping a server.

    But I think the autostart function is more important than the shutdown one because in servers, shutdowns are very rare. The most common scenario is a power fail, in which case it will not be shutdown sequence. But upon power up it is important to auto start the virtual machines otherwise the administrator will need to do it manually.

     
  • Wilco Jansen

    Wilco Jansen - 2014-08-01

    You can set the way a VM needs to be terminated. You can for example set the following option to the following:

    VBoxManage modifyvm "MyVM" --autostart-enabled on
    VBoxManage modifyvm "MyVM" --autostop-type savestate

    This ensured the VM is autostarted, and when the machine (or the hypervisor) is shut down, the state of the VM is saved (more options available, but this is what you probably have been looking to).

    Regardless of that, I would welcome the addition to phpVirtualbox being able to set/unset all these options that now require a command line solution (and seem to be hidden deep away from the admin). Might be time that Oracle also updates the client program used to manage VM's ;-)

     
  • VVD

    VVD - 2016-01-11

    For FreeBSD I wrote start/stop script /usr/local/etc/rc.d/vboxinit.
    It starts VMs on a system startup with a user defined extra attribute pvbx/startupMode = auto (phpvirtualbox use it too) and savestate (by default) all running VMs on system shutdown.

    On my servers with 48Gb RAM savestate and start from savestate for all VMs can be more than 5 minutes. My sollution is:
    1. echo 'kern.init_shutdown_timeout=610' >> /etc/sysctl.conf
    2. echo 'rcshutdown_timeout="600"' >> /etc/rc.conf
    3. start it only after sshd was started to allow login on server during start process.

    Work in production for more than 2 years (with small changes).

     

Log in to post a comment.

Want the latest updates on software, tech news, and AI?
Get latest updates about software, tech news, and AI from SourceForge directly in your inbox once a month.