238

OpenCore on the Mac Pro | MacRumors Forums

 3 years ago
source link: https://forums.macrumors.com/threads/opencore-on-the-mac-pro.2207814/
Go to the source link to view the article. You can view the picture content, updated content and better typesetting reading experience. If the link is broken, please click the button below to view the snapshot at that time.
OpenCore on the Mac Pro

cdf

macrumors 6502a

Original poster

OpenCore on Legacy Apple Hardware

This guide explains how to use the excellent OpenCore bootloader on a classic Mac Pro to install, run and update macOS Catalina, resulting in a clean, unpatched operating system no different than on a supported Mac.

Why OpenCore?

There are several advantages to using OpenCore on a classic Mac Pro:

Boot picker screen (even with a standard graphics card)

Boot Picker.png
Software Update (just like on a supported Mac)
Software Update.png
Hardware acceleration (and DRM for Netflix on Safari)
Hardware Acceleration.png
Requirements
Mac Pro modelEarly 2009 with MacPro5,1 firmware,* Mid 2010 or Mid 2012Processor architectureWestmere (E56xx, L56xx, X56xx) / Gulftown (W36xx)Boot ROM version144.0.0.0.0*GraphicsCatalina supported GPU**, EFI (flashed) or a standard UEFI card (PC GPU)
* Need to upgrade? See the upgrade instructions.
** Several GPUs that are supported with High Sierra had support removed from Mojave and Catalina, like any non-Kepler generation NVIDIA GPUs or AMD GPUs earlier than HD 7950. Several HD 78xx GPUs (Pitcairn) were rebadged as R9 2xx and are not supported anymore by Mojave/Catalina drivers. All Mac Pro factory GPUs had support removed with Mojave.
PART I
Basic Installation
1 Disk Setup

Prepare two disks as follows:
Disk ADisk B
Newly formatted APFS volume (GUID scheme)​
Existing Mojave installation (with working recovery)​
This is where OpenCore and Catalina will go​
This is where the configuration will take place​
These disks should be the only ones in your Mac. To ensure a bootable fallback, it is recommended that Disk B be a SATA disk in Bay 1.

2 Install OpenCore

You will need:
Download the release version. The uncompressed folder will be referred to as OpenCore.​
The name of the uncompressed file is config.plist.​
The sample configuration is incompatible with any OpenCore version other than the one linked above. Before deviating from this configuration, make sure that you fully understand all the options by going over the manual (see OpenCore/Docs/Configuration.pdf). Seriously, read the manual.
Copy the files to the EFI volume of Disk A
  • Open Terminal
    Terminal.png
  • Find the EFI volume of Disk A by entering: diskutil list
The identifier should be something like diskAs1. Replace the actual identifier in the following step.​
  • Mount the EFI volume by entering: sudo diskutil mount /dev/diskAs1
You may need to authorize this. The volume should mount as /Volumes/EFI and appear as EFI in Finder. In the next step, you will be copying the folder OpenCore/X64/EFI to this volume. Note that the volume may already contain a folder called EFI (which in turn may contain a folder called APPLE). In this case, you can choose to merge the contents of the EFI folder if prompted by macOS.​
  • Copy the folder OpenCore/X64/EFI to the volume /Volumes/EFI
The resulting folder /Volumes/EFI/EFI should include two new folders BOOT and OC (possibly alongside the existing folder APPLE).​
  • Copy config.plist to /Volumes/EFI/EFI/OC
3 First Boot

Reboot into recovery
  • Open Terminal
    Terminal.png
  • Reboot into recovery by entering: sudo nvram "recovery-boot-mode=unused" && sudo reboot recovery
You may need to authorize this. Be patient. Mac Pro boot times can be long, especially when booting into recovery.​
Bless the EFI volume of Disk A and reboot
  • In recovery, open Terminal (see Utilities in the menu bar)
  • Find the EFI volume of Disk A by entering: diskutil list
The identifier should be something like diskAs1. Replace the actual identifier in the following step.​
  • Mount the EFI volume by entering: diskutil mount /dev/diskAs1
  • Bless the volume for booting by entering: bless --mount /Volumes/EFI --setBoot
  • Now shut down your Mac and reset the SMC (unplug the power cord, wait 15 seconds, plug the power cord back in, wait 5 seconds, and then press the power button)
