-
-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Hibernation Issues with OpenCore #72
Comments
I hope this is helpful. This post by @traviswparker indicates there was a fix in a custom plist: |
@houser42 Their configuration breaks OpenCore spec and removes a lot of what the patcher uses to ensure a stable system when SMBIOS is changed such as WhateverGreen and AirportFixup. They haven't responded to the thread about what they actually changed and diffing between it and the patcher's plist is more confusing than anything. Assuming logically what could've fixed hibernation with their build is the removal of |
I see, appreciate the heads-up. I guess I should really go back to the main config.plist and wait for a real fix. |
@houser42 To test this theory, can you try to see if this branch works with hibernation?: https://github.com/dortania/Opencore-Legacy-Patcher/tree/hibernation |
@khronokernel |
Awesome, can you test if it wakes correctly after setting |
Sure. |
Yeah |
Yes, that appears to work. BTW. I am on Big Sur 11.2.2 if that matters. |
Awesome, I actually have 1 more test I just pushed to that branch. It re-enables OpenRuntime as well as DiscardHibernateMap. I'm curious if that last quirk is what we're missing for hibernation support |
Ok. You mean load same link: https://github.com/dortania/Opencore-Legacy-Patcher/archive/hibernation.zip again now and just run the patcher again? |
Yeah |
Yes, still appears to work as expected. No issues so far.. |
Awesome! I'm going to merge the changes however will keep this issue open for the day. If there aren't any reports of it still being broken then I'll close it. Thanks so much for your help! |
My pleasure. I just hope I am doing it right then ..;)
|
Can you try using the binary? We actually converted the patcher to a .app on releases. Here's the latest binary: https://github.com/dortania/Opencore-Legacy-Patcher/suites/2179614486/artifacts/44846509 This doesn't require any python installs or updates |
Both the command file and the binary work fine with regards to the install and the actual hibernation issue. |
We're planning to add DEBUG toggles for the patcher, however our current plan will take some work. So as a work around, you can simply set https://github.com/dortania/Opencore-Legacy-Patcher/blob/main/Resources/Constants.py#L43 |
Ok. I will test longer hibernation over night also. Thanks again. |
I still getting P.S. Apple broke hibernation on old Macs with third-party SATA SSDs on 10.15+ and now we need the ThirdPartyDrives quirk. |
@family1232009 Sorry a bit confused, we don't enable |
still seeing hibernation issues on MacBookPro10,1. When waking from hibernate I see the backlight come on, then go off, then come on and reboot. to ensure the Mac actually hibernates and attempts to wake from EFI, you need to do the following:
then |
@traviswparker Are you able to verify if this build works?: |
Yes, I need |
FWIW, using the commands @traviswparker gave, my Macbook Pro 10,2 also crashes at wake using that build. Assuming that is the best way to test this, I am sorry to report that my reports of success were probably incorrect and premature.., but there it is...:( |
I can confirm this. I have a MacBook Pro 10,1 (Retina 15" MacBook Pro Mid-2012) and per se everything was working (except for an issue because of my upgraded WiFi card, see here). But: when the Mac woke up, it sometimes took like 20 seconds or so before the picture appeared (backlight was on from the start). By disabling ConnectDrivers, it is now instant on like it was before on Catalina. Thanks for the find! |
Isn't setting ConnectDrivers to false the same as disabling all drivers? In other words, hibernation won't go through OC but neither will BootVarRouting, so installs/upgrades will die with the prohibited symbol until you option-boot and select OC. |
I don‘t think so. The configuration guide states the following. Sounds to like this is only for specific drivers. And why would an install/upgrade fail even then? If the machine reboots, OC is run anyway again.
|
Ok, I might have the low-level details wrong here, but: When macOS performs an install/upgrade, it sets the boot config in NVRAM to the temporary installer data. This bypasses OC in the EFI partition and you'll get the prohibited symbol on an unsupported Mac. One of the things the OpenRuntime driver does is RequestBootVarRouting, which allows it to intercept that change. It keeps NVRAM pointed at EFI/OC and changes its own boot config to the installer data. |
I cannot judge if that is the case. And since I am on the latest version of Big Sur already, I cannot easily test it. What I did test is to shut down the MacBook, start it again with an NVRAM reset. Everything booted completely fine. But that is also expected right? As far as I know (but I might be completely wrong) the Mac does a normal reboot, just with the boot volume pointing to somewhere else. At least when installing Big Sur, it does it like that. I always saw the OC menu and could have selected a different boot volume, if I wanted to. So I would guess, that it is the same for the updates. @khronokernel: can you maybe enlighten us what exactly BootVarRouting and ConnectDrivers do? |
@mav2010
If |
Hello all; I am having issues with Wake on lan on both windows 10 and Mac OS. (MacBook Pro 2011 8,1 13 inch) If i access the MBP within an hour of entring sleep mode, it works fine. but if i wait longer it doesn't wake up on both windows 10 & big sur. I have noticed also something in Big Sur when i access via screen sharing app from another mac it wakes up, but not via VNC viewer (which is the important because i am trying to access from ios or windows machine). I believe it is waking up via screen share app because it has something to do with Bonjour services; not sure though. I checked on windows the supported Sleep states via "powercfg /availablesleepstates" command and the supported sleep modes were ( Standby S3 , hibernate & Hybrid sleep) , I disabled hibernate via "powercfg.exe /h off" command but also the same issue is still happening not able to wake the w10 installation after an hour. I believe that there is some setting in the EFI that is overruling the Mac & W10 sleep mode configuration. Any suggestions? |
I use a Mac Pro with a remote VNC connection and I have the same issue. |
Hi, I've got a couple of MacbookPro9,1 on 11.6 which were having frequent hibernate/WakeFromSleep issues and also the backlit black screen for 10-20 seconds on start. I've applied the Both machines are more or less stock apart from ac Wireless upgrades, and RAM/SSD upgrades. |
Hi there, I'm running macOS Monterey on a MacBook Pro 11,1. I am encountering this same issue where, if my MBP goes to sleep for a short period, it wakes fine. However, if sleeping for a long period, it won't wake when I open the lid: I have to press the Power key and wait for it to boot. It appears to be resuming not booting, as it's much faster than booting, but it does mean that Unlock with Apple Watch functionality is broken. |
Hello. I believe this to be related to this discussion. I have a MacBookPro11,2. While pretty much everything works with the upgrade to Monterey (from Big Sur) with OpenCore, when I leave the machine for long periods and it has gone to sleep for long periods, when I come back I see the following:
Looking at system logs for the most recent instance of the issue: log show --predicate 'eventMessage contains "Previous shutdown cause"' --last 24h Cause 128 seems pretty nebulous. But looking back further at each instance where this behavior occurred, that same 128 is the cause. Not sure if this is somehow helpful, but if this is the same as what has been encountered by others, it doesn't appear the current build has fixed the issue for all devices. I'm wary of setting hibernatemode 0 given the battery implications. Would appreciate some suggestions. Thanks. |
I have the same issue on a MPB11,1 but if I wait long enough (30m or so it did wake up) it finally gave me the desktop and then I received the hash error on system volume error message -- maybe they are related. |
MBP11,3 here running Monterey with OpenCore, primary boot volume is NVME... I'm having an issue where sometimes when coming back from hibernate the keyboard is inaccessible. I can ssh into the machine and tell it to reboot, but until reboot occurs, the keyboard is inaccessible. Is there a way to kick the keyboard on resume? |
Just to confirm that both systems are working perfectly on 11.6.1. Monterey upgrade failed, however. |
@WashJotson @blahdy @mav2010 are you able to provide some direction regarding how to enable the ConnectDriver config change? |
Hi folks. I actually tried hibernatemode 0 and it had no effect. After a longer period of sleep (14 hours this time), I see a white apple logo, then login screen indicating a restart happened, but when I log in everything is exactly as I left it, it doesn't take time to load up the apps. Is this possibly safe sleep somehow, even though safe sleep is disabled? Any thoughts would be appreciated. |
Yep. If you have OpenCore installed:
If you don't have OpenCore installed, build OpenCore using the patcher UI. When you get the path for the temporary build, apply the same change to |
@WashJotson's process dramatically sped up wake from hibernation for me on a MacBookPro11,3. |
Thanks @WashJotson! What exactly is this changing and what potential side effects might there be? It’s unclear from prior comments. |
From @mav2010 's link to the OpenCore manual, I think it stops OpenCore from force loading all the bundled drivers every time that the system is rebooted. My guess would be when all the drivers are loading it slows down reboots/wake from hibernate sufficiently to fail a macOS check, so it thinks the wake from sleep has failed. The documentation indicates side effects could be devices or filesystems being disconnected on reboot, but haven't encountered this yet. I will try and let one of my systems hibernate whilst hooked up to a bunch of external devices but doubt this will break anything as those drivers will be in macOS |
I tried the workaround to set ConnectDrivers to false and rebooted after and everything was fine. I came to my laptop this morning and tried to start it and the same issue occurred. To be clear, I have two external displays and power connected to my laptop, and the clamshell is closed. The flow is as follows:
This definitely all began right after the upgrade to Monterey using OpenCore. Looking at the logs I see this: 2021-11-13 09:00:01.014515-0500 0x175bc Default 0x0 0 0 kernel: (AppleSMC) Previous shutdown cause: 5 So the shutdown cause now shows 5 which seems to be a normal restart, but I didn't restart it. Honestly my main issue with this is that while I can wake up the machine with a click on the external trackpad, I can't use the trackpad after that and I can't use the external keyboard until I log in — I have to open the clamshell to enter my password which was never the case in the past. Does any of this make any sense to anyone, and does anyone have any suggestions? Also should I switch the ConnectDrivers back to true since this didn't make a difference? |
Not sure if relevant here, but I could not get my cMP 5,1 (using OCLP v0.3.1 and Monterey 12.0.1) to sleep, and tried everything. Since it worked fine in Bootcamp Win10, I assumed this was an OCLP issue. Turns out my Logitech BCC950 USB webcam was waking it as soon as it entered sleep. I got the below, issuing: pmset -g log | grep -e "Sleep.*due to" -e "Wake.*due to"
My fix was to move the BCC950 from one of the rear internal USB 2.0 ports, to a PCIe USB 3.1 card I had installed by daisy-chaining it to the USB 3.0 hub on the back of my monitor. Now my cMP5,1 sleep and stays asleep like a champ. Hope this is of help to someone... |
This is about legacy macs, only. Please discuss PC laptop issues here. |
Hi, the hibernation reprise to work perfectly on my Mac Pro 3.1 (with a UPS connected) after disabling the connection drivers. |
yeah, but that breaks updates. to update you must reenable cooncetdrivers and reboot, or manually hold alt and choose OC during update reboots |
You're thinking of RequestBootVarRouting, which requires OpenRuntime. Disabling OpenRuntime will prevent routing of resume through OC but also break updating boot-vars. Setting ConnectDrivers false doesn't affect RequestBootVarRouting. |
I'm on an iMac 13,2 running Monterey, and it randomly restarts in sleep mode. One time in the middle of the night, with chime and all, and just now it happened about a minute after putting it to sleep. |
For some machines, hibernation is broken resulting in
Sleep Wake Failure
when waking. Currently we recommend users disable hibernation until a more suitable solution is found:Note: Please only reply with possible solutions. This issue is not a discussion thread
The text was updated successfully, but these errors were encountered: