Jump to content
fusion71au

Run Vanilla OS X El Capitan, Sierra, High Sierra or Mojave in VirtualBox 5.x.x on a Windows Host

95 posts in this topic

Recommended Posts

Update for macOS Sierra 10.12 to 10.12.6

 

The El Capitan Settings from post#1 still work for macOS Sierra. 

 

post-846696-0-58645100-1467499909_thumb.png

 

To prepare the Sierra ISO on your Mac or Hack:

 

1.  On your Mac or Hack with SIP disabled, download/copy "Install macOS Sierra.app" into your Applications folder.
2.  Download and unzip the BaseSystem_CSI.tool.zip (attached to this post) into your ~/Downloads folder.  Note: you will need approx 16GB of free space on your hard disk for the script to complete.
3.  Open OS X terminal, then run the following commands to execute the script:
cd ~/Downloads/BaseSystem
chmod +x CSI.tool
./CSI.tool

Provide your admin password when prompted...

4.  At the end of the process, you will have a Sierra.iso on your desktop - copy this onto an exFAT formatted USB for use on the PC Host later.

BaseSystem_CSI.zip

Share this post


Link to post
Share on other sites
Advertisement

Hello! My setup is acting quite strange. I got to the installer page, but then it crashed with an illegal operation. Now whenever I try and boot it, it always fails after DSMOS arrives and then I hear a very distorted sound.

Share this post


Link to post
Share on other sites

I want to use a virtualbox OS X to do development.

 

Using the vanilla installation on first post I can connect to apple store and download updates, and use my developer key, or MUST use clover?

 

Thank you.

Share this post


Link to post
Share on other sites

did have song command just like 

VBoxManage setextradata "El_Capitan" "VBoxInternal/Devices/efi/0/Config/rom" "%xx%xx%xx%xx%xx%xx"

 
 

VBoxManage setextradata "El_Capitan" "VBoxInternal/Devices/efi/0/Config/mlb" "Mac-F65AE981FFA204ED"

 

I kone vm can do this .

 

and vbox i can not find any command like this.

 

Share this post


Link to post
Share on other sites

Great guide!. Appreciate your effort very much.

I am running the El Capitan image from Tech Reviews on a Windows 10 with VirtualBox 5.0.26. It is working Ican download updates and xcode.

I tried to use bootloader from Tech Reviews but it won't boot with option -x to ignore errors. When it does boot with -x option it crashes now and then.

I also tried to install the latest clover but it won't install on El Capitan. 

 

I originally thought that USB doesn't work but it turned out that I chose USB 2.0 but I tested with a USB 3.0 stick. USB is indeed working.

Now the only thing left is the screen resolution. I need 1080P instead of 1902X1200.

 

I  will appreciate some help. Thanks in advance.

 

Below is my settings:

 

VBoxManage.exe modifyvm "OS X El Capitan" --cpuidset 00000001 000306a9 00020800 80000201 178bfbff
VBoxManage setextradata "OS X El Capitan" "VBoxInternal/Devices/efi/0/Config/DmiSystemProduct" "iMac11,3"
VBoxManage setextradata "OS X El Capitan" "VBoxInternal/Devices/efi/0/Config/DmiSystemVersion" "1.0"
VBoxManage setextradata "OS X El Capitan" "VBoxInternal/Devices/efi/0/Config/DmiBoardProduct" "Mac-F2238BAE"
VBoxManage setextradata "OS X El Capitan" "VBoxInternal/Devices/smc/0/Config/DeviceKey" "ourhardworkbythesewordsguardedpleasedontsteal©AppleComputerInc"
VBoxManage setextradata "OS X El Capitan" "VBoxInternal/Devices/smc/0/Config/GetKeyFromRealSMC" 1
VBoxManage setextradata "OS X El Capitan" "VBoxInternal/Devices/efi/0/Config/DmiSystemSerial" "W81234567B6"
VBoxManage setextradata "OS X El Capitan" "VBoxInternal/Devices/efi/0/Config/DmiBoardSerial" "W81234567891A"
VBoxManage setextradata "OS X El Capitan" "VBoxInternal/Devices/efi/0/Config/DmiSystemVendor" "Apple Inc."
VBoxManage setextradata "OS X El Capitan" "VBoxInternal/Devices/efi/0/Config/DmiSystemFamily" "iMac"
VBoxManage setextradata "OS X El Capitan" "VBoxInternal/Devices/efi/0/Config/DmiBIOSVersion" "IM112.0057.03B"
VBoxManage setextradata "OS X El Capitan" VBoxInternal2/EfiGopMode 4

Share this post


Link to post
Share on other sites

For me VBoxManage setextradata "OS X VM" "VBoxInternal2/EfiGopMode" N works fine, but custom resolution (for widescreen) is not working, However, it seems there is a problem with ElCapitan, because VmWare has similar problems.

 

I've just used this guide to successfully install Sierra in VB 5.1.6 and have exactly the same problem.  EfiGopMode works but not a custom resolution.  I've done a lot of searching and tried as many things as I could think of without success.

 

