How to teach VirtualBox to prevent Mac to sleep?

Discussions related to using VirtualBox on Mac OS X hosts.

How to teach VirtualBox to prevent Mac to sleep?

Postby pguyot » 3. Mar 2013, 10:27

Hello,

I am running Windows Media Player within a Windows XP VM to watch DRM-protected videos. Host is a Mac running Mountain Lion. Windows does not go to sleep as WMP naturally prevents it. However, after a while, the Mac's screen goes dim and eventually the Mac would go to sleep.

Is there a way to:
- tell VirtualBox to pass the sleep prevention from the guest to the host?
- tell VirtualBox to prevent the host to sleep for this particular VM?
- tell VirtualBox to prevent the host to sleep when a VM is running?

So far, the only solution I found (beyond moving the mouse during the video) is to change the sleep settings on the Mac. But this is very inconvenient as I want them back whenever I do something else on this computer. After searching this forum and elsewhere on the web, I did this:

Code: Select all   Expand viewCollapse view
VBoxManage setextradata WindowsXP VBoxInternal/Devices/acpi/0/Config/PowerS1Enabled 1


But I believe this is unrelated or the other way around.
pguyot
 
Posts: 1
Joined: 3. Mar 2013, 10:18

Re: How to teach VirtualBox to prevent Mac to sleep?

Postby ptram » 3. Mar 2013, 13:06

I don't know if VB can prevent the Mac (starting from OS X 10.8) from sleeping, but you can create a Terminal script named [anyname].command, containing the "caffeinate" command. You can launch it when you want the Mac to stay always on.

Paolo
ptram
 
Posts: 32
Joined: 10. Dec 2008, 18:58


Return to VirtualBox on Mac OS X Hosts

Who is online

Users browsing this forum: Google [Bot] and 10 guests