How to safely shutdown Guest OS in VirtualBox using command line
- by Bakhtiyor
I have Ubuntu 10.10 and using VirtualBox 3.2. As a Guest OS I have another Ubuntu in the VirtualBox.
I am starting Guest Ubuntu automatically using following command once my Host Ubuntu boots:
VBoxHeadless -startvm Ubuntu --vrdp on
Then I can access to it with ssh or tsclient.
Now I need to shutdown automatically Guest Ubuntu once I shutdown my Host Ubuntu. Does anybody know any safe method to automatically shutdown Guest Ubuntu with a command line? I have found out two ways one can shutdown Guest OS but I am not sure whether they are safe or not. Here are they:
VBoxManage controlvm Ubuntu acpipowerbutton
or
VBoxManage controlvm Ubuntu poweroff