What is particularly frustrating is that I was running Mountain Lion in VB 4.3.30 and the custom resolution trick used to work.  But not any more.  Moreover, if I downgrade to VB 4.3 and open that ML machine, the custom resolution doesn't work anymore - ML now has the same screen resolution problems.

 

The question is - is this a Mac OS X os issue or a VB one?  The fact that you reported VMWare as having the same problems suggests a Mac OS X one.  But the fact that a downgrade of VB doesn't fix my problems suggests that it's more complex.  It's as if running the machine in a recent version of VB somehow does something to the install of Mac OS X in the virtual machine that can't be undone.

 

I'm inclined to report this as a VB bug, but first I need to replicate this on a Mac host rather than a Win host, or they'll ignore me.

 

I think that this is a Mac-specific problem as Win and Linux guests have guest additions.

Share this post


Link to post
Share on other sites

This post suggests that we're wasting our time on custom video modes using UEFI:
https://forums.virtualbox.org/viewtopic.php?f=22&t=74473&p=344689#p344689

 

It would seem that it worked for Mountain Lion because back then I wasn't booting it in EFI.  This post suggests that this isn't an option at present for recent versions of OS X:

http://www.insanelymac.com/forum/topic/309654-run-vanilla-os-x-el-capitan-sierra-yosemite-or-mavericks-in-virtualbox-5010-on-a-windows-host/?do=findComment&comment=2197249

 

Such is life.

Share this post


Link to post
Share on other sites

I got El Capitan to install successfully and was able to get in and navigate like usual. I shut down the VM to try increasing the CPU cores and RAM but after that it would crash or hang when trying to boot up. Has anyone had the same issue or figured out a way to increase the power for the VM?

 

Thanks.

Share this post


Link to post
Share on other sites

Given that it simply isn't possible to get a custom screen resolution to work with booting El Capitan or Sierra via EFI in VB, I had to decide what to do with my 1680x1050 screen (1.6:1 aspect ratio).

 

I tried scaling up the 1440x900 setting like this:

"C:\Program Files\Oracle\VirtualBox\VBoxManage.exe" setextradata "Sera" "VBoxInternal2/EfiGopMode" 4
"C:\Program Files\Oracle\VirtualBox\VBoxManage.exe" setextradata "Sera" "GUI/ScaleFactor" 1.15

And while it works, it's not all that sharp.  Also the fonts end up a bit large and there isn't enough pixel resolution.  So instead I used the 1920x1200 setting scaled down:

"C:\Program Files\Oracle\VirtualBox\VBoxManage.exe" setextradata "Sera" "VBoxInternal2/EfiGopMode" 5
"C:\Program Files\Oracle\VirtualBox\VBoxManage.exe" setextradata "Sera" "GUI/ScaleFactor" 0.875

This is a lot sharper and works well.  The fonts are a bit small now, but you can increase them in quite a few places to compensate.  A custom resolution would be better, but this seems an acceptable workaround.

 

Thanks for the guide BTW, it was much appreciated.

Share this post


Link to post
Share on other sites

Hello all, not sure if this is the best place to post but wanted to give some feedback on recent experiences. I've been running a couple of virtual Hackintoshes as described in this forum for a while now. I generally don't ever shut them down but save the state, and I don't actually use them very often.

 

Anyway I recently rebooted one of them (wanted to reduce the memory allocated to the VM) and when I went to reboot, it hung at the 'boot0: done' stage. On investigating I found that all the extradata items ("VBoxInternal/Devices/efi/0/Config/DmiSystemProduct" etc. had disappeared from the VM) I put them back and that's when I started getting the following message:

 

Failed to open a session for the virtual machine <hidden>.

Configuration error: Querying "UUID" failed (VERR_CFGM_VALUE_NOT_FOUND).

Result Code: NS_ERROR_FAILURE (0x80004005)
Component: ConsoleWrap
Interface: IConsole {872da645-4a9b-1727-bee2-5585105b9eed}

I then tried to create a new machine from scratch, and found exactly the same message. This seems to indicate that the machines can't be created in the same way any more. Bah!

 

