|
| 1 | +# macOS Unlocker V4 for VMware ESXi |
| 2 | + |
| 3 | +Original repositories: [DrDonk](https://github.com/DrDonk)/**[esxi-unlocker](https://github.com/DrDonk/esxi-unlocker)** |
| 4 | + |
| 5 | +(c) 2011-2022 David Parsons |
| 6 | + |
| 7 | +## Download ESXi 8.0 (integrated Unlocker & OEM BIOS) |
| 8 | + |
| 9 | +Powered by [sysin.org](https://sysin.org/) |
| 10 | + |
| 11 | +- [VMware ESXi 8.0 Unlocker standard & Custom Image](https://sysin.org/blog/vmware-esxi-8-oem/) |
| 12 | +- [VMware ESXi 8.0 Unlocker with driver](https://sysin.org/blog/vmware-esxi-8-sysin/) |
| 13 | + |
| 14 | +## Download ESXi 7.0 (integrated Unlocker & OEM BIOS) |
| 15 | + |
| 16 | +- [VMware ESXi 7.0 U3 & Unlocker standard & Custom Image](https://sysin.org/blog/vmware-esxi-7-u3-oem/) |
| 17 | +- [VMware ESXi 7.0 U3 & Unlocker with driver](https://sysin.org/blog/vmware-esxi-7-u3-nuc-usb-nvme/) |
| 18 | +- [VMware ESXi 7.0 U2 & Unlocker standard & Custom Image](https://sysin.org/blog/vmware-esxi-7-u2-oem/) |
| 19 | +- [VMware ESXi 7.0 U2 & Unlocker with driver](https://sysin.org/blog/vmware-esxi-7-u2-nuc-usb-nvme/) |
| 20 | +- [VMware ESXi 7.0 U1 Unlocker standard & Custom Image](https://sysin.org/blog/vmware-esxi-7-u1-oem/) |
| 21 | +- [VMware ESXi 7.0 Unlocker standard & Custom Image](https://sysin.org/blog/vmware-esxi-7-ome/) |
| 22 | + |
| 23 | +--- |
| 24 | + |
| 25 | +**IMPORTANT PLEASE READ!** |
| 26 | + |
| 27 | +## macOS Ventura Guests |
| 28 | + |
| 29 | +There are a known issues that Ventura guests boot loop in VMware Workstation. The situation after extensive testing is: |
| 30 | + |
| 31 | +1. Intel pre-Haswell CPUs dropped by Apple in Ventura - no way to patch need to look at OCLP |
| 32 | +2. AMD CPUs n o longer work in Ventura possibly due to how CPUID leaf 4 is read - no way to patch need to look at OpenCore and other solutions |
| 33 | +3. Intel Haswell+ CPUS, which are supported, make sure you set |
| 34 | + |
| 35 | +`ethernet0.virtualDev = "e1000e` |
| 36 | + |
| 37 | +to |
| 38 | + |
| 39 | +`ethernet0.virtualDev = "vmxnet3"` |
| 40 | + |
| 41 | +<https://github.com/DrDonk/unlocker/issues/47> |
| 42 | + |
| 43 | +Please do not upgrade to Ventura at this time if you have AMD or Intel pre-Haswell CPUs. |
| 44 | + |
| 45 | +VMware will stop supporting new macOS versions as guests starting with Fusion 13 and the next version of ESXi. |
| 46 | + |
| 47 | +This is documented at the VMware KB for Fusion: |
| 48 | +<https://kb.vmware.com/s/article/88697> |
| 49 | + |
| 50 | +And for ESXi: |
| 51 | +<https://kb.vmware.com/s/article/88698> |
| 52 | + |
| 53 | +This will likely impact Workstation Pro/Player as well. Currently the exact details of what may change are not clear, but |
| 54 | +it is safe to say we should look for alternative approaches to the unlocker. |
| 55 | + |
| 56 | +## Upgrading ESXi 8 |
| 57 | + |
| 58 | +There is an issue with ESXi 8 which stops macOS from booting and is probably related to the news that VMware nolonger support macOS as host and guest |
| 59 | +for ESXi8. The workaround is to keep existing VMs as 7U2 variants and create new ones as ESXi 7 U2 VMs. This can be done in the dialogs when creating a new VM. |
| 60 | + |
| 61 | +--- |
| 62 | + |
| 63 | +## 1. Introduction |
| 64 | + |
| 65 | +Unlocker 4 is designed for VMware ESXi 7. |
| 66 | + |
| 67 | +The Unlocker enables certain flags and data tables that are required to see the macOS type when setting |
| 68 | +the guest OS type, and modify the implmentation of the virtual SMC controller device. These capabiltiites are normally |
| 69 | +exposed in Fusion and ESXi when running on Apple hardware. |
| 70 | + |
| 71 | +The patch code carries out the following modifications dependent on the product being patched: |
| 72 | + |
| 73 | +- Patch vmx and derivatives to allow macOS to boot |
| 74 | +- Patch libvmkctl.so to allow vCenter to boot macOS guests |
| 75 | + |
| 76 | +It is important to understand that the Unlocker cannot add any new capabilities to VMware ESXi |
| 77 | +but enables support for macOS that is disabled in the VMware products when run on non-Apple hardware. |
| 78 | + |
| 79 | +The Unlocker cannot: |
| 80 | + |
| 81 | +- add support for new versions of macOS |
| 82 | +- add paravirtualized Apple GPU support |
| 83 | +- add older (non-Ryzen) AMD CPU support |
| 84 | + |
| 85 | +or any other features that are not already in the VMware compiled code. |
| 86 | + |
| 87 | +## 2. Running the patcher |
| 88 | + |
| 89 | +**The ESXi unlocker will need to be run each time the ESXi Server is upgraded**. |
| 90 | + |
| 91 | +**It is also best to switch ESXi to Maintanence mode and make sure you do not have any VMs running**. |
| 92 | + |
| 93 | +The code is written in Python and has no pre-requisites and should run directly from the release zip download. |
| 94 | + |
| 95 | +- Download a binary release from <https://github.com/DrDonk/esxi-unlocker/releases> |
| 96 | +- Unload the archive to a folder on the ESXi server datastore and extract the files |
| 97 | +- Navigate to the folder with the extracted files |
| 98 | + |
| 99 | +You will then need to run one of the following commands to patch or unpatch the ESXi software. |
| 100 | + |
| 101 | +- unlock - apply patches to VMware ESXi |
| 102 | +- relock - remove patches from VMware ESXi |
| 103 | +- check - check the patch status of your VMware installation |
| 104 | + |
| 105 | +## 3. FAQS |
| 106 | + |
| 107 | +### 3.1 Remove older versions of ESXi unlocker |
| 108 | + |
| 109 | +If you hve previously used an earlier version of the ESXi Unlocker please uninstall it by logging into the |
| 110 | +support console and running: |
| 111 | + |
| 112 | +```BootModuleConfig.sh --verbose --remove=unlocker.tgz``` |
| 113 | + |
| 114 | +and then rebooting the ESXi server. |
| 115 | + |
| 116 | +### 3.2 AMD CPUs |
| 117 | + |
| 118 | +A patched macOS AMD kernel must be used to run on older AMD systems, but there is a workaround if you have a modern |
| 119 | +AMD Ryzen CPU. The unlocker cannot patch this but we can recommend settings for the VMX file that allows macOS to |
| 120 | +run on recent AMD CPUs. The tests are being recorded in this issue, and it would be useful if more can report |
| 121 | +success or failures in that issue. |
| 122 | + |
| 123 | +<https://github.com/DrDonk/unlocker/issues/33> |
| 124 | + |
| 125 | +1. Read this KB article to learn how to edit a guest's VMX file safely <https://kb.vmware.com/s/article/2057902> |
| 126 | + |
| 127 | +2. Add the following lines were to the VMX file: |
| 128 | + |
| 129 | + ```txt |
| 130 | + cpuid.0.eax = "0000:0000:0000:0000:0000:0000:0000:1011" |
| 131 | + cpuid.0.ebx = "0111:0101:0110:1110:0110:0101:0100:0111" |
| 132 | + cpuid.0.ecx = "0110:1100:0110:0101:0111:0100:0110:1110" |
| 133 | + cpuid.0.edx = "0100:1001:0110:0101:0110:1110:0110:1001" |
| 134 | + cpuid.1.eax = "0000:0000:0000:0001:0000:0110:0111:0001" |
| 135 | + cpuid.1.ebx = "0000:0010:0000:0001:0000:1000:0000:0000" |
| 136 | + cpuid.1.ecx = "1000:0010:1001:1000:0010:0010:0000:0011" |
| 137 | + cpuid.1.edx = "0000:0111:1000:1011:1111:1011:1111:1111" |
| 138 | + vhv.enable = "FALSE" |
| 139 | + vpmc.enable = "FALSE" |
| 140 | + ``` |
| 141 | + |
| 142 | +3. Make sure there are no duplicate lines in the VMX file or the guest will not start and a dictionary error will be displayed by VMware. |
| 143 | + |
| 144 | +4. You can now install and run macOS as a guest. |
| 145 | + |
| 146 | +## 4. Thanks |
| 147 | + |
| 148 | +Thanks to Zenith432 for originally building the C++ Unlocker and Mac Son of Knife |
| 149 | +(MSoK) for all the testing and support. |
| 150 | + |
| 151 | +Thanks also to Sam B for finding the solution for ESXi 6 and helping me with |
| 152 | +debugging expertise. Sam also wrote the code for patching ESXi ELF files and |
| 153 | +modified the Unlocker code to run on Python 3 in the ESXi 6.5 environment. |
| 154 | + |
| 155 | +Thanks to lucaskamp for testing the new version 4 of ESXi Unlocker. |
| 156 | + |
| 157 | +(c) 2011-2023 David Parsons |
0 commit comments