# Computer shuts down after a minute of inactivity



## jcbar (Jan 10, 2010)

After just over one minute of inactivity (no moving mouse, typing, etc.), I get a "Logout, Cancel, Restart, Shutdown" screen.  If I don't quickly click out of it, the computer totally shuts down.  I have an Intel Macbook.  I don't believe it's a hardware problem; I've run the hardware test and it comes up clear.  Any advice or help would be greatly appreciated!

Thanks


----------



## ElDiabloConCaca (Jan 10, 2010)

Open "System Preferences" then open the "Security" pane.

Under "General," do you have "Log out after XXX minutes of inactivity" enabled?


----------



## jcbar (Jan 10, 2010)

No... it's not checked.


----------



## ElDiabloConCaca (Jan 10, 2010)

Are there any other users and/or user accounts on your computer where this option may be set?


----------



## djackmac (Jan 10, 2010)

Go to system preferences/energy saver and click the schedule button to see the computer is set to shut down at certain times.


----------



## Giaguara (Jan 11, 2010)

The next time it happens (or hte last time it happened if you can trace it in the logs), go to Console (/Applications/Utilities) and in its logs (all or system log) back in time when it shut down. You can find that e.g. searching for _shutdown_ and it should list some cause. 
What does it list? Post the line with the shutdown cause and something before it - some lines before it there will be somehting about kernel loading etc. Before then, there should be the last lines of the system before it actually shut down. (better too much text than little if in doubt).


----------



## jcbar (Jan 12, 2010)

Here's the shutdown cause:

Jan 12 00:58:48 localhost kernel[0]: Previous Shutdown Cause: 5

Here's the last bit of the log in case it is of some use.  Like I said, the computer will shut down, without fail, at slightly over a minute of inactivity.  If in continuous use, everything runs normally.  