I've now spent a full day looking into all this, and can't really afford to spend any more time. What I have found is that by booting my computer with an old kernel (3.2) and installing Virtualbox 4.3.30 (NB had to patch the installation file to handle cope with a changed kernel API, see: https://forums.virtualbox.org/viewtopic.php?f=7&t=70150)I was able to boot my VM as it was (ie without the extradata items). I don't imagine the kernel or Virtualbox version numbers are critical, just that they are 'old'(-ish).

 

But what I find particularly intriguing is that the above error message still appears on a fresh VM with the old kernel and old Virtualbox. Whether this means that they are not old enough, or something else 'new' is polluting my system and stopping them from working I don't know.

 

FYI my host system is Debian/sid. I tried with both Debian and upstream releases of Virtualbox (5.1.8, 5.0.26 and 5.0.0) before I found that 4.3.30 would work. My host system in this case is Mavericks/64 bit.

 

OK hope this helps someone or even better that someone can help me!

 

Cheers.

Share this post


Link to post
Share on other sites

I managed to get a legacy install of clover with Sierra. This allowed me to use a custom resolution.

 

I created a clover boot drive by following the guide for EFI booting and creating a Sierra VM (limited to the GOP modes). I then created a second virtual drive in virtualbox of about 1GB and attached it to the EFI Sierra. I used the clover installer to install legacy clover on the second drive I made. Then, I used the config.plist provided in the original clover guide, with the following modification to bypass the "zone_init: kmem_suballoc failed" issue: under SMBIOS I added

<key>Memory</key>
	<dict>
		<key>Modules</key>
		<array>
			<dict>
				<key>Slot</key>
				<integer>0</integer>
				<key>Size</key>
				<integer>(Memory assigned in virtualbox)</integer>
			</dict>
		</array>
	</dict>

Then, I created new vm with the same settings as in the original post, however I disabled EFI. I also removed the clover drive from the EFI virtual machine and added it to the new virtual machine. I booted from the 1GB clover drive and selected the Sierra ISO, made in the original post, in Clover.

I installed Sierra to the hard disk I made when I made the machine. When it had finished, I closed virtualbox and ran the command, 

VBoxManage setextradata VmName "CustomVideoMode1" 1920x1080x32" 

to set the resolution to 1920x1080. I left the machine booting from the clover drive, but clover could be installed on a partition of the macOS drive, if one so wished.

 

post-1672271-0-94744400-1477622308_thumb.png

config.plist.txt

Share this post


Link to post
Share on other sites

I managed to get a legacy install of clover with Sierra. This allowed me to use a custom resolution.

 

I created a clover boot drive by following the guide for EFI booting and creating a Sierra VM (limited to the GOP modes). I then created a second virtual drive in virtualbox of about 1GB and attached it to the EFI Sierra. I used the clover installer to install legacy clover on the second drive I made. Then, I used the config.plist provided in the original clover guide, with the following modification to bypass the "zone_init: kmem_suballoc failed" issue: under SMBIOS I added

<key>Memory</key>
	<dict>
		<key>Modules</key>
		<array>
			<dict>
				<key>Slot</key>
				<integer>0</integer>
				<key>Size</key>
				<integer>(Memory assigned in virtualbox)</integer>
			</dict>
		</array>
	</dict>

Then, I created new vm with the same settings as in the original post, however I disabled EFI. I also removed the clover drive from the EFI virtual machine and added it to the new virtual machine. I booted from the 1GB clover drive and selected the Sierra ISO, made in the original post, in Clover.

I installed Sierra to the hard disk I made when I made the machine. When it had finished, I closed virtualbox and ran the command, 

VBoxManage setextradata VmName "CustomVideoMode1" 1920x1080x32" 

to set the resolution to 1920x1080. I left the machine booting from the clover drive, but clover could be installed on a partition of the macOS drive, if one so wished.

 

attachicon.gifFull Res.png

 

 

Does Messages work in this scenario?  I actually bought a 1920x1200 monitor just so I could run full screen.  Messages and iTunes is all I use my VM for.

Share this post


Link to post
Share on other sites

I thought I would post my VM here.  Everything works flawlessly.  I've seen no performance issues.  I took a previous Mavericks install using Clover with working Messages and installed Sierra over top using an iso created from the retail .app.  If you're curious about the VM name vs the About This Mac, As part of this I stuck the values into my Clover config for a MB Pro and didn't change the VM name yet. 

 

I did try and upgrade directly from the .app within Mavericks and it got all the way through it and failed on a "cannot be installed on (null)" error.  Attaching the ISO in VirtualBox and booting to it for the upgrade worked perfectly.

 

Let me know if you have any specific questions.  The original VM was installed using this guide with Clover and valid hardware IDs.

 

post-1881223-0-45595900-1478541242_thumb.png

Share this post


Link to post
Share on other sites

I managed to get a legacy install of clover with Sierra. This allowed me to use a custom resolution.

 

I created a clover boot drive by following the guide for EFI booting and creating a Sierra VM (limited to the GOP modes). I then created a second virtual drive in virtualbox of about 1GB and attached it to the EFI Sierra. I used the clover installer to install legacy clover on the second drive I made. Then, I used the config.plist provided in the original clover guide, with the following modification to bypass the "zone_init: kmem_suballoc failed" issue: under SMBIOS I added... <CLIPPED> ... Then, I created new vm with the same settings as in the original post, however I disabled EFI. I also removed the clover drive from the EFI virtual machine and added it to the new virtual machine. I booted from the 1GB clover drive and selected the Sierra ISO, made in the original post, in Clover.

I installed Sierra to the hard disk I made when I made the machine. When it had finished, I closed virtualbox and ran the command, 

VBoxManage setextradata VmName "CustomVideoMode1" 1920x1080x32" 

to set the resolution to 1920x1080. I left the machine booting from the clover drive, but clover could be installed on a partition of the macOS drive, if one so wished.

 

attachicon.gifFull Res.png

 

Hey lost1234 ... Tried this but am not seeing the Sierra ISO from Clover .. I set it up as an virtual optical drive in the VirtualBox VM ... Is that what you did ? Anything I'm missing ? ...

 

Thx in advance for any help ... 

 

Cheers :-)