Resetting the SMC ensures that Disk B is seen by OpenCore.​
If you see the simple boot picker, let it timeout to the default selection.​
Check the installation
  • Open Terminal
  • Check that OpenCore has actually booted the system by entering: nvram 4D1FDA02-38C7-4A6A-9CC6-4BCCA8B30102:opencore-version
You should see REL-064-2020-12-07.​
  • Check the VMM flag by entering: sysctl machdep.cpu.features
You should see VMM (among other features).​
🎉 Congratulations for making it this far! The hard part is done.​
4 Install Catalina

You will need: Install Catalina to Disk A
  • Run the installer and select Disk A
The machine will reboot. If you see the simple boot picker, let it timeout to the default selection. Eventually, you should see the installation progress bar.​
  • Complete the installation
And that's it! From now on, OpenCore should boot Catalina on Disk A by default. You can also select the desired system from Startup Disk or the simple boot picker.​
5 Post-Install

Open the configuration file
  • Open Terminal
    Terminal.png
  • Find the EFI volume of Disk A by entering: diskutil list
The identifier should be something like diskAs1. Replace the actual identifier in the following step.​
  • Mount the EFI volume by entering: sudo diskutil mount /dev/diskAs1
You may need to authorize this. The volume should mount as /Volumes/EFI and appear as EFI in Finder.​
  • Navigate to /Volumes/EFI/EFI/OC and copy config.plist to your home folder
    Home Folder.png
  • Open config.plist in your home folder with TextEdit
    TextEdit.png
Toggle the VMM flag
Adding the VMM flag to the CPUID is what enables Software Update and the installation of macOS Catalina. On a classic Mac Pro, adding this flag is only possible with a Westmere processor architecture. Older generations like Nehalem lack the necessary Apple Hypervisor support. Because the VMM flag causes a performance loss (about 5%) and disables power management, it is a good idea to only have the flag ON when installing macOS or checking for updates.​
  • Find Cpuid1Mask and make the appropriate change
ONOFF
AAAAAAAAAAAAAACAAAAAAA==
AAAAAAAAAAAAAAAAAAAAAA==
Disable the special GOP renderer if not needed
For maximum compatibility, the sample configuration enables a special GOP renderer to display the boot picker. This option, which is needed for the Radeon VII and some versions of the 5700 XT but not for the RX 580, can cause undesirable effects (such as slow scrolling) and therefore should be disabled if not needed.​
  • Find DirectGopRendering and change true to false
Customize the boot screen
  • If you have a HiDPI display (retina), find UIScale and change AQ== to Ag==
  • To get a black boot screen (like all supported Macs), find ConsoleAttributes and change 112 to 0 and find DefaultBackgroundColor and change v7+/AA== to AAAAAA==
  • To hide the boot picker find ShowPicker and change true to false
If you've hidden the boot picker, accessing it is easy: Press and hold the Escape (Esc) key immediately after turning on or restarting your Mac. Release the key once the simple boot picker appears—or once the mouse cursor appears if you've enabled the graphical boot picker (see Part II).​
Load the configuration
  • Close config.plist and copy it back to /Volumes/EFI/EFI/OC
  • Reboot
PART II
Advanced Configuration
Enabling Hardware Acceleration

You will need:
Lilu
Download the latest release version. The uncompressed folder contains the file Lilu.kext.​
Download the latest release version. The uncompressed folder contains the file WhateverGreen.kext.​
Only if you have a dual-processor machine. The uncompressed file is called​
AppleMCEReporterDisabler.kext.​
The path of your graphics card
In canonical form, the path is something like PciRoot(0x0)/Pci(0x0,0x0)/Pci(0x0,0x0).​
Copy the files to the kexts folder
  • Open Terminal
    Terminal.png
  • Find the EFI volume of Disk A by entering: diskutil list
The identifier should be something like diskAs1. Replace the actual identifier in the following step.​
  • Mount the EFI volume by entering: sudo diskutil mount /dev/diskAs1
