# Macbook wakes from sleep every 10 seconds



## FredT (Nov 16, 2007)

I've been having a lot of trouble with my mac lately, battled 3 problems today and only fixed one. :sigh:

Here is my latest (and by far most concerning) problem. Every 10 seconds my Macbook wakes up from sleep for about 1 second then goes back to sleep again. This was happening before, but since the sleep light wasn't even working at the time I though it might have been hardware related, so I brought it into the Genius Bar and they decided to have it sent in for a new logic board and sleep sensor. When I got it back everything worked great, no problems.

Just today, the same thing started happening, so I'm now thinking this may be a software issue. I immediately jumped on Console and tried to spot any red flags... spotted a TON of messages (that appeared to follow my every 10 seconds pattern) from com.apple.launchd[1] saying that

```
(org.postfix.master) Failed to count the number of files in "/var/spool/postfix/maildrop": No such file or directory
```
I fixed that problem by creating the var/spool/postfix/maildrop directory myself and restarted postfix. The error went away, but the wake from sleep problem didn't.

My next lead was this message:

```
com.apple.launchd[1] (com.apple.backupd-wake[2665]) Exited with exit code: 1
```
which caught my attention because it was a recurring message and it had to do with waking... figured it may have been causing the computer to wake up or something.

I found the com.apple.backupd-wake.plist and removed that to see what would happen on reboot. 1) It didn't recreate the file and 2) the problem didn't go away so I put the file back and rebooted again.

All of a sudden, (only after this point, never before) the error became so obvious. I could shut the lid, let it wake up twice, then wake it up on my own and sure enough 2 errors, 9 seconds apart showed up reading:

```
com.apple.loginwindow[35] launchctl start error: No such process
```
I played around with this for a little bit and I am certain there is a connection between this and the wakeup. Only problem, I checked back in the log and this launchctl error only started being logged at 10:26 PM, about the time when I played around with the com.apple.backupd-wake.plist file. Also, it switched from loginwindow[39] to loginwindow[35] at 10:36 PM... I wish I had taken more notice of exactly what I was doing when.

Then I chose to expand the Console to show all messages, not just errors.  More strange things! The sequence of events surrounding each of the launchctl errors looked like this:

```
2/25/09 10:42:29 PM kernel sleep 
2/25/09 10:42:38 PM com.apple.loginwindow[35] launchctl start error: No such process 
2/25/09 10:42:38 PM kernel Wake reason = USB7 
2/25/09 10:42:38 PM kernel System Wake 
2/25/09 10:42:38 PM kernel USB (EHCI):Port 7 on bus 0xfd connected or disconnected: portSC(0x101803)
```
Get this! Bus fd is the iSight camera! What in the world??? I looked at some more launchctl errors and found that sometimes multiple busses were listed including the bus connected to the keyboard/trackpad (which might make sense because I may have hit the spacebar to wake it up when I did it intentionally) and one of the USB ports on the side, which haven't even been touched tonight.

The iSight bus was always listed, and most of the time it was the only one listed. I ran a test where I put the computer to sleep manually, then made certain to wake it up using the spacebar and I got the iSight and the keyboard/trackpad as the two triggers.

I'm not sure if any of this post has made sense, if not, let me know. I may have over complicated things with too much detail, but I didn't want to leave anything out that may be useful.

If anyone has any idea of what is going on here, I would really appreciate some advice!

Thanks so much!!!


----------



## sinclair_tm (Mar 11, 2005)

So, it is doing this with nothing plugged into the USB ports? You also don't have any video chat apps open, or any shockwave sites loaded in your browser?


----------



## FredT (Nov 16, 2007)

Nope, absolutely nothing plugged in or open at all. I think I'm going to take this in to the Genius Bar along with my Dock problem and maybe we can compare my Console log with that of a heathy computer.

Thanks


----------