Share this post


Link to post
Share on other sites

Hi all!

 

Help, please.

 

My “Install OS X El Capitan” does not have the folder and content described (“/Contents/SharedSupport/InstallESD.dmg”).  

 

Further, I found some other instructions that deployed the “/Contents/MacOS/InstallAssistant” that it *does* have inside it, but that returned a message to the effect that it was not a valid copy of the installer.

 

Has Apple added further obfuscation to its [installation] materials, or is there a more simple (and hopefully fix-able) issue, please?

 

Thank you in advance!

Share this post


Link to post
Share on other sites

Very good guide !

 

I have installed the Capitan on a XEON E3-1225 v3 with Intel P4600 with the following settings (stolen from some posts here):

VBoxManage setextradata "El_Capitan" "VBoxInternal/Devices/efi/0/Config/DmiSystemProduct" ""
VBoxManage setextradata "El_Capitan" "VBoxInternal/Devices/efi/0/Config/DmiSystemProduct" "Macmini6,2"
VBoxManage setextradata "El_Capitan" "VBoxInternal/Devices/efi/0/Config/DmiSystemVersion" "1.0"
VBoxManage setextradata "El_Capitan" "VBoxInternal/Devices/efi/0/Config/DmiBoardProduct" "Mac-F65AE981FFA204ED"
VBoxManage setextradata "El_Capitan" "VBoxInternal/Devices/smc/0/Config/DeviceKey" "ourhardworkbythesewordsguardedpleasedontsteal©AppleComputerInc"
VBoxManage setextradata "El_Capitan" "VBoxInternal/Devices/smc/0/Config/GetKeyFromRealSMC" 1
VBoxManage setextradata "El_Capitan" VBoxInternal2/EfiGopMode 4

 

The usual problems: Dissorted Sound, just showing 4MB graphics memory, no CQ/QE, but a fully running 10.11 OSX 'just like that'

:)

Share this post


Link to post
Share on other sites

Hi thanks for the turorial, I'm trying to get it running on latest dell xps 13 (9360) and i cannot get to the isntaller , i suspect kaby lake CPUID must be faked for an skylake processor in order tu run. It's that correct ? also, what system definition should we use :macbook 9,1 , 11,3 or else?

thank you!

Share this post


Link to post
Share on other sites

After following this guide, I get El Capitan installed fine and to the login screen. Sometimes it will log on fine, but most of the time I will enter my password and the screen will go black with a cursor, then about 10-15 seconds later it will go back to the login screen. Any ideas?

 

I used a mid 2012 macbook pro 15" running el cap to make the iso. I then used the macbook pro 11,3 vbox configuration.

 

Running on windows 10 enterprise on an Hp prodesk G1

 

Virtualbox Version 5.1.16 r113841 (Qt5.6.2)

 

Share this post


Link to post
Share on other sites

Not sure what has changed with KabyLake, but no matter what CPUIDSETs I try, my VirtualBox goes to guru meditation when I try to install from vanilla Sierra ISO.

 

Sometimes I see this:

OcBvBbK.png

 

 

The same ISO works just fine on VMWare, but there is a problem with USB - when I attach iPhone, it starts connect/disconnect loop and does not work. On El Capitan in VMWare it works flawlessly, but I can't install the newest XCode there to support the newest iOS. So I hoped I might have better luck on VirtualBox with USB connection, but now it seems VirtualBox does not want to launch at all.

 

My setup:

 