You may need to authorize this. The volume should mount as /Volumes/EFI and appear as EFI in Finder.​
  • Copy Lilu.kext and WhateverGreen.kext and (if you have a dual-processor machine) AppleMCEReporterDisabler.kext to /Volumes/EFI/EFI/OC/Kexts
Open the configuration file
  • Navigate to /Volumes/EFI/EFI/OC and copy config.plist to your home folder
    Home Folder.png
  • Open config.plist in your home folder with TextEdit
    TextEdit.png
Tell OpenCore about the kexts
  • Locate the Kernel key
  • Below it, replace
<key>Add</key>
<array/>
<key>Add</key>
<array>

<dict>
<key>Arch</key>
<string>x86_64</string>
<key>BundlePath</key>
<string>Lilu.kext</string>
<key>Comment</key>
<string>Patch engine</string>
<key>Enabled</key>
<true/>
<key>ExecutablePath</key>
<string>Contents/MacOS/Lilu</string>
<key>MaxKernel</key>
<string></string>
<key>MinKernel</key>
<string></string>
<key>PlistPath</key>
<string>Contents/Info.plist</string>
</dict>

<dict>
<key>Arch</key>
<string>x86_64</string>
<key>BundlePath</key>
<string>WhateverGreen.kext</string>
<key>Comment</key>
<string>Video patches</string>
<key>Enabled</key>
<true/>
<key>ExecutablePath</key>
<string>Contents/MacOS/WhateverGreen</string>
<key>MaxKernel</key>
<string></string>
<key>MinKernel</key>
<string></string>
<key>PlistPath</key>
<string>Contents/Info.plist</string>
</dict>

</array>
Other kexts are configured similarly by adding a dictionary entry to the array.​
  • If you have a dual-processor machine, add
<dict>
<key>Arch</key>
<string>x86_64</string>
<key>BundlePath</key>
<string>AppleMCEReporterDisabler.kext</string>
<key>Comment</key>
<string>Disable AppleMCEReporter</string>
<key>Enabled</key>
<true/>
<key>ExecutablePath</key>
<string></string>
<key>MaxKernel</key>
<string></string>
<key>MinKernel</key>
<string>19.0.0</string>
<key>PlistPath</key>
<string>Contents/Info.plist</string>
</dict>
Add the device properties
  • Find the DeviceProperties key
  • Below it, replace
<key>Add</key>
<dict/>
<key>Add</key>
<dict>

<key>PciRoot(0x0)/Pci(0x0,0x0)/Pci(0x0,0x0)</key>
<dict>
<key>shikigva</key>
<data>UA==</data>
<key>agdpmod</key>
<data>cGlrZXJhAA==</data>
<key>rebuild-device-tree</key>
<data>AA==</data>
</dict>

</dict>
Make sure to replace PciRoot(0x0)/Pci(0x0,0x0)/Pci(0x0,0x0) by the actual path that you noted earlier. Properties for other devices are configured similarly by adding a path key and corresponding dictionary entry to the dictionary.​
Hybridization
iMacPro hybridization, a strategy originally due to @h9826790, is integral to successful hardware acceleration.​
  • Find the SMBIOS key
  • Below it, replace
<dict/>
<dict>
<key>BoardProduct</key>
<string>Mac-7BA5B2D9E42DDD94</string>
</dict>
  • Find UpdateSMBIOS and change false to true
Clean up the NVRAM
  • Find NVRAM and delete
<key>boot-args</key>
<string>-no_compat_check</string>
<string>boot-args</string>
Verify the configuration
  • Close config.plist
  • In Terminal, enter: plutil -convert xml1 config.plist && plutil config.plist
You should see config.plist: OK. If not, recheck all the steps.​
Load the configuration
  • Copy config.plist back to /Volumes/EFI/EFI/OC
  • Reboot
Enabling Night Shift

You will need:
Lilu
Unless you already have it. Download the latest release version. The uncompressed folder contains the file Lilu.kext.​
Download the latest release version. The uncompressed folder contains the file NightShiftEnabler.kext.​
Unfortunately, not all displays support Night Shift.​
Copy the files to the kexts folder
  • Open Terminal
    Terminal.png
  • Find the EFI volume of Disk A by entering: diskutil list
