is there a command line ACPI shutdown

This is for discussing general topics about how to use VirtualBox.
Post Reply
hobbyhack
Posts: 9
Joined: 16. Apr 2009, 20:02
Primary OS: MS Windows Vista
VBox Version: PUEL
Guest OSses: Ubuntu, Windows XP

is there a command line ACPI shutdown

Post by hobbyhack »

Is there a way to initiate an ACPI shutdown of a guest from the command line? I can't find it as an option in VBoxManage.

I am trying to have all my virtual machines automatically shutdown at a certain time in order to backup the host.
Sasquatch
Volunteer
Posts: 17798
Joined: 17. Mar 2008, 13:41
Primary OS: Debian other
VBox Version: PUEL
Guest OSses: Windows XP, Windows 7, Linux
Location: /dev/random

Re: is there a command line ACPI shutdown

Post by Sasquatch »

Weird that you couldn't find it, because it's in plain view.

Code: Select all

VBoxManage controlvm        <uuid>|<name>
                            pause|resume|reset|poweroff|savestate|
                            acpipowerbutton|acpisleepbutton|
Read the Forum Posting Guide before opening a topic.
VirtualBox FAQ: Check this before asking questions.
Online User Manual: A must read if you want to know what we're talking about.
Howto: Install Linux Guest Additions
Howto: Use Shared Folders on Linux Guest
See the Tutorials and FAQ section at the top of the Forum for more guides.
Try searching the forums first with Google and add the site filter for this forum.
E.g. install guest additions site:forums.virtualbox.org

Retired from this Forum since OSSO introduction.
wyrdR
Posts: 36
Joined: 9. Aug 2009, 15:15
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Windows 7,Xubuntu,Mac OS X server

Re: is there a command line ACPI shutdown

Post by wyrdR »

Sasquatch wrote:Weird that you couldn't find it, because it's in plain view.

Code: Select all

VBoxManage controlvm        <uuid>|<name>
                            pause|resume|reset|poweroff|savestate|
                            acpipowerbutton|acpisleepbutton|
Does acpipowerbutton require guest additions?

My Mac OS X Server VM doesn't respond to this command nor does it do anything when I select "Send the Shutdown Signal". Either Mac OS X doesn't work like this or it needs the (currently still in development) Mac OS X Guest Additions.

TA :)
Sasquatch
Volunteer
Posts: 17798
Joined: 17. Mar 2008, 13:41
Primary OS: Debian other
VBox Version: PUEL
Guest OSses: Windows XP, Windows 7, Linux
Location: /dev/random

Re: is there a command line ACPI shutdown

Post by Sasquatch »

It doesn't require GA. However, since it's a server you're running, it's quite possible that it's designed to do nothing when it receives that call. Windows 2003 has the same thing, it will only shut down when you are logged on to the console and it's NOT locked. All other variations (locked, log on screen, etc) all ignores the acpi call. Other systems might react the same way.
Read the Forum Posting Guide before opening a topic.
VirtualBox FAQ: Check this before asking questions.
Online User Manual: A must read if you want to know what we're talking about.
Howto: Install Linux Guest Additions
Howto: Use Shared Folders on Linux Guest
See the Tutorials and FAQ section at the top of the Forum for more guides.
Try searching the forums first with Google and add the site filter for this forum.
E.g. install guest additions site:forums.virtualbox.org

Retired from this Forum since OSSO introduction.
wyrdR
Posts: 36
Joined: 9. Aug 2009, 15:15
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Windows 7,Xubuntu,Mac OS X server

Re: is there a command line ACPI shutdown

Post by wyrdR »

Sasquatch wrote:It doesn't require GA. However, since it's a server you're running, it's quite possible that it's designed to do nothing when it receives that call. Windows 2003 has the same thing, it will only shut down when you are logged on to the console and it's NOT locked. All other variations (locked, log on screen, etc) all ignores the acpi call. Other systems might react the same way.
TA.

So, this being guest dependent, it complicates a whole lotta things.

I guess it is possible that each OS may have configuration options that will allow it to honour acpipowerbutton in any state.

Perhaps VirtualBox could add to the Guest Additions a special process that listens for acpipowerbutton that could trigger neat shutdown inside the guest?
sh1ny
Posts: 2
Joined: 23. Jun 2010, 15:58
Primary OS: Ubuntu other
VBox Version: PUEL
Guest OSses: Ubuntu, Windows, Fedora

Re: is there a command line ACPI shutdown

Post by sh1ny »

Isn't there anything similar to acpid for mac os x ?
wyrdR
Posts: 36
Joined: 9. Aug 2009, 15:15
Primary OS: Mac OS X other
VBox Version: PUEL
Guest OSses: Windows 7,Xubuntu,Mac OS X server

Re: is there a command line ACPI shutdown

Post by wyrdR »

sh1ny wrote:Isn't there anything similar to acpid for mac os x ?
If it runs on *nix it will propbably port to Mac OS X using any number of ways.

I'm wondering if most modern OSes might not have this built in; We might just need to find the right config/preference/reghack/policy/whatever: Googling that thought now…

[Update]
After Googling…
*Nix
People seem to have this under control using acpid.

Windows
Windows Server (2003) and vboxheadless shutdown.

Mac OS X
Still hunting. Maybe porting acpid us the only way? Anyone know otherwise?
Post Reply