Host OS: Windows 10 64 bit (with Creator's Update)

Host CPU: i7-7700 (kaby lake)

VirtualBox: 5.1.26 r117224 with extensions


Oh, I just discovered that I should change operating system from mac os x 64 El CAPITAL to just the mac os x 64. now I can get past guru meditation.
 
The same thing works also on VMWare: you have to pick 10.7 instead of 10.11 or 10.12. I’m not sure why, though – maybe something related to the fact that I’m on KabyLake.
 
But now I was stuck with the spinning cursor and this output:
 
yCXVJYi.png
 
But when I removed the DVD and booted from vmware vmdk I had installed earlier, it worked fine. Go figure...

Share this post


Link to post
Share on other sites

Update for High Sierra 10.13 17A365

The El Capitan Settings from post#1 still work for macOS High Sierra 10.13 17A365, but with newer VirtualBox 5.1.xx releases, USB3/xHCI should be enabled.  Tested below with 3GB Base Memory allocated for the guest macOS. 
 
post-846696-0-70723400-1508328130_thumb.png
post-846696-0-83960500-1508304724_thumb.png
post-846696-0-88046600-1508304876_thumb.jpg
 
To prepare the High Sierra ISO on your Mac or Hack:
1.  On your Mac or Hack with SIP disabled, download/copy "Install macOS High Sierra.app" into your Applications folder.
2.  Download and unzip the BaseSystem_CHSI.tool.zip (attached to this post) into your ~/Downloads folder.  Note: you will need approx 16GB of free space on your hard disk for the script to complete.
3.  Open OS X terminal, then run the following commands to execute the script:
cd ~/Downloads/BaseSystem
chmod +x CHSI.tool
./CHSI.tool
  Provide your admin password when prompted...
 
4.  At the end of the process, you will have a HSierra.iso on your desktop - copy this onto an exFAT formatted USB for use on the PC Host later.
 
Installation Notes
Install occurrs in 3 phases, procedure as follows:
 
1.  Boot to HSierra.iso and erase/format the Virtual HDD as HFS+ with Disk Utility.  Hint at the DU screen, click View & Show All Devices...
 

post-846696-0-55198300-1508305777_thumb.png
post-846696-0-17310700-1508305807_thumb.png
post-846696-0-55154500-1508306915_thumb.png
post-846696-0-66258500-1508305036_thumb.png
post-846696-0-87486400-1508305124_thumb.png

 
2.  Back at the main screen, select "Reinstall macOS" --->  will create first phase "/macOS Install Data" on target volume eg "HiSierra".
 

post-846696-0-05167700-1508305095_thumb.png
post-846696-0-76533700-1508307082_thumb.png
post-846696-0-52783500-1508307106_thumb.png
post-846696-0-37510300-1508307121_thumb.png

 
3.  We need to now copy the prelinkedkernel from our HSierra.iso to replace the vanilla one in "/macOS Install Data/Locked Files/Boot Files/" (using terminal, booted again into HSierra.iso):  <--- No longer need to copy prelinkedkernel from HSierra.iso for VirtualBox 5.1.30.
cp -rp /System/Library/PrelinkedKernels/prelinkedkernel /Volumes/HiSierra/macOS\ Install\ Data/Locked\ Files/Boot\ Files/

 

post-846696-0-01142700-1508305224_thumb.png

 

 

Shutdown the system and remove the HSierra.iso from the Virtual CD drive.
 

post-846696-0-39537100-1508305297_thumb.png
post-846696-0-21542600-1508305263_thumb.png

 
4.  In the second phase, "/macOS Install Data" packages are extracted and installed on the disk.  On restarting the system, you will be greeted with the UEFI shell.  Type the 2 lines below, followed by <Enter> after each line... 
FS1:
"\macOS Install Data\Locked Files\Boot Files\boot.efi"

 

post-846696-0-89353900-1508305360_thumb.png

 

 

---> will restart the installation process...

 

 

post-846696-0-57544000-1508305446_thumb.png

post-846696-0-36920200-1508305486_thumb.png

post-846696-0-26809500-1508305523_thumb.png

 

 

5.  Final third installation phase is rebuilding kextcaches, booting to the completed installation to select language and setup new user etc.
 

post-846696-0-33132900-1508305619_thumb.png
post-846696-0-88046600-1508304876_thumb.jpg

BaseSystem_CHSI.tool.zip

Share this post


Link to post
Share on other sites

Hi,

 

Thanks again for this great guide. High Sierra installed and it's working fine. However, trying to go a bit further with Clover EFI, I get a blurry unusable screen. Should we just wait for a Clover update?

See attached screenshot

 

post-241390-0-67333900-1509812592_thumb.png

Share this post


Link to post
Share on other sites
On 11/5/2017 at 3:26 AM, Gwan said:

Should we just wait for a Clover update?

 

Make sure the EFI GOP mode you specify matches the GUI/ScreenResolution set in Clover's config.plist eg for GOP mode 2, corresponding to 1024x768,

VBoxManage setextradata "VM_Name" VBoxInternal2/EfiGopMode 2

set config.plist/GUI/ScreenResolution

		<key>ScreenResolution</key>
		<string>1024x768</string>

Likewise for GOP mode 3, resolution = 1280x1024 etc.

 

Also the official Clover from SourceForge compiled with XCODE doesn't seem to work in Virtual Machines.  Need to install Clover compiled with GCC in Linux (eg EFI_Clover_r4332 for VMware also works in EFI mode with VirtualBox).

 

After starting the VM, press <F12> to access the VirtualBox Boot Manager, then choose EFI Hard Drive to start Clover...

 

 

 

 

post-846696-0-24390900-1509836536_thumb.png

post-846696-0-14379800-1509836557_thumb.png

post-846696-0-44753200-1509855356_thumb.png

post-846696-0-00333500-1509855407_thumb.png

 

 

 

 

How to install High Sierra on a VirtualBox Guest from scratch (without access to Mac or App Store Installer.app)

 

Pre-requisites

1)  On 8GB NTFS formatted USB, Vol Name "DATA",  a "SharedSupport" folder was prepared as described in my guide here, containing the following 6 installer files downloaded from Apple's Software Catalog ....

 

 

 

 

 

  1. BaseSystem.dmg
  2. BaseSystem.chunklist
  3. InstallInfo.plist <---Edited, attached example here
  4. InstallESDDmg.pkg <---Renamed to InstallESD.dmg 
  5. AppleDiagnostics.dmg
  6. AppleDiagnostics.chunklist

(Hint - search page for "InstallESD" to find its URL and others nearby)

 

 

 

