It's me :)Thireus' Website
linkedin | CV | PGP key | about | search | register | --:--:--
Take the blue pill!
User:  Pass: 
Do you have problems when your computer wakes from sleep? PDF Print E-mail
User Rating: / 18
Written by Thireus   
Thursday, 18 June 2009 16:23

Here you'll learn how to ask your computer to do tasks before going to sleep and after waking from sleep.

This article is about how to fix these main issues:

- VoodooHDA volume set to max after sleep

- VoodooHDA not working after sleep

- USB drives not correctly unmounted before sleep

For any suggestions: This e-mail address is being protected from spambots. You need JavaScript enabled to view it

First of all you need to download this application: SleepWatcher


Open the sleepwatcher package and install the application.

If it's asked to reboot, then do it.

Now, go to /etc/ and get these two files: rc.sleep and rc.wakeup

Copy and paste them on your desktop or wherever you like (make sure to copy them too into a backup folder too)

Once you pasted them, you'll have to edit them, open these two files with TextEdit

(Once edited you can replace the old ones located into /etc/)

Ok so here we are.

You can see what are the tasks your computer do before going to sleep --> rc.sleep

You can see what are the tasks your computer do after waking from sleep --> rc.wakeup

Let's begin with some basic hacks:

If this hack is not correctly working, just try to reboot your computer.

FIX: VoodooHDA volume set to max after wakeup.

FILE(S) TO BE MODIFIED: .wakeup (you need to create this one, this is NOT the rc.wakeup file!!!)

This file should be located into your Home directory (/Users/YOURUSERNAME), don't foreget it is a hidden file!

Type into the terminal: open -a TextEdit .wakeup

If nothing happens this file doesn't exist, but if it does, jump to the modification instructions.

If .wakeup doesn't exist, download my wakeup file and put this file into your /Users/YOURUSERNAME directory (called Home directory):

Download & extract: ~ 4ko

Then rename it as .wakeup to hide it!

Type into the terminal (type the admin password when asked):

sudo chmod 755 .wakeup

That's it! You don't need to read the modification instructions Wink

MODIFICATIONS: (Only if you didn't downloaded and installed my file

Add at the end of the .wakeup file these lines: VoodooHDA_Volume_Fix.txt

NOTE: The .wakeup file should be located into your Home directory (/Users/YOURUSERNAME), don't foreget it is a hidden file!

FIX: VoodooHDA global sleep issues (this should fix all the issues you have with VoodooHDA after waking from sleep). THIS FIX DOES NOT WORK WITH MY 10.5.8 INSTALL, FEEL FREE TO TRY!!

FILE(S) TO BE MODIFIED: rc.sleep; rc.wakeup


Add at the end of the rc.sleep file these lines: VoodooHDA_sleep.txt

Add at the end of the rc.wakeup file these lines: VoodooHDA_wakeup.txt

NOTE: If the kext doesn't load after waking from sleep, just try to add VoodooHDA_sleep.txt before the VoodooHDA_wakeup.txt lines of your rc.wakeup file. So it will try to unload your kext after wakeup too! Hope this help Wink

FIX: USB or SD Card reader that doesn't correctly unmount before going to sleep



Add at the end of the rc.sleep file these lines: USB_sleep.txt

Don't forget to edit #Vars to give a name for the USB you want to unmount!!!

FIX: Launches WirelessUtilityCardbusPCI to get connected to your wireless network after waking from sleep (For eeepc)



Add at the end of the rc.sleep file these lines: WirelessUtilityCardbusPCI_wakeup.txt

Only registered users can write comments!

2009-08-16 19:08:41

Does this fix VoodooHDA ignoring Mute on wake? I don't have it setting the volume to max but if I mute my volume before I put my 1000HE to sleep and then wake it back up my volume is unmuted (however, the menu bar shows it as muted).

2009-08-16 19:09:58

Yes it does Wink

2009-08-16 20:23:13

Fantastic! Well, I gave it a go and the first fix "Volume setting to max" just made it set my volume to max (when it wasn't doing it before). So, I kept .wakeup and modified my rc.sleep and rc.wakeup with your provided scripts (2nd fix). That fixed the mute issue, however everytime I wake the machine the sound menu bar icon goes away and I have to go into System Preferences and check the box to display it again. Is this just a side effect of the scripts, or is it doing something it shouldn't? Thanks again!

2009-08-16 20:33:56

Hum... strange, the first script just does a quick adjustment of the volume after the computer wakes up. It gets the volume settings and apply it back to the volume, so it does nothing special but enough to fix the "Max Volume" issue or the "Unmute" issue you might have after sleep.

The second script unload VoodooHDA and then load it back after sleep. Maybe try to put both scripts into your rc.wakeup file and delete the script for your rc.sleep file. One script after the other as explained into the article as a quick "NOTE" for this fix, then tell me if it works.

2009-08-16 20:51:02

Putting both of them in rc.wake up has the same results, except there is a delay before my menu bar icon disappears. I've also noticed that now it unmutes the volume when it reloads the KEXT.

2009-08-17 01:04:03

Hum... not very nice :/
Sorry I can't help more Sad

2009-07-05 07:21:30

Hi I am using a lenovo s10 with built in bluetooth that prevents the laptop from going to sleep and i stumbled upon your instructions

1) I was trying to see if i can disable bluetooth via osx last night and i was attempting to use SuperHai's USBEHCI.kext from and i was meant to edit an info.plist file of


I did not do it properly and i think i ended up with a problem where AppleUSBEHCI.kext not working and i did not have access to all USB devices that are plugged into the laptop. In other words, OSX did not detect my USB Mouse.

At this point of time, i was able to enter sleep mode. (after following your instructions)

2) But after i used OSx86 tools to repair the permissions, AppleUSBEHCI.kext was working again and i was unable to make the laptop go to sleep. In other words, it will go to sleep and wake up again almost immediately.

3) Therefore, i have been looking for a way to kextunload AppleUSBEHCI.kext when in OSX but when i used the command,
sudo kextunload /System/Library/Extensions/IOUSBFamily.kext/Contents/PlugIns/AppleUSBEHCI.kext

i got the message,
kextunload: unload kext /System/Library/Extensions/IOUSBFamily.kext/Contents/PlugIns/AppleUSBEHCI.kext failed

I guess its some dependencies or because its a "core" operating system file that disallowed me from doing so.

4) Do you have an idea how to do this and kextload the AppleUSBEHCI.kext upon waking the laptop?
It would be cool if someone can come up with a script and maybe integrate it into the rc.sleep ad rc.wakeup as modified according to instructions provided on your site, together with sleepwatcher.

2009-07-07 21:28:07

Sorry I don't have any idea :-/

I will inform you as soon as I can if I find a solution Wink

2010-09-07 11:26:39

Hi thireus, great work, i have a question:

with this is possible to have the gma overclock also on wake and not only hence to start?

And if yes, how?

I use sleepwatcher for voodoohda and it works flawlessy, i have try with gma script but it doesn't work, maybe i wrong something

thank you

2010-10-22 01:36:06


Once your GMA has been overclocked, it should work until you shutdown your computer. So there's no need to use the script with sleepwatcher.


Last Updated on Friday, 14 August 2009 11:53