Vanya Crow

Q: MBP freezes on sleep and logout

This has been driving me nuts for three weeks now, and couldn't find anybody with a similar problem in the usual forums, so here it goes...


MBP from August 2010:


2,66 GHz Intel Core i7

8 GB 1067 MHz DDR3

Intel HD Graphics 288 MB + NVIDIA GeForce GT 330M


Mavericks - OS X 10.9.5 (13F34).

(The problem first happened while running OS X 10.9.4 and continued after the update.)


The issue: when I close the lid or try logging out from any account —admin, user or guest— the system freezes. The screen goes black or freezes in the logging screen. Keyboard becomes irresponsive. Hard drive sometimes sounds as being doing something. On occasions, when closing the lid down, the system actually manages to enter sleep mode, though it might take it up to a couple of minutes, and, when opening the lid, it freezes on wake up anyway. After such freezes, on about 50% of times, the system also freezes on start up. So I have to retry several times until, for some unknown reason, it starts up "normally". Reseting the NV-RAM seems to help guarantying a restart, though I couldn't see a 100% correlation. Funny enough, the system doesn't seem to have any issue if I do a full shutdown without logging out, though it takes about double time than it used to.


That's the core of the problem, I think, because other things also started to go wrong the second after the first freeze on sleep happened. Any software that somehow has to interact with screen/video resolutions, such as VLC, Quicktime, Safari Flash Player or games that go on full screen, crash on start. Some other non-video-related programs also tend to crash or take an awful long time to start. So far, I have experienced that on Chrome, TheUnarchiver and uTorrent. To make things more interesting, all this programs seem to agree on when and when not work. So if one of them goes wrong, all of them will go wrong and I'd have to restart the system and cross my fingers. I failed to identify the apparent common root...


The fact that issues are independent of the account I log in to and that various pieces of software seem to fail together or not at all hints, I think, to a failure somewhere deeper in the system or in the hardware. I ran a hardware test and, apart form a bit worn out 4 year old battery, everything got an OK. I checked the hard drive and the permissions table and nothing popped out apart from some minor and usual errors, which got corrected. I updated from 10.9.4 to 10.9.5 —keeping users files—, the update happened, but the system froze on the first automatic restart. The problem persisted on 10.9.5, so I did another system reinstall, this time, right after reseting the power management system and NV-RAM, just in case. Again, reinstall seemed to happen without errors, but the system froze on restart. Though it came back again "normal" after doing a manual shutdown. Spent hours looking at the system logs, and couldn't find anything related to any of the multiple freezes and neither do the individual software crashes seem to leave a log (!!!).


Also, in case it may have some relation with the issue, though I doubt it, I have a Bootcamp partition with a Windows 7 Ultimate installed. It's being there for the last two years without making any trouble, running as smooth as a Window can and, as far as I can tell, unaffected by any of the problems above.


Hope somebody can give me any clues... Thanks in advance!!!

MacBook Pro, OS X Mavericks (10.9.5)

Posted on Oct 11, 2014 2:11 PM

Close