2)  macOS High Sierra guest created in VirtualBox r5.1.30, as described in post#1 but 3GB RAM, enable USB3/XHCI, EFI GOP mode2 (1024x768)...

cd "C:\Program Files\Oracle\VirtualBox\"
VBoxManage setextradata "VM_Name" VBoxInternal2/EfiGopMode 2

3) Attached blank, preformatted virtual disk, macOS.vmdk of 50GB size, with Clover r4332 installed in its EFI (extract from "macOS.vmdk.zip" attached to this post).

 

 

 

 

post-846696-0-86187200-1512074010_thumb.png

 

 

 

 

 

Procedure

1)  Download & extract dmg2img-1.6.7-win32 and qemu-img-win-x64-2_3_0 to USB\.  For my system, the drive letter was H:

 

 

 

 

 

post-846696-0-23988600-1512076592_thumb.png

post-846696-0-93981000-1512076609_thumb.png

 

 

2)  Convert BaseSystem.dmg to BaseSystem.img with dmg2img.  Open a Windows command prompt and type the following commands

H:
cd \dmg2img-1.6.7-win32
dmg2img.exe \SharedSupport\BaseSystem.dmg \qemu-img-win-x64-2_3_0\BaseSystem.img

 

 

 

Microsoft Windows [Version 6.1.7601]

Copyright © 2009 Microsoft Corporation.  All rights reserved.

 

C:\Users\fusion71au>H:

H:\>cd \dmg2img-1.6.7-win32

H:\ dmg2img-1.6.7-win32>dmg2img.exe \SharedSupport\BaseSystem.dmg \qemu-img-win-x64-2_3_0\BaseSystem.img

 

dmg2img v1.6.7 © vu1tur (to@vu1tur.eu.org)

 

\SharedSupport\BaseSystem.dmg --> \qemu-img-win-x64-2_3_0\BaseSystem.img

 

 

decompressing:

opening partition 0 ...             100.00%  ok

opening partition 1 ...             100.00%  ok

opening partition 2 ...             100.00%  ok

opening partition 3 ...             100.00%  ok

opening partition 4 ...             100.00%  ok

opening partition 5 ...             100.00%  ok

opening partition 6 ...             100.00%  ok

opening partition 7 ...             100.00%  ok

 

Archive successfully decompressed as \qemu-img-win-x64-2_3_0\BaseSystem.img

 

 

3)  Change to \qemu-img-win-x64-2_3_0 directory and convert BaseSystem.img to BaseSystem.vmdk in your VirtualBox macOS guest folder...

cd \qemu-img-win-x64-2_3_0
qemu-img.exe convert BaseSystem.img -O vmdk Path_to_your_VirtualBox_macOSGuest_HD_folder

 

 

 

H:\dmg2img-1.6.7-win32>cd \qemu-img-win-x64-2_3_0

H:\qemu-img-win-x64-2_3_0>qemu-img.exe convert BaseSystem.img -O vmdk "E:\VirtualBox VMs\macOS\BaseSystem.vmdk"

 

 

4)  Attach BaseSystem.vmdk to your macOS guest as an extra hard drive (so now have macOS.vmdk + BaseSystem.vmdk attached to the VM)...

 

 

 

 

post-846696-0-13748400-1512074390_thumb.png

post-846696-0-03134800-1512074407_thumb.png

post-846696-0-46554600-1512074424_thumb.png

 

 

 

 

5)  Boot the VM to macOS Utilities screen.  Attach DATA usb with \SharedSupport files to VM...

 

 

 

 

post-846696-0-69436800-1512074629_thumb.png

post-846696-0-50581900-1512074652_thumb.png

post-846696-0-31701000-1512074675_thumb.png

 

 

 

6)  Open terminal from the Utilities Menu and type

cd /
ls -l /Volumes

to confirm that the following Volumes are attached to the VM:  "OS X Base System", "macOS"=HD target, and "DATA"=8GB or larger USB with "SharedSupport" folder...

 

 

 

post-846696-0-91444400-1512074931_thumb.png

 

 

7)  Launch the startosinstall.command script to assemble the Installer App on the macOS target volume and start the startosinstall utility...

-bash-3.2# cd /Volumes/macOS/
-bash-3.2# ./startosinstall.command

The process may take a while.  One way you can see its progression is to look at the size of the macOS.vmdk in the host VM folder (approx 5.2GB when the Installer App is fully assembled)...

 

 

 

 

post-846696-0-86003800-1512075005_thumb.png

post-846696-0-77138800-1512075025_thumb.png

 

 

 

8)  The Apple Software Licence will appear in the terminal window.  Type A to agree ---> install files will be placed in /Volumes/macOS/macOS Install Data ---> System will reboot after 30 seconds...

 

 

 

 

 

post-846696-0-78747000-1512075128_thumb.png

 

 

 

9)  Power off the VM when you see the message "MACH Reboot".  Then go to the VM Storage settings to detach the BaseSystem.vmdk (since it is no longer required).

 

 

 

 

post-846696-0-71465900-1512075234_thumb.png

post-846696-0-87990200-1512075250_thumb.png