The identifier should be something like diskAs1. Replace the actual identifier in the following step.​
  • Mount the EFI volume by entering: sudo diskutil mount /dev/diskAs1
You may need to authorize this. The volume should mount as /Volumes/EFI and appear as EFI in Finder.​
  • Copy Lilu.kext (unless you already have it) and NightShiftEnabler.kext to /Volumes/EFI/EFI/OC/Kexts
Open the configuration
  • Navigate to /Volumes/EFI/EFI/OC and copy config.plist to your home folder
    Home Folder.png
  • Open config.plist in your home folder with TextEdit
    TextEdit.png
Tell OpenCore about the kexts
  • Locate the Kernel key
  • If this is your first time adding kexts, replace
<key>Add</key>
<array/>
<key>Add</key>
<array>

<dict>
<key>Arch</key>
<string>x86_64</string>
<key>BundlePath</key>
<string>Lilu.kext</string>
<key>Comment</key>
<string>Patch engine</string>
<key>Enabled</key>
<true/>
<key>ExecutablePath</key>
<string>Contents/MacOS/Lilu</string>
<key>MaxKernel</key>
<string></string>
<key>MinKernel</key>
<string></string>
<key>PlistPath</key>
<string>Contents/Info.plist</string>
</dict>

<dict>
<key>Arch</key>
<string>x86_64</string>
<key>BundlePath</key>
<string>NightShiftEnabler.kext</string>
<key>Comment</key>
<string>Enable Night Shift</string>
<key>Enabled</key>
<true/>
<key>ExecutablePath</key>
<string>Contents/MacOS/NightShiftEnabler</string>
<key>MaxKernel</key>
<string></string>
<key>MinKernel</key>
<string></string>
<key>PlistPath</key>
<string>Contents/Info.plist</string>
</dict>

</array>
  • Otherwise, add the NightShiftEnabler dictionary entry to the array
The Lilu dictionary entry must always be first in the array.​
Verify the configuration
  • Close config.plist
  • In Terminal, enter: plutil -convert xml1 config.plist && plutil config.plist
You should see config.plist: OK. If not, recheck all the steps.​
Load the configuration
  • Copy config.plist back to /Volumes/EFI/EFI/OC
  • Reboot
Making External Drives Internal

You will need:
The path of your disk
In canonical form, the path is something like PciRoot(0x0)/Pci(0x0,0x0)/Pci(0x0,0x0).​
Open the configuration file
  • Open Terminal
    Terminal.png
  • Find the EFI volume of Disk A by entering: diskutil list
The identifier should be something like diskAs1. Replace the actual identifier in the following step.​
  • Mount the EFI volume by entering: sudo diskutil mount /dev/diskAs1
You may need to authorize this. The volume should mount as /Volumes/EFI and appear as EFI in Finder.​
  • Navigate to /Volumes/EFI/EFI/OC and copy config.plist to your home folder
    Home Folder.png
  • Open config.plist in your home folder with TextEdit
    TextEdit.png
Add the built-in property
  • Locate the DeviceProperties key
  • If this is your first time adding device properties, replace
<key>Add</key>
<dict/>
<key>Add</key>
<dict>

<key>PciRoot(0x0)/Pci(0x0,0x0)/Pci(0x0,0x0)</key>
<dict>
<key>built-in</key>
<data>AA==</data>
</dict>

</dict>
  • Otherwise, add the path key and dictionary entry to the dictionary
Make sure to replace PciRoot(0x0)/Pci(0x0,0x0)/Pci(0x0,0x0) by the actual path that you noted earlier.​
Verify the configuration
  • Close config.plist
  • In Terminal, enter: plutil -convert xml1 config.plist && plutil config.plist
You should see config.plist: OK. If not, recheck all the steps.​
Load the configuration
  • Copy config.plist back to /Volumes/EFI/EFI/OC
  • Reboot
Enabling the Graphical Boot Picker

You will need:
Download the ZIP (click the code button
Button.png
and select download ZIP). The uncompressed folder will be referred to as OcBinaryData.​
Depicted in the screenshot above, OpenCanopy is the official OpenCore graphical user interface.​
Copy the files to the resources folder
  • Open Terminal
    Terminal.png
  • Find the EFI volume of Disk A by entering: diskutil list