Q: MBP freezes on sleep and logout

  • All replies
  • Helpful answers

  • by Linc Davis,

    Linc Davis Linc Davis Oct 11, 2014 3:50 PM in response to Vanya Crow
    Level 10 (207,963 points)
    Applications
    Oct 11, 2014 3:50 PM in response to Vanya Crow

    When you have the problem, note the exact time: hour, minute, second.  

    These instructions must be carried out as an administrator. If you have only one user account, you are the administrator.

    Launch the Console application in any of the following ways:

    ☞ Enter the first few letters of its name into a Spotlight search. Select it in the results (it should be at the top.)

    ☞ In the Finder, select Go Utilities from the menu bar, or press the key combination shift-command-U. The application is in the folder that opens.

    ☞ Open LaunchPad. Click Utilities, then Console in the icon grid.

    The title of the Console window should be All Messages. If it isn't, select

              SYSTEM LOG QUERIES All Messages

    from the log list on the left. If you don't see that list, select

              View Show Log List

    from the menu bar at the top of the screen.

    Each message in the log begins with the date and time when it was entered. Scroll back to the time you noted above.

    Select the messages entered from then until the end of the episode, or until they start to repeat, whichever comes first.

    Copy the messages to the Clipboard by pressing the key combination command-C. Paste into a reply to this message by pressing command-V.

    The log contains a vast amount of information, almost all of it useless for solving any particular problem. When posting a log extract, be selective. A few dozen lines are almost always more than enough.

    Please don't indiscriminately dump thousands of lines from the log into this discussion.

    Please don't post screenshots of log messages—post the text.

    Some private information, such as your name, may appear in the log. Anonymize before posting.

  • by CaptH,

    CaptH CaptH Oct 11, 2014 5:17 PM in response to Vanya Crow
    Level 1 (59 points)
    Oct 11, 2014 5:17 PM in response to Vanya Crow

    Simple things first:

     

    1. Try disabling (unchecking) the "Put hard drive to sleep when possible" under System Preferences->Energy Saver, then use the system

    2. If that doesn't help, try putting the screen and sleep settings in Energy Saver to "Never" as an experiment, then use the system

    3. If you haven't updated to 10.9.5, do so, assuming you can successfully accomplish it

     

    If you're on 10.9.5 and items 1 and/or 2 clear up the problem you should contact Apple and report it as a bug. If you're currently on 10.9.4 and you upgrade to 10.9.5 and the problems stop, you're done...I think this was one of the bug fixes in 10.9.5.

     

    I've seen this happen on some systems. It seems to be very system dependent, but on those I've seen it occur on, it seemed fixed in 10.9.5. However, just because it seems fixed on the systems I'm working with doesn't mean it's fixed on all of them. On the systems I've seen this happen on,  when the system went to sleep, it was as if the OS ejected the boot drive, and when waking up, there was no longer a drive present to access, hence a lockup.

     

    If it isn't an OS bug or problem, it may be software related. I would boot into safe mode and see if the problems continue to replicate themselves. If, when running in safe mode, the problems go away, then it's something that's either being loaded by the system or something you're starting when you log in. That's something you would have to track down. Safe mode booting can be found at:

     

    OS X: What is Safe Boot, Safe Mode?

     

    It it's not the OS or an application, it may be hardware or file system related. You may wish to use Disk Utility to verify the file system and its permissions. If there's a hard drive problem you may need to get something like Scannerz to see if the problem can be found. If the drive has a corrupt/bad blocks typically the system doesn't lock up it just delays or hangs and then returns an error, so that's likely a long shot. You may also want to try re-seating your RAM.

     

    Good luck.

  • by Vanya Crow,

    Vanya Crow Vanya Crow Oct 12, 2014 2:18 PM in response to Linc Davis
    Level 1 (0 points)
    Oct 12, 2014 2:18 PM in response to Linc Davis

    OK, this is maybe a bit excessive, but when I tried to replicate the problem, in order to get the logs you asked me for, lots of things happened. First, I rebooted  and logged in on my admin account —that's where the log file a link below starts [12/10:2014-22:01:19]—. So far so good. Second, rebooted to try getting a log of a "clean" reboot and system crashed on reboot, which is not usual. It took five manual shutdowns and restarts [12/10/2014-22:09:37, 22:11:23, 22:13:54, 13/10/2014-00:24:16 (!!!), 12/10.2014-22:29:03] to get it running again. Don't if it was by chance, but it restarted without crashing only after I unplugged the charger. After that I closed the lid and, after a one minute wait or so, system entered sleep. On opening the lid, the screen was frozen black as sadly expected, though this time keyboard seemed to work and I could shutdown by pressing Command+Option+Control+Eject. So, I restarted the system [12/10/2014-22:43:36], save the hugemongous log in a file and wrote you this.

     

    You can find the saved logs from the whole process, about 45 min, in this file:

     

    https://www.dropbox.com/s/v1mndrl2y5flkjq/log.rtf?dl=0

     

    I know you advised me against dumping a huge amount of log lines. I think that this way you can just check the last ones and, in case nothing relevant show up there, review the points of the process that you may find relevant.

     

    Many many thanks for your help and time!!!

  • by Vanya Crow,

    Vanya Crow Vanya Crow Oct 12, 2014 2:26 PM in response to CaptH
    Level 1 (0 points)
    Oct 12, 2014 2:26 PM in response to CaptH

    Thanks for your suggestions. I had already done your first three suggestions. It didn't help. Also updated to 10.9.5, checked drive and permissions but the problem persisted. The issue seems to happen also in safe mode, though I haven't fully explored that end... Thanks for your tips!

  • by Linc Davis,

    Linc Davis Linc Davis Oct 12, 2014 4:35 PM in response to Vanya Crow
    Level 10 (207,963 points)
    Applications
    Oct 12, 2014 4:35 PM in response to Vanya Crow

    Sorry, I won't even look at a log dump. I don't have the time or the interest. You simply ignored the instructions I wrote in red letters. Good luck.

  • by Vanya Crow,

    Vanya Crow Vanya Crow Oct 13, 2014 1:57 AM in response to Linc Davis
    Level 1 (0 points)
    Oct 13, 2014 1:57 AM in response to Linc Davis

    Excuse me, Linc, I wasn't my intent to annoy you or ignore your instructions. I understood what you requested and though carefully before giving you the link to the log dump. There are so many things show up in the log, that I cannot tell what can be relevant to help identifying the problem. I'm not even sure whether the issue originates during the system boot or when it actually freezes. I could easily provide you with a dozen lines that might as well be irrelevant. That's why I decided to send you the whole log dump together with the time marks for freezes and reboots, because I assume you can decide much better than me, what and what not could be relevant around those critical time marks.

     

    I appreciate and respect your time and help, so, if you can be bother, please, let me try again. This is what happened right before I managed to shutdown by pressing Command+Option+Control+Eject right after the system froze on opening the lid.

     

    12/10/14 22:42:20,755 sessionlogoutd[356]: sessionlogoutd Launched

    12/10/14 22:42:20,766 sessionlogoutd[356]: DEAD_PROCESS: 47 console

    12/10/14 22:42:20,767 loginwindow[47]: ERROR | -[Application hardKill:] | Application hardKill returned -600

    12/10/14 22:42:20,777 loginwindow[47]: ERROR | -[Application setAppContext:] | Unable to get PID for context [0,90134]

    12/10/14 22:42:20,778 loginwindow[47]: ERROR | -[ApplicationManager quitFinder] | Error: Could not get the Finder App, continuing the logout.

    12/10/14 22:42:20,782 loginwindow[47]: ERROR | -[Application terminate] | Application terminate returned 3

    12/10/14 22:42:20,783 com.apple.launchd.peruser.501[169]: (com.wacom.ConsumerTouchDriver.11120[177]) Exited with code: 1

    12/10/14 22:42:20,784 loginwindow[47]: ERROR | -[Application setAppContext:] | Unable to get PID for context [0,73746]

    12/10/14 22:42:20,786 loginwindow[47]: FAILURE: Job com.apple.Dock.agent is not loaded in launchd.

    12/10/14 22:42:20,786 loginwindow[47]: ERROR | -[ApplicationManager quitDock] | Error: SMJobRemove for Dock returned error:6

    12/10/14 22:42:20,787 loginwindow[47]: ERROR | -[Application setAppContext:] | Unable to get PID for context [0,73746]

    12/10/14 22:42:20,824 airportd[68]: _doAutoJoin: Already associated to “google”. Bailing on auto-join.

    12/10/14 22:42:20,935 shutdown[359]: halt by _netbios:

    12/10/14 22:42:20,935 shutdown[359]: SHUTDOWN_TIME: 1413146540 935370

     

    12/10/14 22:42:20,000 kernel[0]: Kext loading now disabled.

    12/10/14 22:42:20,000 kernel[0]: Kext unloading now disabled.

    12/10/14 22:42:20,000 kernel[0]: Kext autounloading now disabled.

    12/10/14 22:42:20,000 kernel[0]: Kernel requests now disabled.

     

    And this are the messages showing right after the next restart:

     

    12/10/14 22:43:36,000 bootlog[0]: BOOT_TIME 1413146616 0

    12/10/14 22:43:49,000 syslogd[20]: Configuration Notice:

    ASL Module "com.apple.appstore" claims selected messages.

    Those messages may not appear in standard system log files or in the ASL database.

    12/10/14 22:43:49,000 syslogd[20]: Configuration Notice:

    ASL Module "com.apple.authd" sharing output destination "/var/log/system.log" with ASL Module "com.apple.asl".

    Output parameters from ASL Module "com.apple.asl" override any specified in ASL Module "com.apple.authd".

    12/10/14 22:43:49,000 syslogd[20]: Configuration Notice:

    ASL Module "com.apple.authd" claims selected messages.

    Those messages may not appear in standard system log files or in the ASL database.

    12/10/14 22:43:49,000 syslogd[20]: Configuration Notice:

    ASL Module "com.apple.bookstore" claims selected messages.

    Those messages may not appear in standard system log files or in the ASL database.

    12/10/14 22:43:49,000 syslogd[20]: Configuration Notice:

    ASL Module "com.apple.eventmonitor" claims selected messages.

    Those messages may not appear in standard system log files or in the ASL database.

    12/10/14 22:43:49,000 syslogd[20]: Configuration Notice:

    ASL Module "com.apple.install" claims selected messages.

    Those messages may not appear in standard system log files or in the ASL database.

    12/10/14 22:43:49,000 syslogd[20]: Configuration Notice:

    ASL Module "com.apple.iokit.power" claims selected messages.

    Those messages may not appear in standard system log files or in the ASL database.

    12/10/14 22:43:49,000 syslogd[20]: Configuration Notice:

    ASL Module "com.apple.mail" claims selected messages.

    Those messages may not appear in standard system log files or in the ASL database.

    12/10/14 22:43:49,000 syslogd[20]: Configuration Notice:

    ASL Module "com.apple.MessageTracer" claims selected messages.

    Those messages may not appear in standard system log files or in the ASL database.

     

    My apologies again and I hope this is of some use...

  • by Vanya Crow,

    Vanya Crow Vanya Crow Oct 25, 2014 4:01 AM in response to Vanya Crow
    Level 1 (0 points)
    Oct 25, 2014 4:01 AM in response to Vanya Crow

    Yesss... I think I have identified the source of the problem and a solution!!!

     

    Almost by chance, I managed dig out a crash report about a "GPU Panic". From there on it only took 30 seconds to find this:

     

    MacBook Pro (15-inch, Mid 2010): Intermittent black screen or loss of video

     

    Long story short: on mid-2010 15'' MBP with an nVidia GeForce GT 330M —just like mine, how lucky is that— there's a hardware bug on the graphics card. To make things more obscure, it seems that the bug only has persistent and noticeable effects —such as the ones I described in the original post— in the latest versions of Mavericks —***!—. Still need to check what happens on Yosemite. The problem arises whenever the system changes graphics mode, between the Intel graphics card integrated in the main board and the higher performance mode using the PCI nVidia. This happens on login and logout, entering and leaving sleep mode and starting video related programs —video player, some browsing, games, etc.

     

    Solution: until I convince Apple to change the factory faulty graphics card, preventing the system from switching graphics mode, has solved the problem for me so far. One can do that un-ticking the option "Automatic graphics switching" in:

     

    System Preferences > Energy Saver > (Un-tick) Automatic graphics switching

     

    That forces the system to always run on the high performance graphics mode using the PCI nVidia. So far, in this mode, I didn't notice any dramatic change in battery duration. Haven't made any serious testing, but after running the computer on this mode for a week, I would say battery duration goes down about a 10%. On the upside, everything came back to normal and smooth, didn't experience a single freeze episode since I un-ticked that option