post-846696-0-56854200-1512075265_thumb.png

 

 

 

10)  Power on the VM again and you will be greeted with the Clover Main Menu --->  select "Boot macOS Install from HFS+ volume" + press <Enter>  ---> will see "Installing on "macOS"" and time remaining, as the pkg files are extracted to their final locations ---> Power off the VM when you see the message "MACH Reboot"...

 

 

 

 

post-846696-0-19576600-1512075352_thumb.png

post-846696-0-91196600-1512075373_thumb.png

post-846696-0-63236100-1512075388_thumb.png

post-846696-0-19576400-1512075414_thumb.png

post-846696-0-33660800-1512075465_thumb.png

post-846696-0-67466800-1512075490_thumb.png

 

 

 

11) Power on the VM a final time to rebuild kext caches and setup new user account.  The installer app and startosinstall.command script can be safely deleted if desired...

 

 

 

 

post-846696-0-31706900-1512075506_thumb.png

post-846696-0-44646600-1512075878_thumb.png

post-846696-0-02425800-1512075923_thumb.png

 

 

12) If you subsequently want to start the VM through Clover, click in the VM window when it is still black and quickly press the <F12> key to access the VirtualBox BIOS Boot Manager ---> select EFI Hard Drive ---> Boot macOS from HFS+ volume at the Clover Main Menu.  Clover nicely fills in the System's details, including a serial number (you can change this later + add custom MLB + ROM for iMessage by mounting the EFI partition and editing Clover's config.plist)...

 

 

 

 

post-846696-0-42022300-1512075991_thumb.png

post-846696-0-65791200-1512076017_thumb.png

post-846696-0-51643900-1512076057_thumb.png

post-846696-0-56340700-1512076100_thumb.png

 

 

macOS.vmdk.zip