Jan 12 00:52:23 localhost kernel[0]: hi mem tramps at 0xffe00000
Jan 12 00:52:23 localhost kernel[0]: PAE enabled
Jan 12 00:52:23 localhost kernel[0]: 64 bit mode enabled
Jan 12 00:52:23 localhost kernel[0]: standard timeslicing quantum is 10000 us
Jan 12 00:52:23 localhost kernel[0]: vm_page_bootstrap: 250304 free pages
Jan 12 00:52:23 localhost kernel[0]: mig_table_max_displ = 71
Jan 12 00:52:23 localhost kernel[0]: Enabling XMM register save/restore and SSE/SSE2 opcodes
Jan 12 00:52:23 localhost kernel[0]: 93 prelinked modules
Jan 12 00:52:23 localhost kernel[0]: ACPI CA 20060421
Jan 12 00:52:23 localhost kernel[0]: AppleIntelCPUPowerManagement: ready
Jan 12 00:52:23 localhost kernel[0]: AppleACPICPU: ProcessorApicId=0 LocalApicId=0 Enabled
Jan 12 00:52:23 localhost kernel[0]: AppleACPICPU: ProcessorApicId=1 LocalApicId=1 Enabled
Jan 12 00:52:23 localhost kernel[0]: Copyright (c) 1982, 1986, 1989, 1991, 1993
Jan 12 00:52:23 localhost kernel[0]: The Regents of the University of California. All rights reserved.
Jan 12 00:52:23 localhost kernel[0]: using 5242 buffer headers and 4096 cluster IO buffer headers
Jan 12 00:52:23 localhost kernel[0]: Enabling XMM register save/restore and SSE/SSE2 opcodes
Jan 12 00:52:23 localhost kernel[0]: Started CPU 01
Jan 12 00:52:23 localhost kernel[0]: IOAPIC: Version 0x20 Vectors 64:87
Jan 12 00:52:23 localhost kernel[0]: ACPI: System State [S0 S3 S4 S5] (S3)
Jan 12 00:52:23 localhost kernel[0]: Security auditing service present
Jan 12 00:52:23 localhost kernel[0]: BSM auditing present
Jan 12 00:52:23 localhost kernel[0]: disabled
Jan 12 00:52:23 localhost kernel[0]: rooting via boot-uuid from /chosen: 2D2A2B8C-BE44-476A-BD90-80AF73E53AF0
Jan 12 00:52:23 localhost kernel[0]: Waiting on <dict ID="0"><key>IOProviderClass</key><string ID="1">IOResources</string><key>IOResourceMatch</key><string ID="2">boot-uuid-media</string></dict>
Jan 12 00:52:23 localhost kernel[0]: USB caused wake event (EHCI)
Jan 12 00:52:23 localhost kernel[0]: FireWire (OHCI) Lucent ID 5811 PCI now active, GUID 001b63fffe73a6ac; max speed s400.
Jan 12 00:52:23 localhost kernel[0]: Got boot device = IOService:/AppleACPIPlatformExpert/PCI0@0/AppleACPIPCI/SATA@1F,2/AppleAHCI/PRT2@2/IOAHCIDevice@0/AppleAHCIDiskDriver/IOAHCIBlockStorageDevice/IOBlockStorageDriver/FUJITSU MHW2080BHPL Media/IOGUIDPartitionScheme/Apple_HFS_Untitled_1@2
Jan 12 00:52:23 localhost kernel[0]: BSD root: disk0s2, major 14, minor 2
Jan 12 00:52:23 localhost kernel[0]: jnl: replay_journal: from: 6234112 to: 4074496 (joffset 0x254000)
Jan 12 00:52:23 localhost kernel[0]: CSRHIDTransitionDriver:robe: 
Jan 12 00:52:23 localhost kernel[0]: CSRHIDTransitionDriver::start before command
Jan 12 00:52:23 localhost kernel[0]: CSRHIDTransitionDriver::stop
Jan 12 00:52:23 localhost kernel[0]: IOBluetoothHCIController::start Idle Timer Stopped
Jan 12 00:52:23 localhost kernel[0]: Jettisoning kernel linker.
Jan 12 00:52:23 localhost kernel[0]: Resetting IOCatalogue.
Jan 12 00:52:23 localhost kernel[0]: GFX0: family specific matching fails
Jan 12 00:52:23 localhost kernel[0]: display: family specific matching fails
Jan 12 00:52:23 localhost kernel[0]: Matching service count = 2
Jan 12 00:52:23 localhost kernel[0]: Matching service count = 4
Jan 12 00:52:23 localhost kernel[0]: Matching service count = 4
Jan 12 00:52:23 localhost kernel[0]: Matching service count = 4
Jan 12 00:52:23 localhost kernel[0]: Matching service count = 4
Jan 12 00:52:23 localhost kernel[0]: Matching service count = 4
Jan 12 00:52:23 localhost kernel[0]: Previous Shutdown Cause: 5
Jan 12 00:52:23 localhost kernel[0]: GFX0: family specific matching fails
Jan 12 00:52:23 localhost kernel[0]: display: family specific matching fails
Jan 12 00:52:23 localhost kernel[0]: ath_attach: devid 0x24
Jan 12 00:52:23 localhost kernel[0]: Override HT40 CTL Powers. EEPROM Version is 14.4, Device Type 5
Jan 12 00:52:23 localhost kernel[0]: ath_descdma_setup: tx dd_desc_paddr = 0xe833000, length 0x46500(288000) bytes
Jan 12 00:52:23 localhost kernel[0]: ath_descdma_setup: beacon dd_desc_paddr = 0xa390000, length 0x90(144) bytes
Jan 12 00:52:23 localhost kernel[0]: mac 12.10 phy 8.1 radio 12.0
Jan 12 00:52:23 localhost kernel[0]: IPv6 packet filtering initialized, default to accept, logging disabled
Jan 12 00:52:23 localhost memberd[37]: memberd starting up
Jan 12 00:52:23 localhost mDNSResponder-108.6 (Jul 19 2007 11: 41:28)[30]: starting
Jan 12 00:52:23 localhost lookupd[42]: lookupd (version 369.6) starting - Tue Jan 12 00:52:23 2010
Jan 12 00:52:24 localhost diskarbitrationd[36]: disk0s2    hfs      72C688EB-6013-3852-9674-6B4FE2278138 Jonathan                /
Jan 12 00:52:25 localhost kernel[0]: yukonosx: Ethernet address 00:17:f2:de:f2:77
Jan 12 00:52:25 localhost kernel[0]: AirPort_Athr5424ab: Ethernet address 00:1c:b3:b3:fc:00
Jan 12 00:52:26 localhost DirectoryService[41]: Launched version 2.1 (v353.6)
Jan 12 00:52:27 localhost kernel[0]: Registering For 802.11 Events
Jan 12 00:52:27 localhost kernel[0]: [HCIController][setupHardware] AFH Is Supported
Jan 12 00:52:27 Jonathans-Computer configd[34]: setting hostname to "Jonathans-Computer.local"
Jan 12 00:52:27 Jonathans-Computer lookupd[64]: lookupd (version 369.6) starting - Tue Jan 12 00:52:27 2010
Jan 12 00:52:28 Jonathans-Computer kernel[0]: display: Not usable
Jan 12 00:52:28 Jonathans-Computer /System/Library/CoreServices/loginwindow.app/Contents/MacOS/loginwindow: Login Window Application Started
Jan 12 00:52:28 Jonathans-Computer loginwindow[67]: Login Window Started Security Agent
Jan 12 00:52:29 Jonathans-Computer /System/Library/PrivateFrameworks/Apple80211.framework/Resources/airport: Currently connected to network Cassie
Jan 12 00:52:32 Jonathans-Computer mDNSResponder: Adding browse domain local.
Jan 12 00:52:32 Jonathans-Computer configd[34]: executing /System/Library/SystemConfiguration/Kicker.bundle/Contents/Resources/enable-network
Jan 12 00:52:32 Jonathans-Computer configd[34]: posting notification com.apple.system.config.network_change
Jan 12 00:52:32 Jonathans-Computer lookupd[104]: lookupd (version 369.6) starting - Tue Jan 12 00:52:32 2010
Jan 12 00:52:33 Jonathans-Computer sudo:     root : TTY=unknown ; PWD=/ ; USER=root ; COMMAND=/sbin/kextload /System/Library/Extensions/speedit.kext
Jan 12 00:52:33 Jonathans-Computer kernel[0]: SpeedIt Kext is loading!
Jan 12 00:52:33 Jonathans-Computer kernel[0]: Supported states 
Jan 12 00:52:33 Jonathans-Computer configd[34]:   target=enable-network: disabled
Jan 12 00:58:48 localhost kernel[0]: hi mem tramps at 0xffe00000
Jan 12 00:58:48 localhost kernel[0]: PAE enabled
Jan 12 00:58:48 localhost kernel[0]: 64 bit mode enabled
Jan 12 00:58:48 localhost kernel[0]: standard timeslicing quantum is 10000 us
Jan 12 00:58:48 localhost kernel[0]: vm_page_bootstrap: 250304 free pages
Jan 12 00:58:48 localhost kernel[0]: mig_table_max_displ = 71
Jan 12 00:58:48 localhost kernel[0]: Enabling XMM register save/restore and SSE/SSE2 opcodes
Jan 12 00:58:48 localhost kernel[0]: 93 prelinked modules
Jan 12 00:58:48 localhost kernel[0]: ACPI CA 20060421
Jan 12 00:58:48 localhost kernel[0]: AppleIntelCPUPowerManagement: ready
Jan 12 00:58:48 localhost kernel[0]: AppleACPICPU: ProcessorApicId=0 LocalApicId=0 Enabled
Jan 12 00:58:48 localhost kernel[0]: AppleACPICPU: ProcessorApicId=1 LocalApicId=1 Enabled
Jan 12 00:58:48 localhost kernel[0]: Copyright (c) 1982, 1986, 1989, 1991, 1993
Jan 12 00:58:48 localhost kernel[0]: The Regents of the University of California. All rights reserved.
Jan 12 00:58:48 localhost kernel[0]: using 5242 buffer headers and 4096 cluster IO buffer headers
Jan 12 00:58:48 localhost kernel[0]: Enabling XMM register save/restore and SSE/SSE2 opcodes
Jan 12 00:58:48 localhost kernel[0]: Started CPU 01
Jan 12 00:58:48 localhost kernel[0]: IOAPIC: Version 0x20 Vectors 64:87
Jan 12 00:58:48 localhost kernel[0]: ACPI: System State [S0 S3 S4 S5] (S3)
Jan 12 00:58:48 localhost kernel[0]: Security auditing service present
Jan 12 00:58:48 localhost kernel[0]: BSM auditing present
Jan 12 00:58:48 localhost kernel[0]: disabled
Jan 12 00:58:48 localhost kernel[0]: rooting via boot-uuid from /chosen: 2D2A2B8C-BE44-476A-BD90-80AF73E53AF0
Jan 12 00:58:48 localhost kernel[0]: Waiting on <dict ID="0"><key>IOProviderClass</key><string ID="1">IOResources</string><key>IOResourceMatch</key><string ID="2">boot-uuid-media</string></dict>
Jan 12 00:58:48 localhost kernel[0]: USB caused wake event (EHCI)
Jan 12 00:58:48 localhost kernel[0]: FireWire (OHCI) Lucent ID 5811 PCI now active, GUID 001b63fffe73a6ac; max speed s400.
Jan 12 00:58:48 localhost kernel[0]: Got boot device = IOService:/AppleACPIPlatformExpert/PCI0@0/AppleACPIPCI/SATA@1F,2/AppleAHCI/PRT2@2/IOAHCIDevice@0/AppleAHCIDiskDriver/IOAHCIBlockStorageDevice/IOBlockStorageDriver/FUJITSU MHW2080BHPL Media/IOGUIDPartitionScheme/Apple_HFS_Untitled_1@2
Jan 12 00:58:48 localhost kernel[0]: BSD root: disk0s2, major 14, minor 2
Jan 12 00:58:48 localhost kernel[0]: jnl: replay_journal: from: 8286720 to: 4643328 (joffset 0x254000)
Jan 12 00:58:48 localhost kernel[0]: CSRHIDTransitionDriver:robe: 
Jan 12 00:58:48 localhost kernel[0]: CSRHIDTransitionDriver::start before command
Jan 12 00:58:48 localhost kernel[0]: CSRHIDTransitionDriver::stop
Jan 12 00:58:48 localhost kernel[0]: IOBluetoothHCIController::start Idle Timer Stopped
Jan 12 00:58:48 localhost kernel[0]: Jettisoning kernel linker.
Jan 12 00:58:48 localhost kernel[0]: Resetting IOCatalogue.
Jan 12 00:58:48 localhost kernel[0]: GFX0: family specific matching fails
Jan 12 00:58:48 localhost kernel[0]: display: family specific matching fails
Jan 12 00:58:48 localhost kernel[0]: Matching service count = 2
Jan 12 00:58:48 localhost kernel[0]: Matching service count = 4
Jan 12 00:58:48 localhost kernel[0]: Matching service count = 4
Jan 12 00:58:48 localhost kernel[0]: Matching service count = 4
Jan 12 00:58:48 localhost kernel[0]: Matching service count = 4
Jan 12 00:58:48 localhost kernel[0]: Matching service count = 4
Jan 12 00:58:48 localhost kernel[0]: Previous Shutdown Cause: 5
Jan 12 00:58:48 localhost kernel[0]: GFX0: family specific matching fails
Jan 12 00:58:48 localhost kernel[0]: display: family specific matching fails
Jan 12 00:58:48 localhost kernel[0]: ath_attach: devid 0x24
Jan 12 00:58:48 localhost kernel[0]: Override HT40 CTL Powers. EEPROM Version is 14.4, Device Type 5
Jan 12 00:58:48 localhost kernel[0]: ath_descdma_setup: tx dd_desc_paddr = 0xdbd9000, length 0x46500(288000) bytes
Jan 12 00:58:48 localhost kernel[0]: ath_descdma_setup: beacon dd_desc_paddr = 0x974a000, length 0x90(144) bytes
Jan 12 00:58:48 localhost kernel[0]: mac 12.10 phy 8.1 radio 12.0
Jan 12 00:58:48 localhost kernel[0]: IPv6 packet filtering initialized, default to accept, logging disabled
Jan 12 00:58:48 localhost memberd[37]: memberd starting up
Jan 12 00:58:48 localhost mDNSResponder-108.6 (Jul 19 2007 11: 41:28)[30]: starting
Jan 12 00:58:48 localhost lookupd[43]: lookupd (version 369.6) starting - Tue Jan 12 00:58:48 2010
Jan 12 00:58:49 localhost diskarbitrationd[36]: disk0s2    hfs      72C688EB-6013-3852-9674-6B4FE2278138 Jonathan                /
Jan 12 00:58:50 localhost kernel[0]: yukonosx: Ethernet address 00:17:f2:de:f2:77
Jan 12 00:58:50 localhost kernel[0]: AirPort_Athr5424ab: Ethernet address 00:1c:b3:b3:fc:00
Jan 12 00:58:51 localhost DirectoryService[41]: Launched version 2.1 (v353.6)
Jan 12 00:58:52 localhost kernel[0]: Registering For 802.11 Events
Jan 12 00:58:52 localhost kernel[0]: [HCIController][setupHardware] AFH Is Supported
Jan 12 00:58:52 Jonathans-Computer configd[34]: setting hostname to "Jonathans-Computer.local"
Jan 12 00:58:52 Jonathans-Computer lookupd[64]: lookupd (version 369.6) starting - Tue Jan 12 00:58:52 2010
Jan 12 00:58:53 Jonathans-Computer kernel[0]: display: Not usable
Jan 12 00:58:53 Jonathans-Computer /System/Library/CoreServices/loginwindow.app/Contents/MacOS/loginwindow: Login Window Application Started
Jan 12 00:58:53 Jonathans-Computer loginwindow[67]: Login Window Started Security Agent
Jan 12 00:58:54 Jonathans-Computer /System/Library/PrivateFrameworks/Apple80211.framework/Resources/airport: Currently connected to network Cassie
Jan 12 00:58:55 Jonathans-Computer configd[34]: executing /System/Library/SystemConfiguration/Kicker.bundle/Contents/Resources/enable-network
Jan 12 00:58:55 Jonathans-Computer configd[34]: posting notification com.apple.system.config.network_change
Jan 12 00:58:55 Jonathans-Computer lookupd[102]: lookupd (version 369.6) starting - Tue Jan 12 00:58:55 2010
Jan 12 00:58:56 Jonathans-Computer sudo:     root : TTY=unknown ; PWD=/ ; USER=root ; COMMAND=/sbin/kextload /System/Library/Extensions/speedit.kext
Jan 12 00:58:56 Jonathans-Computer kernel[0]: SpeedIt Kext is loading!
Jan 12 00:58:56 Jonathans-Computer kernel[0]: Supported states 
Jan 12 00:58:56 Jonathans-Computer configd[34]:   target=enable-network: disabled
Jan 12 00:58:57 Jonathans-Computer mDNSResponder: Adding browse domain local.


