Compare commits
360 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
32dc71708c | ||
|
|
54a7e6811c | ||
|
|
dc02b6919f | ||
|
|
461953bc59 | ||
|
|
48f33a76d8 | ||
|
|
861f02bb98 | ||
|
|
9d3ae02c5c | ||
|
|
d8aaca529d | ||
|
|
ce3ee4c410 | ||
|
|
0d5f89aa2d | ||
|
|
5a9c88f0e1 | ||
|
|
1ce5c9319f | ||
|
|
90d177dbae | ||
|
|
c95e56618e | ||
|
|
f50240419d | ||
|
|
02dfe34e00 | ||
|
|
d7ae27ce68 | ||
|
|
b82cd52a2b | ||
|
|
11e9278355 | ||
|
|
7d6a8b03d1 | ||
|
|
2d8c227a50 | ||
|
|
0ded89a78a | ||
|
|
d8fe2f6ed2 | ||
|
|
81eb59053c | ||
|
|
a789a78410 | ||
|
|
9099277a2d | ||
|
|
8968e1028d | ||
|
|
45bf3a436a | ||
|
|
62e5f47ba9 | ||
|
|
269bf572a4 | ||
|
|
3b4c81ad2a | ||
|
|
9b360e729b | ||
|
|
ecedb55013 | ||
|
|
ab2f94ba48 | ||
|
|
cb806b70f2 | ||
|
|
81554d0524 | ||
|
|
7ebe80626c | ||
|
|
c679e65d34 | ||
|
|
1c28c6c987 | ||
|
|
08e99e81f1 | ||
|
|
011c2236ad | ||
|
|
e330d03816 | ||
|
|
17aa03f4f4 | ||
|
|
41d91402b7 | ||
|
|
ec58e4e0e9 | ||
|
|
40519182cc | ||
|
|
0030b4afab | ||
|
|
07b379fa58 | ||
|
|
7c97b324bb | ||
|
|
93108f410b | ||
|
|
c472a08622 | ||
|
|
1e21924404 | ||
|
|
97418578fd | ||
|
|
473a72b76c | ||
|
|
c8bba73989 | ||
|
|
b225de4cd1 | ||
|
|
0855b1ea50 | ||
|
|
28e75d5431 | ||
|
|
ff848c7301 | ||
|
|
49e0a09f05 | ||
|
|
c504fb04d5 | ||
|
|
b47fbd977e | ||
|
|
af1c8d71c9 | ||
|
|
3e8dae1919 | ||
|
|
d405dbe937 | ||
|
|
7b03389f78 | ||
|
|
f3e1346d6a | ||
|
|
d9a7d03734 | ||
|
|
45709367fe | ||
|
|
88e625d952 | ||
|
|
033e3670cf | ||
|
|
240ba08c0d | ||
|
|
ffa4f9006d | ||
|
|
65cca7fb3d | ||
|
|
80908ff743 | ||
|
|
cb902fcf82 | ||
|
|
9fdbe665e7 | ||
|
|
3ee28be973 | ||
|
|
b6ba0fd2ae | ||
|
|
366c93a7c4 | ||
|
|
a942be2ab0 | ||
|
|
cce2480d8d | ||
|
|
bcd07f5ab8 | ||
|
|
51c272deb5 | ||
|
|
5f13e2a80e | ||
|
|
e8d60db435 | ||
|
|
69c6bb56c7 | ||
|
|
f5399bc461 | ||
|
|
f7f3a60cbe | ||
|
|
004199ef8f | ||
|
|
eb4f3baadf | ||
|
|
a07cf3b1b9 | ||
|
|
b177b0e760 | ||
|
|
2823307867 | ||
|
|
a2e19dc6c8 | ||
|
|
aa8764db18 | ||
|
|
e1fd1988fc | ||
|
|
1c2c66532c | ||
|
|
7e0ccd863c | ||
|
|
d0f1dd7a9f | ||
|
|
e44e8a32ce | ||
|
|
da2c6f8512 | ||
|
|
5c181695aa | ||
|
|
d6ff74e574 | ||
|
|
75ed8071f0 | ||
|
|
1e4bf5d150 | ||
|
|
a83e5de9c1 | ||
|
|
261b2bb61e | ||
|
|
7e67c3b653 | ||
|
|
3b252ba272 | ||
|
|
94e8f98c59 | ||
|
|
443a781dba | ||
|
|
0b5119ebda | ||
|
|
d3b39d03e6 | ||
|
|
4654b7b7e7 | ||
|
|
af8c16b8ee | ||
|
|
238af06c80 | ||
|
|
1b8af3de11 | ||
|
|
e277c02361 | ||
|
|
825a581033 | ||
|
|
086e498fc8 | ||
|
|
88d761ba66 | ||
|
|
c7ffb48e8e | ||
|
|
e9673b679b | ||
|
|
9fa7e4ad03 | ||
|
|
df393ec711 | ||
|
|
6cad9b4bdb | ||
|
|
81feeb484e | ||
|
|
083bde45c4 | ||
|
|
e7459198f1 | ||
|
|
c832e0fd50 | ||
|
|
a35fd0d398 | ||
|
|
38a2750e91 | ||
|
|
e6e9786c6a | ||
|
|
a50857fa04 | ||
|
|
89b15410f7 | ||
|
|
e6d8d1f9d3 | ||
|
|
6a9d1a22bd | ||
|
|
26961f842e | ||
|
|
9ae37b9c58 | ||
|
|
495dd56014 | ||
|
|
4eb25f3bf1 | ||
|
|
02aa945f77 | ||
|
|
4146e863bf | ||
|
|
97fb738d56 | ||
|
|
4b02d4e907 | ||
|
|
5b54cdc38b | ||
|
|
c4f5b05422 | ||
|
|
a089359d14 | ||
|
|
899c27905f | ||
|
|
701c44854d | ||
|
|
ee39fc7bc3 | ||
|
|
9a207f2619 | ||
|
|
636bae86c8 | ||
|
|
7bae5bf1a4 | ||
|
|
11af9b2e9a | ||
|
|
614d1b490e | ||
|
|
00d788cd14 | ||
|
|
b000b49946 | ||
|
|
5fa840343b | ||
|
|
61f8fccd49 | ||
|
|
5883b7da96 | ||
|
|
dc2477337c | ||
|
|
71696b2489 | ||
|
|
ec273047a7 | ||
|
|
1eed1f1b1e | ||
|
|
78d7353d42 | ||
|
|
89b20ce67f | ||
|
|
39856fa0c4 | ||
|
|
f02283efa7 | ||
|
|
a453685a7f | ||
|
|
df1a53e8de | ||
|
|
0661ce2252 | ||
|
|
e40fbffcb4 | ||
|
|
582e19d08a | ||
|
|
56cce9074a | ||
|
|
9143ff173a | ||
|
|
bdbfbacf25 | ||
|
|
81919b7a31 | ||
|
|
f93ed7f11c | ||
|
|
39ab5efa1b | ||
|
|
2f478258ac | ||
|
|
9053ac4b59 | ||
|
|
887b495451 | ||
|
|
44a21f7aa5 | ||
|
|
9ebde4207a | ||
|
|
1dd79acd7c | ||
|
|
5f715121c3 | ||
|
|
40f63146ea | ||
|
|
3a9edfa2b6 | ||
|
|
73e7af7841 | ||
|
|
896cfba50f | ||
|
|
1840a08498 | ||
|
|
bf26386b9c | ||
|
|
c2a8a359a7 | ||
|
|
b9c351ef3f | ||
|
|
072c5b1408 | ||
|
|
159f2362e9 | ||
|
|
371b8765f1 | ||
|
|
a0355f6d29 | ||
|
|
c1a11d409a | ||
|
|
df20843337 | ||
|
|
1891334f3b | ||
|
|
d3f29d9e33 | ||
|
|
afe2c1e81d | ||
|
|
6a78b3fc32 | ||
|
|
f3bdc7bd93 | ||
|
|
0f0648301a | ||
|
|
6fe47defab | ||
|
|
8663ef8a66 | ||
|
|
6d19d11714 | ||
|
|
9c46566b6c | ||
|
|
ad25c5c155 | ||
|
|
dd4676ed31 | ||
|
|
e3765cc53a | ||
|
|
d731f6fcc9 | ||
|
|
6429a0a2aa | ||
|
|
99b4c73fd8 | ||
|
|
9dfc77f2fd | ||
|
|
9f286192f6 | ||
|
|
13cde82df1 | ||
|
|
bcd9392d60 | ||
|
|
a183b86aa9 | ||
|
|
add5dbd945 | ||
|
|
87158a720d | ||
|
|
cdd1893a31 | ||
|
|
20267826cf | ||
|
|
82d53cfb32 | ||
|
|
a97db97dc4 | ||
|
|
fbb4dbe77d | ||
|
|
b5e79504c8 | ||
|
|
20c39f4ebe | ||
|
|
7a928fa9b9 | ||
|
|
0bb753c392 | ||
|
|
f31c8f1484 | ||
|
|
86acfc7998 | ||
|
|
b8278f505f | ||
|
|
b28b121fc2 | ||
|
|
2e6166edc7 | ||
|
|
08af5a567d | ||
|
|
c0dda851d1 | ||
|
|
13e8a8d2ff | ||
|
|
04bac058e2 | ||
|
|
7a30a91947 | ||
|
|
447bb851fc | ||
|
|
f671b350d9 | ||
|
|
001ad54e92 | ||
|
|
cfa76a8655 | ||
|
|
e0089ea684 | ||
|
|
88147ea6af | ||
|
|
e61156b1c5 | ||
|
|
350838e0b0 | ||
|
|
7968d11493 | ||
|
|
d51e310e7e | ||
|
|
98541ebf12 | ||
|
|
9fd339fdf6 | ||
|
|
f6c6b8d8cc | ||
|
|
86a4c65853 | ||
|
|
3810159f05 | ||
|
|
bd57143dc7 | ||
|
|
6743e838a8 | ||
|
|
d29a2b0811 | ||
|
|
bdbba666f5 | ||
|
|
0e79e08900 | ||
|
|
c414f9cb95 | ||
|
|
d027250a35 | ||
|
|
7fcf1ec9a5 | ||
|
|
c4208f771e | ||
|
|
852ef63bf8 | ||
|
|
54ed5dc3b7 | ||
|
|
6397460b35 | ||
|
|
dba08098f2 | ||
|
|
a8744bc337 | ||
|
|
647b0b7931 | ||
|
|
c3a3cec6a9 | ||
|
|
28e20f140b | ||
|
|
cd021ca6b9 | ||
|
|
3f56594242 | ||
|
|
0d1dda866a | ||
|
|
0525b09e83 | ||
|
|
856d0dbedc | ||
|
|
36fd9c0ea6 | ||
|
|
ff5ceaac8d | ||
|
|
91a2cf2ef9 | ||
|
|
e4caea9ae9 | ||
|
|
0ace086a21 | ||
|
|
c42c2e6e51 | ||
|
|
ca347878ba | ||
|
|
f0edf53fbc | ||
|
|
ac3a9fa686 | ||
|
|
d26eea2082 | ||
|
|
0ac0f4ba47 | ||
|
|
fae435f810 | ||
|
|
ed7e529e2c | ||
|
|
4459af9ad2 | ||
|
|
93e3e19828 | ||
|
|
832c161a17 | ||
|
|
3e76b46481 | ||
|
|
188d14fcbd | ||
|
|
1414395c77 | ||
|
|
dccaf672b0 | ||
|
|
d36132b0a3 | ||
|
|
4c3db4b3f6 | ||
|
|
e92563bc4d | ||
|
|
35a71eda27 | ||
|
|
d891fd5796 | ||
|
|
e17df50b5c | ||
|
|
f53000c868 | ||
|
|
9c27d8569c | ||
|
|
d56f6926ea | ||
|
|
50176ca7de | ||
|
|
a320651a5f | ||
|
|
840978e184 | ||
|
|
1662f3e5bf | ||
|
|
d60d79fc0a | ||
|
|
0783988901 | ||
|
|
f9a4785b60 | ||
|
|
066825aaf4 | ||
|
|
bc4e16d39c | ||
|
|
177b3601a8 | ||
|
|
e7cd4d8a86 | ||
|
|
80683beb31 | ||
|
|
0751b50f05 | ||
|
|
92f3c05e06 | ||
|
|
8d9a01722b | ||
|
|
546d76e0cc | ||
|
|
9f90783344 | ||
|
|
c96428608a | ||
|
|
847823d3c5 | ||
|
|
12e856a4ae | ||
|
|
016de93402 | ||
|
|
94732237f4 | ||
|
|
f23037c2e0 | ||
|
|
df210377f8 | ||
|
|
308e3aed51 | ||
|
|
aaf7ec03c4 | ||
|
|
0843118996 | ||
|
|
7698e582b7 | ||
|
|
aff95aa72d | ||
|
|
ff5f0620a9 | ||
|
|
4bc8c21ce0 | ||
|
|
d51caa6074 | ||
|
|
4d232e7775 | ||
|
|
13fecd45a7 | ||
|
|
be755222ef | ||
|
|
1924198bb1 | ||
|
|
930bb90901 | ||
|
|
26ba1fb9ac | ||
|
|
da5b1a5e20 | ||
|
|
47aae90046 | ||
|
|
9837a67b09 | ||
|
|
c7c70fe9b3 | ||
|
|
41c25d758c | ||
|
|
0a055e7791 | ||
|
|
fa7902ae09 | ||
|
|
569ffa963a | ||
|
|
2a4845b706 | ||
|
|
08f356f252 | ||
|
|
ef8d2abdac | ||
|
|
245f532572 |
@@ -1,34 +1,87 @@
|
|||||||
## Semi-automatic installer of macOS on VirtualBox
|
|
||||||
|
|
||||||
### Supports macOS Mojave (10.14) and High Sierra (10.13)
|