The identifier should be something like diskAs1. Replace the actual identifier in the following step.​
  • Mount the EFI volume by entering: sudo diskutil mount /dev/diskAs1
You may need to authorize this. The volume should mount as /Volumes/EFI and appear as EFI in Finder.​
  • Copy OcBinaryData/Resources to /Volumes/EFI/EFI/OC (overwrite the existing folder)
Open the configuration file
  • Navigate to /Volumes/EFI/EFI/OC and copy config.plist to your home folder
    Home Folder.png
  • Open config.plist in your home folder with TextEdit
    TextEdit.png
Enable OpenCanopy
  • Find PickerMode and change Builtin to External
  • Locate the Drivers key and add
<string>OpenCanopy.efi</string>
to the array​
Verify the configuration
  • Close config.plist
  • In Terminal, enter: plutil -convert xml1 config.plist && plutil config.plist
You should see config.plist: OK. If not, recheck all the steps.​
Load the configuration
  • Copy config.plist back to /Volumes/EFI/EFI/OC
  • Reboot
PART III
Maintenance
Updating Catalina

To update Catalina, simply turn on the VMM flag (see toggle the VMM flag in step 5 of Part I and don't forget to reboot). To manually check for updates, choose Apple menu > System Preferences, then click Software Update.

Updating OpenCore

OpenCore is currently being updated on the first Monday of every month. To update OpenCore, simply repeat steps 2 and 5 of Part I (overwriting /Volumes/EFI/EFI/OC and /Volumes/EFI/EFI/BOOT) and (if applicable) repeat Part II. To facilitate the process, @TECK has developed a nifty script, which you can adapt to your configuration. This tool is especially useful for advanced configurations.

Disabling OpenCore

Open the configuration file
  • Open Terminal
    Terminal.png
  • Find the EFI volume of Disk A by entering: diskutil list
The identifier should be something like diskAs1. Replace the actual identifier in the following step.​
  • Mount the EFI volume by entering: sudo diskutil mount /dev/diskAs1
  • Navigate to /Volumes/EFI/EFI/OC and copy config.plist to your home folder
    Home Folder.png
  • Open config.plist in your home folder with TextEdit
    TextEdit.png
Turn off boot selection routing
  • Find RequestBootVarRouting and change true to false
Load the configuration
  • Close config.plist and copy it back to /Volumes/EFI/EFI/OC
  • Reboot
Select Mojave and reboot
  • Select Mojave in System Preferences > Startup Disk
  • Reboot
You are now booted into Mojave without OpenCore.​
Reenabling OpenCore

Open the configuration file
  • Open Terminal
    Terminal.png
  • Find the EFI volume of Disk A by entering: diskutil list
The identifier should be something like diskAs1. Replace the actual identifier in the following step.​
  • Mount the EFI volume by entering: sudo diskutil mount /dev/diskAs1
  • Navigate to /Volumes/EFI/EFI/OC and copy config.plist to your home folder
    Home Folder.png
  • Open config.plist in your home folder with TextEdit
    TextEdit.png
Turn on boot selection routing
  • Find RequestBootVarRouting and change false to true
Repeat the first-boot steps
See step 3 in Part I.​
Uninstalling OpenCore

Disable OpenCore
Refer to the steps above.​
Delete the files
  • Open Terminal
    Terminal.png
  • Find the EFI volume of Disk A by entering: diskutil list
The identifier should be something like diskAs1. Replace the actual identifier in the following step.​
  • Mount the EFI volume by entering: sudo diskutil mount /dev/diskAs1
You may need to authorize this. The volume should mount as /Volumes/EFI and appear as EFI in Finder.​
  • Delete /Volumes/EFI/EFI/OC and /Volumes/EFI/EFI/BOOT
APPENDIX
Installing Windows 10

You will need:
Double-click the image file. The mounted volume will be referred to as CCCOMA_X64.​
Download the ZIP (click the code button
Button.png
and select download ZIP). The uncompressed folder will be referred to as OcBinaryData.​
The sample configuration includes the required setting to protect the Mac Pro from potential damage caused by UEFI Windows.​
Prepare two disks as follows:
Disk CUSB
Newly formatted exFat volume (GUID scheme)​
Newly formatted exFat volume (MBR scheme)​
This is where Windows will go​
This is where the installer will go​
Disk C should not be the same as Disk A. The volume of the USB disk will be referred to as USB.​
Add the exFat driver
  • Open Terminal
    Terminal.png
  • Find the EFI volume of Disk A by entering: diskutil list
The identifier should be something like diskAs1. Replace the actual identifier in the following step.​
  • Mount the EFI volume by entering: sudo diskutil mount /dev/diskAs1
You may need to authorize this. The volume should mount as /Volumes/EFI and appear as EFI in Finder.​
  • Copy OcBinaryData/Drivers/ExFatDxeLegacy.efi to EFI/OC/Drivers
Open the configuration file
  • Navigate to /Volumes/EFI/EFI/OC and copy config.plist to your home folder
    Home Folder.png
  • Open config.plist in your home folder with TextEdit
    TextEdit.png
Tell OpenCore about the driver
  • Find the Drivers key and add
<string>ExFatDxeLegacy.efi</string>
to the array​
Also, make sure that the VMM flag is off.​
Verify the configuration
  • Close config.plist
  • In Terminal, enter: plutil -convert xml1 config.plist && plutil config.plist
You should see config.plist: OK. If not, recheck all the steps.

Load the configuration
  • Copy config.plist back to /Volumes/EFI/EFI/OC
  • Reboot
Prepare the installer
Use the actual volumes names in the following step:​
  • Enter: rsync -r /Volumes/CCCOMA_X64/ /Volumes/USB
Let the task complete.​
Proceed with the installation
  • Reboot and select Windows (External) from the boot picker
The Windows installer should start.​
  • At the Windows Setup window, press Shift+F10 to open the Command Prompt
  • Start diskpart by entering: diskpart
Wait for the prompt.​
  • Identify your disks by entering: list volume
You should see something like​
Code:
Volume 1    C    Disk C    exFAT
Volume 2    D    USB       exFAT
Note the actual volume numbers and letters. Do not proceed if you are not sure! Replace the actual volume number of Disk C in the following step.​
  • Select Disk C by entering: select volume 1
Double check that you have the right volume number.​
  • Format the disk by entering: format quick fs=ntfs label=Windows
Wait for the task to complete.​
  • Enter: exit
Use the actual letter of the USB drive in the following step:​
  • Enter: D:
  • Backup the efi folder of the installer by entering: ren efi efi.bak
  • Enter: cd sources
  • Identify the version of Windows that you want to install by entering: dism /get-wiminfo /wimfile:install.wim
You should see something like​
Code:
Index : 1
Name : Windows 10 Home
Replace the actual index of the Windows version and the actual letter of Disk C in the following step:​
  • Apply the install image by entering: dism /apply-image /imagefile:install.wim /index:1 /applydir:C:\ /compact /EA
Wait for the task to complete.​
  • Create the boot files by entering:bcdboot C:\Windows /s D: /f uefi
Wait for the task to complete.​
  • Enter: exit
  • Close the Windows Setup window (click the X)
Click "yes" to restart your computer.​
  • Reboot into macOS
Copy the boot files
  • Open Terminal
    Terminal.png
  • Find the EFI volume of Disk C by entering: diskutil list
The identifier should be something like diskCs1. Replace the actual identifier in the following step.​
  • Mount the EFI volume by entering: sudo diskutil mount /dev/diskCs1
You may need to authorize this. The volume should mount as /Volumes/EFI and appear as EFI in Finder. This EFI volume should be empty.​
  • Copy /USB/EFI/Microsoft to /Volumes/EFI/EFI
  • Delete /USB/EFI and rename efi.bak to efi
  • Eject the USB
Finish the installation
  • Reboot and use the boot picker to select Windows
The configuration process should begin and eventually your computer will restart.​
  • Complete the configuration
Acknowledgements

A big thank you to @vit9696 and the other talented developers of Acidanthera for making all of this possible. Special gratitude goes to @h9826790 for spearheading the hardware acceleration study and @startergo for the relentless testing that led to boot screen support. And thanks to all those that have contributed to this thread!

About Joyk


Aggregate valuable and interesting links.
Joyk means Joy of geeK