----------



## Giaguara (Jan 12, 2010)

Previous shutdown cause is reported always after the system is started and starts the services... in the example above, the logs start about the moment the system was started, so the last commands given to it before it received the shutdown signal aren't included (they'd be before - whenever there is a break of time before the last commands and the powering on). But we can see something

Jan 12 00:58:48 localhost kernel[0]: Previous Shutdown Cause: 5
Sleep called for the shutdown in this case.

Was there also before the shutdown line something like below?
kernel[0]: Previous Sleep Cause: 0 

Finding a correct translation for the numbers in the shutdown cause is always a nice treasure hunt, for number 5 this is what I think covers it as much as it's ever been covered even in a semi-public view. Which will still leave a lot of open ends to find the exact cause in this case.

What does system profiler show for the battery? Voltage in full charge, cycle count, is it seen correctly?
Does the Mac get hot in use?
Do you have any usb hubs connected to the Mac?
_Any_ peripherals? If there are, it would be worth testing with nothing attached to it (not even an external mouse).
Any remote services enabled? Remote login, or remote desktop etc?
Any difference if you are using battery or are connected to the mains?
Any difference for other users on the Mac? If there aren't other users, create one (and it can be deleted later). 
Any unusual programs or services that could be running? Any torrent services, anything like Parallels or Fusion or VirtualBox? Games?
I guess we could eliminate the services as a cause if running the Mac in _safe mode_ (boot with shift until you see it's starting in safe mode), with nothing attached to the Mac, and it would not happen there.


----------



## jcbar (Jan 12, 2010)

*I&#8217;ve put my responses in bold:*

Previous shutdown cause is reported always after the system is started and starts the services... in the example above, the logs start about the moment the system was started, so the last commands given to it before it received the shutdown signal aren't included (they'd be before - whenever there is a break of time before the last commands and the powering on). But we can see something

