Announcement

Collapse
No announcement yet.

Macbook A1466 - Long to wake from sleep after motherboard swap

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    Macbook A1466 - Long to wake from sleep after motherboard swap

    Hi,

    I don't know if it's the correct forum for this but I hope so.

    So, it's the continuation of https://www.badcaps.net/forum/showthread.php?t=115802, I swapped the motherboard to a "working" second-hand one.

    Now, I have weird issues with it. It works mostly fine (can boot, and everything seems to work) but every time I close the lid, even for 1 second, it takes a very long time to wake up, like between 30s and 1 min, instead of the normal .5s.
    The weird thing is that in safe mode (booting with left shift pressed), it works fine. I tried to see what could do that in "EtreCheckPro", but the only difference I see is the zoom daemon (which I uninstalled) and the chrome update daemon (https://pastebin.com/C2p53Daf & https://pastebin.com/j90qG31V in safe mode, excuse me for the french in the logs).

    Another weird behaviour is that network recovery (cmd + alt + R) fails after downloads with a 5101F error code, and the original version network recovery (cmd + alt + shift + R) just hangs after loading (downloads works fine, but second progress bar fills very slowly and hangs full, had let it load all night but nothing happens).

    I don't know much about macs so I don't really know where to search.

    Edit : note that with a brand new session it does the same, but on initial boot before opening a session, it works correctly.
    Last edited by orion78fr; 03-07-2023, 06:26 PM. Reason: Adding details

    #2
    Re: Macbook A1466 - Long to wake from sleep after motherboard swap

    Okay so, I solved my problem ! (while severely sleep depraving myself ^^" 5AM at the moment of writing)

    So, I'm now 99% sure the problem was the EFI version on the new board was way too old to be compatible with the newest system version that was installed. As these updates are automagically installed when system is updated, Apple doesn't provide any easy way to update EFI or SMC versions.

    I did an `/usr/libexec/firmwarecheckers/eficheck/eficheck --integrity-check` and got a message about my EFI version not being in the allowlist, so I knew I didn't have the latest version.

    Downloaded a macos update and extracted it (took the one I found in another forum post : https://support.apple.com/kb/DL2088).
    To extract the interesting part, double click on the .dmg, copy the contained .pkg somewhere, then use `xar -xf <...>.pkg FirmwareUpdate.pkg`
    then `cd FirmwareUpdate.pkg && tar -xf Scripts`.

    Once we're here, we can flash the SMC and some other things (like usbc firmware) with `sudo /usr/libexec/FirmwareUpdateLauncher -p "$PWD/Tools"`. Should say at the end if something updated.
    Then flash the EFI with `sudo /usr/libexec/efiupdater -p "$PWD/Tools/EFIPayloads"`. It should say at the end "reboot to apply the update". Mine said it updated EFI from 176.00 to 428.60.3 !

    Rebooted, had an apple logo on black background with a progress bar, it rebooted, and now sleep works correctly and recovery mode doesn't crash anymore !

    Hope this could help someone in the future.

    Comment


      #3
      Re: Macbook A1466 - Long to wake from sleep after motherboard swap

      Nice one, command line stuff always handy. You can also determine firmware version by going into Finder, About This Mac, System Report.

      The problem using command line stuff for this is that you have to get into MAC OS first, rather than doing via the recovery console. Very old firmware versions won't boot APFS file systems so you are stuck there, and others don't recognise 3rd party SSD's. It's amazing how many people don't update, and some are still on Yosemite.

      So for really old boards that aren't APFS aware, the best way is to use either Big Sur (for 820-3437) or Monterey (for 820-00165) installers with a spare Apple SSD. Format it as MAC OS Journalled (if you use APFS it'll complain that you can't install it without a firmware update). Then install MAC OS in the usual way. Firmware is updated as part of the install process automatically. Once it gets to the final stage of installation (where it says about 30 mins remaining), no need to complete that. The firmware should've already been updated and you can put any old drive in from that point. You'll also find at the end your SSD has been auto updated to APFS too.

      As a footnote, newer versions of MAC OS have the OS in a separate APFS container to that of the user data. They have a software integrity feature called the seal that detects if any tampering has occurred. IIRC, you actually boot off an image of the OS, not the actual files. Reinstallation is very risk free, and doesn't touch the user APFS container. Can't see how any 3rd party (virus or malware) could alter the OS without it being detected. Apple do have some great stuff in this way and light years ahead of Windows.
      Last edited by reformatt; 03-08-2023, 12:41 AM.

      Comment


        #4
        Re: Macbook A1466 - Long to wake from sleep after motherboard swap

        Originally posted by reformatt View Post
        You can also determine firmware version by going into Finder, About This Mac, System Report.
        Yes, but also no. The system report was telling me EFI was "MBA71.0176.B00" and is now "428.60.3.0.0", two vastly different numbering scheme. Plus I didn't find any official documentation on what the current version is (and couldn't compare it either to the "430.140.3.0.0" I found somewhere on the net).

        Originally posted by reformatt View Post
        The problem using command line stuff for this is that you have to get into MAC OS first, rather than doing via the recovery console.
        The problem I had is that no recovery option (cmd + R, cmd + alt + R and cmd + alt + shift + R) booted in my case, it either errored out with an 5101F or hanged while loading (which is fixed now that the EFI is updated). Don't know if an USB bootable device would have worked or just hang like the other recovery options.
        Another solution I found on internet, if recovery worked, was to install macOS on an external USB device. That would have updated the EFI during the install.

        Originally posted by reformatt View Post
        IIRC, you actually boot off an image of the OS, not the actual files. Reinstallation is very risk free, and doesn't touch the user APFS container.
        Oh yeah, would have been great, but didn't want to risk the user data and didn't have any spare mac drive at hand.
        By the way, on windows, when you reinstall over the main partition, all user data is copied under a windows.old folder at the root (you have to choose custom install and point to the correct partition IIRC), which is handy if you can't boot the device (but I would recommend a copy by extracting the disk anyway, I can't trust any of these reinstalls to safely handle my data).

        Comment


          #5
          Re: Macbook A1466 - Long to wake from sleep after motherboard swap

          Built in recovery doesn't work on the really old firmware, that's why you create a bootable installer on USB. If you work on these regularly like I do, then something like MBA71.0176.B00 is considered at least pre-High Sierra. I know that new numbering scheme started from at least that version (think it was 195.0.0.0 or similar).

          820-00165 boards are at 476.0.0.0 for Monterey 12.6.3.

          Comment


            #6
            Re: Macbook A1466 - Long to wake from sleep after motherboard swap

            Originally posted by reformatt View Post
            Built in recovery doesn't work on the really old firmware, that's why you create a bootable installer on USB.
            Oh I see, I kinda assumed the included internet recovery was a failsafe way to reinstall because it would download what it needs to work, like a recent bootable USB directly downloaded "in memory".

            Comment


              #7
              Re: Macbook A1466 - Long to wake from sleep after motherboard swap

              Older versions of the recovery console usually default to whatever MAC OS it came with and tries to download it from Apple's servers. If something changes on Apple's end then this no longer works, especially if its an older version they no longer support.

              Hence why I never use it and rely on USB installers. Its like a chicken and egg situation really. Unfortunately on the newer T2 MAC's, this option is disabled by default and a complete PITA if recovery doesn't work for some reason.

              Comment


                #8
                Re: Macbook A1466 - Long to wake from sleep after motherboard swap

                https://www.badcaps.net/forum/showthread.php?t=117885
                Last edited by piernov; 04-10-2023, 06:52 AM.

                Comment

                Working...
                X