Edited by fusion71au
Updated download links for 10.13.6

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now

  • Recently Browsing   0 members

    No registered users viewing this page.

  • Similar Content

    • By fusion71au
      Run Vanilla OS X El Capitan, Sierra, High Sierra or Mojave in VMware Workstation on a Windows Host
       
      I wanted to make a simple guide on how to create a vanilla OS X El Capitan virtual machine running on a Windows host.  The virtual machine should be useful for testing El Capitan and also for creating installers for use on a real machine/hackintosh.
       
      There are many guides and videos on the net about running OS X on Windows machines using pre-made VMWare disk images but you can never guarantee what else is in there….
       
      I’ve gathered info for this guide from various threads in the Multibooting and Virtualisation section of this forum eg
       
      Workstation 11/12, Player 7/12, Fusion 7/8 and ESXi 6 Mac OS X Unlocker 2 by @Donk How to Install OS X 10.x from Snow Leopard to El Capitan in VMware Workstation 10/12, Player 6/8 or ESXi 5/6 by @MSOK HOW TO: Create a bootable El Capitan ISO for VMware Credit and thanks to @Donk, @Albert Nietsnie and @MSOK for all their hard work in creating and testing the VMware Unlocker program.
       
      Requirements
      Intel PC with four or more CPU cores running Windows 7 X64 or later OS (2 or more cores needed for OS X) 4GB or more RAM (2GB or more will be needed for OS X) Hard Disk with at least 40GB free for Virtual Machine VMware Workstation 12 or later VMware Unlocker 2.0.7 or later Install OS X El Capitan app and Mac or Hack to prepare installation iso <-- Now, no longer necessary to have previous access to a Mac or Hack by building the Installer.app from scratch - see post#41 16GB or larger exFAT formatted USB stick to transfer El Capitan iso from Mac/Hack to Host PC Prepare Installation ISO on your Mac or Hack
      1.  On your Mac or Hack, download "Install OS X El Capitan.app" from the App Store into your Applications folder.
      2.  Unmount any attached install image/InstallESD.dmg (if currently mounted) by rebooting the system or running the hdiutil unmount command in terminal eg
       
      3.  Download and unzip the CECI.tool (attached to this post) into your ~/Downloads folder. The commands in this executable script are shown below for informational purposes….
       
       
       
      4.  Open OS X terminal, then run the following commands to execute the script:
      cd downloads chmod +x CECI.tool ./CECI.tool 5.  At the end of the process, you will have an El Capitan iso on your desktop - copy this onto an exFAT formatted USB for use on the PC Host later.
       
      Update: @shela has created an ISO generating script compatible with OS X 10.6-10.12: create_osx_iso post #362.
       
      Install and Patch VMware Workstation 12 on your PC
      1.  Download and install VMWare Workstation Player 12 or later
      2.  Download and extract Unlocker 2.0.7 or later to your USB stick…
      3.  Run the win-install.cmd as administrator by right clicking the file in Windows explorer or run it from an Administrative Command Prompt.
       



       
      Create an El Capitan Virtual Machine
      1.  Double click on the VMware Workstation 12 Player icon on your desktop and click “Create a New Virtual Machine”.  Choose “I will install the operating system later” at the How will you install screen….
       

      2.  Select Apple Mac OS X as the Guest operating system and OS X 10.11 as the version.  By default, an OS X 10.11 folder will be created in your Documents\Virtual Machines folder.
       


      3.  Under Specify Disk Capacity, you can leave the default 40GB or set a larger value.  I personally store the virtual disk as a single file.  Click Finish and you will see OS X 10.11 on the Main Screen of Workstation 12.
       


      4.  Next, we need to edit the virtual machine settings to map the virtual SATA CD/DVD drive to the El Capitan installation iso we created earlier.
       


       
      5.  To prevent the virtual machine from crashing in Windows, the virtualHW.version set in the vmx configuration file needs to be changed from 12 to 10 (alternatively, the line smc.version = "0" can be added to the file).  The OS X 10.11.vmx file can be edited with the WordPad program (navigate to the OS X 10.11 virtual machine folder with Windows Explorer and right click on the file to open in WordPad).
       


       
      6.  For HW10, set USB compatibility to USB 2.0, otherwise your mouse and keyboard might not work in the virtual machine.
       

      7.  Finally click “Play virtual machine”
       

      Installation of El Capitan
      Installation should be relatively straight forward, just following the prompts of the OS X installer:
      1.  Select language, agree to legal terms
       

      2.  Use Disk Utility from the Utilities Menu to erase and format the virtual hard drive as a single partition GUID Mac OS X Extended.  I’ve named the drive Macintosh HD but you can enter whatever you like eg El_Capitan.
       



      3.  Quit DU and choose Macintosh HD to install El Capitan on.
       

      4.  After 20-30 min (depending on how fast your system is), the installation will complete and the VM will automatically reboot…
       

      5.  At the welcome screen, choose your country and keyboard layout.  You can skip transfer information, location services and logging in with your Apple ID if you wish…
       


      6.  Create a User Account and select your Time Zone.  You can skip sending diagnostics and usage data to Apple….
       


      7.  Finally, you will arrive at the El Capitan Desktop.  You should eject the Installation iso now by right clicking and selecting “Eject OS X Base System”.  This will allow you to install VMware Tools….
       



      8.  After rebooting, the VM can now be resized or run at full screen resolution.  Audio and network/internet should also work OOB.
       

       
      SMBIOS Customization and iMessage Vars
      To make the Virtual Machine more "Mac like", you can edit the vmx file to add unique identifiers from a real Mac's SMBIOS -
      eg for an iMac 11,3 SMBIOS, you can enter the following lines....
      smbios.reflectHost = "FALSE" board-id.reflectHost = "FALSE" board-id = "Mac-F2238BAE" hw.model.reflectHost = "FALSE" hw.model = "iMac11,3" serialNumber.reflectHost = "FALSE" serialNumber = "W80#######6" Refer How to spoof real Mac in VMware - Multi-booting and Virtualisation.
       
      The critical variables for iMessage/Facetime activation are MLB & ROM.  By default, VMware "reflects" the host's MLB and ROM since it assumes you are running the OSX guest on a real Mac host - see post#42 by @Donk.
       
      If the host is a Windows PC, the following lines need to be added to the vmx file (requires virtualHW.version 12 and smc.version = "0")....
      efi.nvram.var.ROM.reflectHost = "FALSE" efi.nvram.var.MLB.reflectHost = "FALSE" system-id.enable = "TRUE" and the MLB, ROM and optionally system-id entered manually eg
      efi.nvram.var.MLB = "W80######BA1A" (MLB can be 13 or 17 characters long, alphanumeric string) efi.nvram.var.ROM = "<=>?@A" (ROM is entered here as a 6 character ASCII string) uuid.bios = "## ## ## ## ## ## ## ##-## ## ## ## ## ## ## ##" <---Optional (if you want to inject a given system-id hexadecimal value) Note the output for ROM from imessage_debug is a 12 character hexadecimal that needs to be entered here as a 6 character ASCII string eg using an Hex to ASCII converter we find that "3c3d3e3f4041" hex is equivalent to   "<=>?@A".
       
      Vanilla Mavericks and Yosemite
      The same VM settings for El Capitan will also boot and run vanilla installations of OS X Mavericks and Yosemite .  Attached to this post are installer scripts to create bootable Mavericks (CMI.tool) and Yosemite (CYI.tool) ISOs for VirtualBox and VMware.
       
      With the respective OS X installer apps in the Applications folder, download and run the installer tools using terminal ie
       
      To create a Mavericks ISO on your desktop
      cd downloads chmod +x CMI.tool ./CMI.tool To create a Yosemite ISO on your desktop
      cd downloads chmod +x CYI.tool ./CYI.tool Here is a screenshot of the VM running Mavericks 10.9.5...
       

       
      Enjoy
       
      Update for macOS 10.12 Sierra
      The above settings still work for macOS Sierra after upgrading to VMware Workstation 12.5 and unlocker 2.0.8 - see post #13.
       
      Update for macOS 10.13 High Sierra and 10.14 Mojave
      See post#30
      Post#41 describes how to build "Install macOS ******.app" on the fly from installer files downloaded beforehand in /SharedSupport folder.
       
       
      CECI.zip
      CYI.tool.zip
      CMI.tool.zip
×