My MacBook Pro wouldn’t sleep, draining my battery each night. It wouldn’t ask for a password after a screen saver. Here’s why, how I fixed it, and what caused it to happen in the first place.
Ok, let’s start off by stating out right this was my own darn fault…
I’m using a MacBook Pro (Intel) running OS X 10.4.8, and my personal habit is to charge the system way up to full, then use the battery until it’s virtually drained, and repeat. Somehow I’m hoping that this will get me longer battery life, but that’s another story.
OS X is really smart in that while you’re working it pops up a dialog box telling you that you’ve got ten minutes of battery life left, and that you should go get your adapter and plug in the laptop. It’s so smart, in fact, that if you do that, it will close the dialog without you even have to click. Very clever.
But Apple is also treats you with a little respect. If you dismiss the dialog box, it’s not going to remind you any further. You know about the condition of the battery, as you just acknowledged it. To perpetually remind you would not just be insulting, but get in the way of what you were doing. I can’t count the number of times I’ve acknowledged the state, finished an email leisurely, and then gotten my adapter. I like that. I like not being nagged.
With that kind of interface comes responsibility, and I neglected mine. I allowed myself to get distracted by other things and it took me a moment to realize what had happened when the screen went dark and wouldn’t come back with a flick of the touch pad. I had accidentally allowed my battery to completely drain.
Turns out you don’t want to do this. It’s not going to damage your computer, but at the same time it isn’t going to leave things in a very valid state.
First, let’s give some credit to Apple — the moments after I plugged in my power adapter, the disk whirled up, and within a few seconds my screen came back to life, I lost no data, and my internet connections were still functioning. In the laptop’s last dying breath, it had preserved its state to disk, recovering when it had power.
The immediate concern is a disk repair; although the file system is journaled and your data won’t get corrupted, if it was in the middle of doing something where it hadn’t gotten that data to disk yet, that data is lost. This can result in minor file system problems which are easily corrected by booting your original OS X install disc and using the Disk Utility (rather than the install program) to repair the volume structurally, and then repair permissions.
But things doesn’t necessarily stop there. It is possible that your system, because of lack of power, lose some important system settings. The best analogy I can make for PC users is when your CMOS battery dies and your system “forgets” all the settings for the time and drives. While this doesn’t happen on the MacBook Pro, the following things did happen — and here’s how I corrected them.
1. The “Place two fingers on trackpad and click button for secondary click” stopped functioning. Solving this was merely a matter of going to the Keyboard & Mouse preference screen and toggling it off and back on.
2. The function keys, F9 – F12, stopped invoking Expose. Solving this was merely a matter of going to the Dashboard & Expose preference screen and setting the keyboard shortcuts back, they became unassigned.
3. The laptop stopped going into sleep mode when I closed the lid; apparently the power management subsystem had gotten confused. If something like Firefox was running GMail, this was enough to keep the system running (even though the back light went out). I’d awake in the morning to find my battery drained, leading to more problems of this nature. The laptop’s “sleep” led wasn’t “breathing” and pulsating as it does when hibernating. The solution was to reset the power management: Shutdown, Remove Battery, Hold Power Button for 5 Seconds, Insert Battery, and Boot.
4. When the laptop was woken up or coming out of a screen saver, it was not prompting for a password, as I had configured it to do. The solution was to Reboot, Hold Down Option-Command-P-R (that’s four keys at once!), wait for the chime, and release all four keys letting it boot as normal, then, sign on and go to the Security preference screen and toggle “Require password to wake this computer from sleep or screen saver”
I’m happy to report, the Mac is back working perfectly.
Oh, and a tip for people who want to put their Mac to sleep real quick, even with the above problems you can do this, press Option-Command-Eject. You’ll have to close your lid and re-open it to wake.