Jan 12 00:58:48 localhost kernel[0]: Previous Shutdown Cause: 5
Sleep called for the shutdown in this case.

Was there also before the shutdown line something like below?
kernel[0]: Previous Sleep Cause: 0 
*I copied and pasted all of the log.  I also noticed there wasn&#8217;t anything regarding before I booted up last.  There is nothing like the &#8220;Previous Sleep Cause: 0&#8221; you mentioned.*

Finding a correct translation for the numbers in the shutdown cause is always a nice treasure hunt, for number 5 this is what I think covers it as much as it's ever been covered even in a semi-public view. Which will still leave a lot of open ends to find the exact cause in this case.

What does system profiler show for the battery? 
Voltage in full charge, cycle count, is it seen correctly?
*Battery Installed:	Yes
  First low level warning:	No
  Full Charge Capacity (mAh):	5098
  Remaining Capacity (mAh):	3672
  Amperage (mA):	1680
  Voltage (mV):	12155
  Cycle Count:	445*
Does the Mac get hot in use?
*Not really&#8230; it warms up slightly after continued use, but nothing major or any more than any other computer.*
Do you have any usb hubs connected to the Mac?
*No*
Any peripherals? If there are, it would be worth testing with nothing attached to it (not even an external mouse).
*Nothing attached*
Any remote services enabled? Remote login, or remote desktop etc?
*No*
Any difference if you are using battery or are connected to the mains?
*No difference*
Any difference for other users on the Mac? If there aren't other users, create one (and it can be deleted later). 
*No difference*
Any unusual programs or services that could be running? Any torrent services, anything like Parallels or Fusion or VirtualBox? Games?
*Nope*
I guess we could eliminate the services as a cause if running the Mac in safe mode (boot with shift until you see it's starting in safe mode), with nothing attached to the Mac, and it would not happen there.
*I did this, and the shutdown still happened.*

*This one is a pickle!!!*


----------



## Giaguara (Jan 12, 2010)

Older logs would be under the archive (from the logs sidebar in console). 
Hm... not battery, not a user specific thing, and happens in safe boot. :-/
You said you had done the hardware test and it reported nothing. 
Did you run it once or multiple times? It's usually best run in looped mode with extended test at least for a few hours. Is it possible to test run it for a few hours or an evening?
When you boot to the hardware test and don't select anything (and let it get idle) will it still do that?
Or if booted from an OS install disc? Don't select to install anything but let it get idle...


----------



## jcbar (Jan 12, 2010)

When I ran the hardware test last it did not shut down.  I actually left the computer alone to see if it would.

I'm not sure about running from the install disk; I'll have to check that.

I'll run the hardware test again this evening and give a report!


----------



## johau (Apr 5, 2010)

Hi jcbar!
I have the same problem with my Macbook. Did you find a solution?

These are the specs of my Macbook:
  Modellname:	MacBook
  Modell-Identifizierung:	MacBook1,1
  Prozessortyp:	Intel Core Duo
  Prozessorgeschwindigkeit:	2 GHz
  Anzahl der Prozessoren:	1
  Gesamtzahl der Kerne:	2
  L2-Cache (pro Prozessor):	2 MB
  Speicher:	1 GB
  Busgeschwindigkeit:	667 MHz
  Boot-ROM-Version:	MB11.0061.B03
  SMC Version:	1.4f12
  Seriennummer:	4H61913AVMM
  Sensor für plötzliche Bewegung:
  Status:	Aktiviert

I am running Tiger 10.4.11, all updates installed.

It happens at about 65sec after the last activity (mouse / kbd) and you have 5sec to click on the "Cancel" button - very nasty!
It happens when running off the battery or AC adapter, battery installed or not. I can confirm it happens when started in safe mode (<SHIFT> during boot).


----------



## johau (May 27, 2010)

I found the problem for this behaviour: it is the keyboard. After replacing the KBD my Macbook behaves normally again.

I hope this helps other users...

Johannes


----------

