Timeline for How to automatically start and shut down VirtualBox machines?
Current License: CC BY-SA 3.0
5 events
| when toggle format | what | by | license | comment | |
|---|---|---|---|---|---|
| Jan 8, 2012 at 20:05 | comment | added | Nikhil Mulley | Regarding: how script knows when the guest is down, try a simple check if the vm is on or off from VboxManager interface and if the guest is ssh'able. Also, put some monitoring on the host system which will perform whether the VM is available from Vboxmanager and its ssh'able on a timely basis. | |
| Jan 8, 2012 at 20:02 | comment | added | Nikhil Mulley | Your comment assumes that everything will work smoothly on host system and not on guest system. What if power cable is plugged out on host system? Its a different discussion. Your SysV-init on host system will wait for the service script to stop the VMs as long as service script understands the logic to get the guest VMs off in a right way (exec shutdown on remote host or just power off through vbox interface) and then yield return the success or failure status back to console or init. | |
| Jan 8, 2012 at 19:35 | comment | added | jstarek | Basically, this would work, the appliance can be reached in the entire LAN via its DNS entry. However, suppose I wrote a script that ssh'd into the appliance whenever the host goes down -- it would still have to block (pause) until the guest has shut down completely. This is precisely the point of my question: How can the script know when the guest is down, so that it can yield control flow back to SysV-Init and the host can continue to shut down? | |
| Jan 8, 2012 at 17:30 | comment | added | Nikhil Mulley | Good thought, but this would warrant that guest VM be reachable via network from the host, atleast the ssh port(22). | |
| Jan 8, 2012 at 17:16 | history | answered | Baarn | CC BY-SA 3.0 |