|
||||||
### macOS Catalina 10.15.2 fails to boot on VirtualBox as of the date of its release. Earlier versions of Catalina work, but they are not currently being distributed by Apple's software update servers, from which the script fetches the installer.
|
|
||||||
|
|
||||||
The script is semi-automatic and requires a little user interaction. Most of the time the user simply has to press enter. There is one step where the user has to choose between [C]atalina, [M]ojave, or [H]igh Sierra, and a couple of instances where the user has to choose whether to delete or keep temporary files and previous installations.
|
## Push-button installer of macOS on VirtualBox
|
||||||
|
|
||||||
The goal of the script is to allow for a very easy installation without any closed-source additions or extra bootloaders.
|
[`macos-guest-virtualbox.sh`](https://raw.githubusercontent.com/myspaghetti/macos-guest-virtualbox/master/macos-guest-virtualbox.sh) is a Bash script that creates a macOS virtual machine guest on VirtualBox with unmodified macOS installation files downloaded directly from Apple servers.
|
||||||
|
|
||||||
Tested on Cygwin. Works on macOS and WSL, should work on most Linux distros.
|
A default install only requires the user to sit patiently and, less than ten times, press enter when prompted by the script, without interacting with the virtual machine.
|
||||||
|
|
||||||
## iCloud and iMessage connectivity
|
Tested on `bash` and `zsh` on [Cygwin](https://cygwin.com/install.html). Works on macOS, CentOS 7, and Windows. Should work on most modern Linux distros.
|
||||||
### Due to VirtualBox 6.1 NVRAM issues, iCloud and iMessage connectivity is not available on VirtualBox 6.1 as of the date of its release. Please use VirtualBox 6.0 instead.
|
|
||||||
|
|
||||||
iCloud, iMessage, and other connected Apple services require a valid device name and serial number, board ID and serial number, and other genuine (or genuine-like) Apple parameters. These parameters may be set in the script before installation, or set after installation and applied with `./macos-guest-virtualbox.sh configure_vm`
|
macOS Catalina (10.15), Mojave (10.14), and High Sierra (10.13) currently supported.
|
||||||
|
|
||||||
|
## Documentation
|
||||||
|
|
||||||
|
Documentation can be viewed by executing the command `./macos-guest-virtualbox.sh documentation`
|
||||||
|
|
||||||
|
The majority of the script is either documentation, comments, or actionable error messages, which should make the script straightforward to inspect and understand.
|
||||||
|
|
||||||
|
## iCloud and iMessage connectivity and NVRAM
|
||||||
|
|
||||||
|
iCloud, iMessage, and other connected Apple services require a valid device name and serial number, board ID and serial number, and other genuine (or genuine-like) Apple parameters. These can be set in EFI and NVRAM by editing the script. See the [documentation command](#documentation) for further information.
|
||||||
|
|
||||||
## Storage size
|
## Storage size
|
||||||
|
|
||||||
The script by default assigns a target virtual disk storage size of 80GB, which is populated to about 15GB on the host on initial installation. After the installation is complete, the storage size may be increased. First increase the virtual disk image size through VirtualBox Manager or `VBoxManage`, then in Terminal in the virtual machine run `sudo diskutil repairDisk disk0`, and then `sudo diskutil apfs resizeContainer disk1 0` or from Disk Utility, after repairing the disk from Terminal, delete the "Free space" partition so it allows the system APFS container to take up the available space.
|
The script by default assigns a target virtual disk storage size of 80GB, which is populated to about 25GB on the host on initial installation. After the installation is complete, the storage size may be increased. See the [documentation command](#documentation) for further information.
|
||||||
|
|
||||||
## Performance and unsupported features
|
## Primary display resolution
|
||||||
|
|
||||||
Developing and maintaining VirtualBox or macOS features is beyond the scope of this script. Some features may behave unexpectedly, such as USB device support, audio support, and other features.
|
The following primary display resolutions are supported by macOS on VirtualBox: `5120x2880` `2880x1800` `2560x1600` `2560x1440` `1920x1200` `1600x1200` `1680x1050` `1440x900` `1280x800` `1024x768` `640x480`. See the [documentation command](#documentation) for further information.
|
||||||
|
|
||||||
|
## Unsupported features
|
||||||
|
|
||||||
|
Developing and maintaining VirtualBox or macOS features is beyond the scope of this script. Some features may behave unexpectedly, such as USB device support, audio support, FileVault boot password prompt support, and other features.
|
||||||
|
|
||||||
|
### CPU compatibility
|
||||||
|
|
||||||
|
macOS guests on VirtualBox are incompatible with some CPU models. If the guest macOS boot process hangs on “LoadKernelFromStream”, “EndRandomSeed”, or "EXITBS", see the [documentation command](#documentation) regarding VirtualBox CPU profiles and [CPUID settings](https://www.virtualbox.org/manual/ch08.html#vboxmanage-modifyvm-teleport). Some CPU models released in 2020 and later may fail to start or complete the installer, and may require manually adjusting the CPUID settings.
|
||||||
|
|
||||||
|
### Upgrading to Big Sur and Monterey
|
||||||
|
|
||||||
|
The virtual machine may be upgraded to the latest macOS Big Sur (11) and macOS Monterey (12) versions through Software Update. Big Sur may be installed in-place. Monterey may require attaching another volume to the virtual machine and selecting the volume as the installation target, otherwise the upgrade is prone to failing and entering a boot loop.
|
||||||
|
|
||||||
|
### Performance and deployment
|
||||||
|
|
||||||
|
After successfully creating a working macOS virtual machine, consider importing it into more performant virtualization software, or packaging it for configuration management platforms for automated deployment. These virtualization and deployment applications require additional configuration that is beyond the scope of the script.
|
||||||
|
|
||||||
|
QEMU with KVM is capable of providing virtual machine hardware passthrough for near-native performance. QEMU supports the `VMDK` virtual disk image storage format, which can be configured to be created by the script. See the [documentation command](#documentation) for further information. QEMU and KVM require additional configuration that is beyond the scope of the script.
|
||||||
|
|
||||||
|
#### VirtualBox Native Execution Manager (NEM)
|
||||||
|
|
||||||
|
The VirtualBox Native Execution Manager (NEM) is an experimental VirtualBox feature. [VirtualBox uses NEM when access to VT-x and AMD-V is blocked by virtualization software or execution protection features such as Hyper-V, WSL2, WSLg, Windows Sandbox, memory integrity protection, Application Guard, Credential Guard, Device Guard, and other features and software.](https://docs.microsoft.com/en-us/troubleshoot/windows-client/application-management/virtualization-apps-not-work-with-hyper-v) macOS and the macOS installer have memory corruption issues under NEM virtualization. The script checks for NEM and exits with an error message if it is detected.
|
||||||
|
|
||||||
|
[VirtualBox can run on WSL2 and WSLg with some kernel module compilation](https://github.com/myspaghetti/macos-virtualbox/issues/525), though performance is extremely low. At the point that kernel module compilation is required, it may be preferable to use QEMU/KVM on WSL2 and WSLg, which is orders of magnitude faster than VirtualBox on WSL2 and WSLg. WSL2, WSLg, QEMU, and KVM require additional configuration that is beyond the scope of the script.
|
||||||
|
|
||||||
|
### Bootloaders
|
||||||
|
|
||||||
|
The macOS VirtualBox guest is loaded without extra bootloaders, but it is compatible with [OpenCore](https://github.com/acidanthera/OpenCorePkg/releases). OpenCore requires additional configuration that is beyond the scope of the script.
|
||||||
|
|
||||||
|
### Audio
|
||||||
|
|
||||||
|
macOS may not support any built-in VirtualBox audio controllers. The bootloader [OpenCore](https://github.com/acidanthera/OpenCorePkg/releases) may be able to load open-source or built-in audio drivers in VirtualBox, providing the configuration for STAC9221 (Intel HD Audio) or SigmaTel STAC9700,83,84 (ICH AC97) is available.
|
||||||
|
|
||||||
|
### Display scaling
|
||||||
|
|
||||||
|
VirtualBox does not supply an EDID for its virtual display, and macOS does not enable display scaling (high PPI) without an EDID. The bootloader OpenCore can [inject an EDID](https://github.com/acidanthera/WhateverGreen/blob/master/Manual/FAQ.IntelHD.en.md#edid) which enables display scaling.
|
||||||
|
|
||||||
|
### FileVault
|
||||||
|
|
||||||
|
The VirtualBox EFI implementation does not properly load the FileVault full disk encryption password prompt upon boot. The bootloader [OpenCore](https://github.com/acidanthera/OpenCorePkg/releases/tag/0.6.9) is able to load the password prompt with the parameter `ProvideConsoleGop` set to `true`. See sample [config.plist](https://github.com/myspaghetti/macos-virtualbox/files/6600860/config.plist.txt)
|
||||||
|
|
||||||
After successfully creating a working macOS virtual machine, consider importing it into QEMU/KVM so it can run with hardware passthrough at near-native performance. QEMU/KVM requires additional configuration that is beyond the scope of the script.
|
|
||||||
|
|
||||||
## Dependencies
|
## Dependencies
|
||||||
|
|
||||||
* [VirtualBox](https://www.virtualbox.org/wiki/Downloads)≥6.0 with Extension Pack
|
The following dependencies should be available through a package manager:
|
||||||
* `Bash`≥4.3 (GNU variant; run on Windows through [Cygwin](https://cygwin.com/install.html) or WSL)
|
`bash` `coreutils` `gzip` `unzip` `wget` `xxd` `dmg2img` `virtualbox`
|
||||||
* `coreutils` (GNU variant; install through package manager)
|
|
||||||
* `unzip` (install through package manager)
|
The following optional packages provide optical character recognition that reduces the required interaction with the script:
|
||||||
* `wget` (install through package manager)
|
`tesseract-ocr` `tesseract-ocr-eng`
|
||||||
* `dmg2img` (install through package manager on Linux, macOS, or WSL; let the script download it automatically on Cygwin)
|
|
||||||
|
Supported versions:
|
||||||
|
|
||||||
|
* [VirtualBox](https://www.virtualbox.org/wiki/Downloads) ≥ 6.1.6, though versions as low as 5.2 may work.
|
||||||
|
* GNU `Bash` ≥ 4.3, on Windows run through [Cygwin](https://cygwin.com/install.html) or WSL "1", see [NEM](#virtualbox-native-execution-manager-nem)
|
||||||
|
* GNU `coreutils` ≥ 8.22, GNU `gzip` ≥ 1.5, Info-ZIP `unzip` ≥ v6.0, GNU `wget` ≥ 1.14, `xxd` ≥ 1.11
|
||||||
|
* `dmg2img` ≥ 1.6.5, on Cygwin the package is not available through the package manager so the script downloads it automatically.
|
||||||
|
* `tesseract-ocr` ≥ 4
|
||||||
|
|||||||
+1299
-638
File diff suppressed because it is too large
Load Diff
Reference in New Issue
Block a user