OK, I’ve been using Opencore Legacy Patcher for a few months now and it has been working well, but the big issue has been updating it and rebooting. There is a step called root patching where the boot drive gets kernel extensions in /Library/Extensions and on reboot these can fail.
I had in the past had to rebuild the entire thing, but thanks to the Discord channel, I discovered this fix which solved the problem. It involves deleting the offending kext that is causing the boot to fail in the middle of the startup bar.
The solution is in a nutshell:
- Boot the system up and have the USB key that you used to install OLCP, this should boot fine assuming that what is happening is that you installed root patches (kernel extensions) on your main disk and these are hanging
- If you are using FileVault 2 (the disk encryption), then go to the Disk Utility and mount the partition called Data. You will see the name of your main disk and then a Data piece, mounting it will require a password (which hopefully you remember, for me, it is the password of my main user account and no, I don’t understand how that user account is associated with the hard disk).
- When you boot it, you will see the Recovery windows, and here is the unintuitive part, choose Utilities > Terminal at the top menu, it is not one of the items in the main part of the screen
- In the terminal, you need to first mount the main hard disk, typically called “Macintosh HD”, but if you rename it use that name with
mount -uw "/Volumes/Machintosh HD
- Now you revert the snapshot of the main drive that didn’t work with
bless --mount "/Volumes/Macintosh HD" --bootefi --last-sealed-snapshot
. I had never heard ofbless
before this, but this writes information to a disk volume saying it is bootable, copiesboot.efi
which is the magic file in a blessed volume that the system reads when it starts into magic location/System/Library/CoreServices/boot.efi
. For non-T2 Macs, this had to be on a special disk/dev/disk1s2
so there is a lot of magic. The –bootefi means work on that special drive and –last-sealed-snapshot means that you are reverting backward as you can have different versions of what is on that drive. - Now comes the magic,
/Volumes/Macintosh HD/Library/Extensions
and you have to delete all the kext files except forHighPoint*
and SoftRAID.kext - Now restart and it should work
Reminder on MacOS boot commands
The big thing to remember all all the magic keys for rebooting which are for Intel Macs:
- Reset the PRAM. Command-Option-P-R for Intel Macs resets the boot options.
- Command-R puts you into recovery mode
- Command-S puts you into single-user mode where you get just a command line window
- Option key to get the Startup manager so you can pick which boot drive (for instance if you have a USB key that is bootable)
- Shift key put you into safe mode where you can diagnose things
- D. Puts you into the diagnostic utility
- T. For those macs that support it, turns the entire Mac into a hard drive, so at least you get things out
- Ctrl-V. Verbose mode to try to figure out where things are handing
Apple silicon Macs have far fewer things, basically one, when you boot, hold down the power button while it is booting and it will give you startup options and other options under the gear icon (and from there get to Recovery mode, etc.)
Still have problems with MacBook Pro 2014 even after dGPU disabled
OK, here is another strange thing, I’ve been trying to make my MacBook Pro 2014 with an Intel Pro and an nVidia 750 discrete GPU. From work on my MacBook Pro 2010, I know there is a nvram command that disables the dGPU
However, when I run this command on my MacBook Pro 2014 with Crystal Well, instead I disable the integrated GPU (which is pretty weird). Safari and Photos still don’t work so Metal emulation is broken and the graphics on the Mac are not enabled when I plug a screen in. Net, net, I think that options must be reversed on this machine. Sigh. I set it to %01 to disable it seems to be reversed on 2014, it is hard to say because I found but can’t find anymore what the magic parameters had what do any of these fields mean?
It does look like getting both graphics card again is done by setting this magic to zero:
nvram fa4ce28d-b62f-4c99-9cc3-6815686e30f9:gpu-power-prefs=%00%00%00%00
The other thing is to just reset the PRAM and there is a rumor that sudo pmset -b gpuswitch 2
works
What the heck is nvram?
It stands for nonvolatile RAM where key parameters are kept and where you can:
nvram -
p this print out all the nvram parametersnvram -c
clears all the parametersnvram -d _variable name
will delete a variablenvram _variable_=_value_
to set a value