With the release of macOS High Sierra 10.13, this guide is now outdated! Click here to view the new High Sierra guide!
This tutorial for installing macOS Sierra has been adapted for Proxmox 4.4 from this tutorial for Yosemite, and this GitHub project for installing into vanilla KVM.
I’ll assume you already have Proxmox 4.4 installed. You also need a real Mac available in order to download Sierra from the App Store and build the installation ISO. Your host computer must have an Intel CPU at least as new as Penryn. I think you may need a custom Mac kernel to use an AMD CPU.
These installation instructions have been tested with Sierra 10.12.4. Although it’s been a while since I performed a fresh install, I’m currently running Sierra 10.12.6 on Proxmox 5 using a VM built with these instructions.
First step: Create an installation ISO
On a Mac machine, download the macOS Sierra installer from the App Store (this will download it into your Applications folder).
Download the contents of this repository to your mac.
From inside that directory, run “sudo ./create_install_iso.sh” to create the install CD for you:
Once that’s done, connect to your Proxmox server using Transmit (or some other SCP/SFTP client) and upload the ISO you created to /var/lib/vz/template/iso.
While you’re there, upload the enoch_rev2902_boot bootloader file from the GitHub repository to /var/lib/vz/template/qemu/enoch_rev2902_boot.
Fetch the OSK authentication key
macOS checks that it is running on real Mac hardware, and refuses to boot on third-party hardware. You can get around this by reading an authentication key out of your real Mac hardware (the OSK key). Run the first bit of C code from this page (you’ll need XCode installed) and it’ll print out the 64 character OSK for you. Make a note of it.
Create the VM
From the Proxmox web UI, create a new virtual machine as shown below.
In the Options page for the VM, change “Use tablet for pointer” to “No”.
In the Hardware page for the VM, change the the Display to Standard VGA (std).
Don’t try to start the VM just yet. First, SSH into your Proxmox server so we can make some edits to the configuration files.
Edit /etc/pve/qemu-server/YOUR-VM-ID-HERE.conf (with nano or vim). Add these two lines, being sure to subtitute the OSK you extracted earlier into the right place:
machine: pc-q35-2.4 args: -device isa-applesmc,osk="THE-OSK-YOU-EXTRACTED-GOES-HERE" -smbios type=2 -kernel /var/lib/vz/template/qemu/enoch_rev2902_boot -cpu Penryn,kvm=off,vendor=GenuineIntel
Find the line that specifies the ISO file, and remove the “,media=cdrom” part from the end of the line (otherwise you’ll get stuck at the bootloader).
On the net0 line, change “e1000” to “e1000-82545em”. This variant is supported by OS X.
macOS doesn’t support the PS2 keyboard and mouse that QEMU will emulate, nor does it support the tablet, so edit /usr/share/qemu-server/pve-q35.cfg and add these USB input devices to the bottom of the file instead:
[device "mouse1"] driver = "usb-mouse" bus = "ehci.0" port = "1" [device "keyboard1"] driver = "usb-kbd" bus = "ehci.0" port = "2"
We’ve added those to the config file instead of to the VM’s args directly. If we were to add them to the VM’s args, then when Proxmox constructs its call to KVM to launch the VM, those device definitions would appear before the pve-q35.cfg file is included, which defines the USB busses. However, the device definitions must appear after the definitions of the USB bus that they refer to.
Note that this file is whitespace-sensitive, make you you don’t add any blank lines that have extraneous spaces on them.
On Proxmox, run “echo 1 > /sys/module/kvm/parameters/ignore_msrs” to avoid a bootloop during macOS boot. To make this change persist across Proxmox reboots, run:
echo "options kvm ignore_msrs=Y" >>/etc/modprobe.d/kvm.conf && update-initramfs -k all -u
If you’re installing Sierra 10.12.4 or newer, you’ll also need to patch Proxmox’s copy of QEMU in order to be able to boot until this patch is merged by the upstream.
Now start up your VM.
If you get an error “file system may not support O_DIRECT / Could not open iso: invalid argument” when starting the VM, you may need to edit the CD drive on the hardware tab and change its cache setting to “writeback (unsafe)”.
Go to the Console tab:
Press enter to choose the “install macOS Sierra” entry and the installer should boot up.
If you are unable to move the mouse cursor at the Welcome screen, and a beachball-of-doom appears on the host, you might be using Safari. It seems to get overwhelmed with the number of screen updates on the animated Welcome screen and become unresponsive. Try Chrome instead.
Our virtual hard drive needs to be erased/formatted before we can install to it, so go to Utilities -> Disk Utility and do that now:
Before we start installation, we have some files to copy over to the newly-formatted drive. Choose Utilities -> Terminal, and copy the /Extras directory to your main volume (/Volumes/Main, for example) using “cp -av /Extra /Volumes/Main/” like so:
Quit terminal. Now you can begin installation to the Main drive.
After the first stage of installation, the VM should reboot itself and continue installation by booting from the hard drive. After answering the initial install questions, you’re ready to go!
I found that I was unable to wake Sierra from sleep using my mouse or keyboard. You can either disable system sleep in Sierra’s Energy Saver settings to avoid this, or you can manually wake the VM up from sleep from Proxmox by running:
qm monitor YOUR-VM-ID-HERE system_wakeup quit
Using noVNC gets pretty annoying due to the Mac’s absence of tablet support for absolute cursor positioning. You can solve this by turning on the Mac’s screen sharing feature and using that instead. But I want to use this as my primary computer, so I’m using USB input devices plugged directly into Proxmox.
Proxmox has good documentation for USB passthrough. Basically, run “qm monitor YOUR-VM-ID-HERE”, then “info usbhost” to get a list of the USB devices connected to Proxmox:
qm> info usbhost Bus 3, Addr 12, Port 6, Speed 480 Mb/s Class 00: USB device 8564:1000, Mass Storage Device Bus 3, Addr 11, Port 5.4, Speed 12 Mb/s Class 00: USB device 04d9:0141, USB Keyboard Bus 3, Addr 10, Port 5.1.2, Speed 12 Mb/s Class 00: USB device 046d:c52b, USB Receiver Bus 3, Addr 9, Port 14.4, Speed 12 Mb/s Class 00: USB device 046d:c227, G15 GamePanel LCD Bus 3, Addr 8, Port 14.1, Speed 1.5 Mb/s Class 00: USB device 046d:c226, G15 Gaming Keyboard Bus 3, Addr 6, Port 11, Speed 12 Mb/s Class e0: USB device 0b05:17d0, Bus 3, Addr 2, Port 1, Speed 1.5 Mb/s Class 00: USB device 068e:00f2, CH PRO PEDALS USB
In this case I can add my keyboard and mouse to USB passthrough by quitting qm, then running:
qm set YOUR-VM-ID-HERE -usb1 host=04d9:0141 qm set YOUR-VM-ID-HERE -usb2 host=046d:c52b
This saves the devices to the VM configuration for you. It’s possible to hot-add USB devices, but I just rebooted my VM to have the new settings apply.
PCIe GPU passthrough
For native graphics performance, I wanted to pass through my graphics card for the macOS VM’s exclusive use (driving a monitor connected to Proxmox). Follow the instructions from the Proxmox manual. Use the “GPU Seabios PCI EXPRESS PASSTHROUGH” section for this installation.
Note that your CPU and motherboard need to support VT-d (be sure to enable it in your BIOS as it’s often disabled by default), and your CPU needs to support IOMMU interrupt remapping.
After following the instructions to blacklist video drivers in the Proxmox manual, I found I had to run “update-initramfs -u” in order for the blacklist to be applied.
Check that your graphics card has been reserved correctly by running “lspci -k” on Proxmox and checking which driver is assigned to the graphics card (if done correctly, it should be “vfio-pci”).
After following through all the steps in that guide, I ended up with a new “hostpci0: 01:00,pcie=1,x-vga=on” line in my VM’s configuration, and after a reboot of Proxmox, my graphics card (Radeon R9 280X) was working! Only some cards are natively supported by macOS, check out the tonymacx86 Radeon compatibility list for your card. I also found a list of supported Nvidia cards (some using Nvidia’s Web Driver).
I have had success passing through my EVGA GeForce GTX 750Ti SC 2G, driving a 4K screen over DisplayPort and another display over HDMI. This required me to use Clover/UEFI boot, install the NVidia web drivers, and update my SMBIOS to “iMac 14,2” and enable “NvidiaWeb” in Clover Configurator.
Using Clover as a bootloader
I’ve also written up a guide on converting this VM to use Clover for booting instead of Enoch.
104 thoughts on “Installing macOS Sierra on Proxmox 4.4 / QEMU 2.7.1”
In my case I am getting that during biit from iso. EL Capitan and Sierra
Can’t find boot file /system/library/kernels/kernel
Any errors during the build of the ISO? I had a problem where I didn’t realise I also needed to download the “pbzx” binary from the repo, and ensure it was chmod u+x (clone the whole repo since it has other files needed for build too).
Yes. That was pbzx.
Created image again.
Unfortunataly I have only MAC mini which reject to update up to Sierra
So I’ve made following trick.
– Found and downloaded Installation package dmg for Sierra.
– Created folder “Install macOS Sierra.app” inside /Applications/
– Copied Content of dmg package into created folder
– started script.
I did not got any errors while script run and got iso file.
Created VM accordingly with instructions.
It does boot. Shows different stuff about found some patches for Sierra kernel, etc …
But after some time stops at the lines related to root device:
rooting via boot-uid from /chosen: [HERE LONG UUID]
Still waiting for root device
Still waiting for root device
and same again..
The only thing I can think of is that the .dmg you downloaded has extra stuff added to it.
Maybe try downloading the app linked from this page?
I haven’t tried it, but it sounds like it might be the unmodified version from the mac app store.
Got new image from guy on Mac PRO with Sierra.
So image is fully OK.
Getting same issue:
Still waiting for root device
Screenshot – https://postimg.org/image/niir2kal7/
I apologize for all my comments here.
It appears I forgot to insert machine type into config.
So feel free to remove all my comments as I think they are useless for people.
It just require to follow instructions step by step and double check! 🙂
I am setting up successfully now.
Got an issue with login to apple store.
Your device or computer could not be verified…
Have you meet the same ever?
Found the solution for that, your main network adapter has to be called “en0”:
I was able to log in to the app store after fixing that!
This didn’t work for me – any ideas?
The other critical part is installing that Enoch plist file, I think the “PCI root ID” setting in particular is required.
I reinstalled and it worked 🙂
Great article, very helpful – thank you!
Just want to say THANK YOU for this fantastic guide!!!
Is it somehow possible to refere to a different config file than /usr/share/qemu-server/pve-q35.cfg ? I don’t want to make changes on this file.
I am struggling to extract the OSK with the C code. Tried it in xcode but got errors.
Can anyone assist, I am running Sierra on a Macbook Pro
You can save that code into a file called “smc_read.c”, then using the terminal go to that same directory and run “gcc -Wall -o smc_read smc_read.c -framework IOKit” followed by “./smc_read”.
Or the GitHub repository I linked early on has a copy of the OSK without having to run any tools.
Refer kholia github for the osk code.
I am able to boot up the VM and it starts the install, but I get stuck on the choose a language page. Actually I can get past it, but on the next page where you need to use the Menu to run Disk Utility, the menus say “Choose a Language” and I cannot get to the disk utility to proceed. Also on the language selection page I cannot make the language I want (English in my case) to show as selected in blue, it’s a dark-gray selection which makes me think perhaps it is getting stuck because I am not actually choosing the language, then on the next page it’s hung up? Don’t know, hoping someone else has dealt with this? Also I saw on another site that it did happen and the solution was to sit on the language page for a bit before proceeding. I have tried this (left it sitting there for 30 mins) but it hasn’t helped. So frustrated because if I could get past this one hurdle I think I’d be homefree!
Sorry, I haven’t encountered that one! Are you using Proxmox 4.3? I would try rebuilding the Sierra install ISO and trying again. Are you using an official (non-hacked) Sierra installer as input to build the ISO?
The same thing happened with me. There is no menu with Utilities.. I’m using the iso image generated from the provided scripts from the repository that you pointed
I am stuck on this same problem. Did you find a fix?
To update in case anybody comes across this same problem – I didn’t figure out how to fix the issue but do have a workaround. If you boot your VM into a GParted live disk – or any live disk with GParted – you can create format your partition then go back and do the install.
The partition table needs to be gpt and the partition HFS+.
If you do that, you should add an EFI partition while you’re there, for future use.
On the bootscreen add -X flag to boot in safe mode, worked for me.
I’ve got the same issue as Don. I’m on Proxmox 4.4 and have tried the -X flag with no luck.
Thanks for the workaround using Gparted. I did just that!
thanks for the workaround! im trying to give that a shot but gparted gives the options for gpt and hfs+ but i dont see an option for journaled? i tried w/ out and the mac installer lets me select the disk but then gives an error that i need to make it journeled to function. any idea??
i was able to use a combo of ubuntu live and gparted to get it to a working hfs+ journaled drive and install finished. I wasnt able to do the Extras copy of course since that Utilities menu is still not avail so going to try that from within osx since it boots. last snag i have left is rebooting osx seems to hang (have to force restart from proxmox) and also after a reboot i have to uncheck/recheck remote management or screen sharing for that to work again. not sure if anyone else has seen that?
Micah – Thank you for sharing your work around. N00b here. I am using Proxmox 4.4. Can you please tell me how I can boot the VM I originally created to run MacOS into a Gparted live disk?
Many thanks in advance!
Hey, sorry – I haven’t checked back here since my problem got solved, just came back to reread how I got it going. Hopefully you’ve got it running but if not here you go.
Assuming you’ve already gone through the process outlined here you need to do a few things – delete the hard drive that is the install ISO from Proxmox, delete the Args and Machine lines from the config file, then create a new CD drive to mount the GParted ISO. Once you boot and format you can mount the Mac ISO again, redo the steps and are good to go.
If you want more detail let me know – with basic knowledge that is enough and I don’t want to spend too much time if you already got it.
Just came across this hint.
On my machine, i needed to create HFS+ with journaling enabled to install MacOS
mkfs.hfsplus -v “MacOS” /dev/sdX1 -J 1024M
or whatever you find suitable as journal size
Don – I am stuck with the same situation as you were. Did you ever find a solution to this?
Thanks for the guide!
I am having two problems – one is the same as Don Langhorne where I can’t get to disk utility.
The other is with the mouse pointer. The pointer in the VNC doesn’t line up with my actual mouse. I tried the VNC on both my Mac and Linux computers as well as multiple browsers on both.
Anybody else have this issue?
Not sure about the missing disk utility problem. Is your virtual hard disk attached by IDE? I guess it’s possible that if the Mac installer can’t mount any disks, it doesn’t show the menu.
As for the mouse, that’s expected as Mac doesn’t support a tablet pointing device for absolute mouse positioning. The two solutions I’ve tried are to use Mac screen sharing or some other guest-installed VNC server rather than the built-in VNC (since the clients for these can hide your local mouse pointer, eliminating the confusion between the two) or to pass through a hardware mouse using USB.
There’s a virtio Mac guest tablet driver that should solve the issue, but I’ve never tried it:
In trying to retrieve the key I get
You’ve got it, that *is* the key!
Thanks for a great guide. I get a kernel panic as boot relating to. exit reason namespace 2.
Do you have any ideas. my server only has 2GB RAM at the moment could this be an issue? i am waiting on more.
2GB of RAM for the whole server is super tight, Sierra itself has a 2GB minimum requirement. Is this a 64 bit system? Do you have an Intel processor? AMD processors require a custom Mac kernel.
Yes intel, yes 64bit. more RAM on the way, maybe that is the issue?
nick if I run -v at boot I get Thread 0 crashed
and buch of hex text and then
Mac osx version : not set yet
Maybe take a screenshot of that message? Or a photo or video of the boot. You can upload images to http://imgur.com/ and link them here.
I was able to boot the installer and Sierra with just 1800MB of RAM assigned to the guest. I wonder if your host is actually running out of memory and killing the VM thread, check /var/log/kern.log for OOM (Out Of Memory Killer) warnings.
I’m using zfs iso and vm storage in proxmox. I ran into a problem where the boot menu didn’t display any install options. I stumbled across this post on reddit that solved the problem: https://www.reddit.com/r/homelab/comments/55y9t7/installing_macos_sierra_on_proxmox_43_qemu_261/
Simply set the cache to write-back on the ISO entry like this:
Thanks for the great guide! Here’s a challenge for you: my installation starts and gets to the “select disk for install” screen, but there is no menu except for the Language Chooser. I need to open Disk Utility to format my disk, but I can’t because there’s no menu for it. Any ideas?
@eebb I am running into the same issue. did you ever find a solution to resolve this?
Hi all :),
I have tried to install Sierra OS X under ProxMox 4.4 but after the black boot screen I select the device where I would like to install the OS and after than appear the on the console screen just the Apple logo. I tried many install guid but not helped for my case.
Does have somebody any idea?
Add “-v” (verbose) to the boot arguments so you can see where the boot process stops.
Which CPU do you have?
Thanks for this great Guide. It worked all perfectly, although I made a little mistake at first ( I had added the mouse and keyboard at the beginning of the file instead of the end). Btw I made it running with El Capitan.
Almost there, running on prox 4.3 w/Sierra
It boots, I see the Apple gray screen and then fails and cycles back to boot.
With -v I see:
Attempting to load drivers from standard repositories:
-Third parth extensions…
-Apple extensions search path: ….
I did get it to boot, required:
at the bootloader prompt
Probably you were missing the /Extra directory then.
Got this message when running on a real mac with that c program. Any ideas?
You’ve got it, that funny text is the OSK.
can’t get the key 🙁 the c script or apple is preventing it.
ok… so that is the key… pff very nice
Has anyone tried to create two macOS VMs using this guide? I successfully created the first one using these instructions and the gparted workaround (thank you @micah!).
However, when I tried to create a second one and set the hard disk to IDE3 I get the following errors:
kvm: -drive file=/var/lib/vz/template/iso/Install_macOS_Sierra.iso,if=none,id=drive-ide2,format=raw,cache=none,aio=native,detect-zeroes=on: file system may not support O_DIRECT
kvm: -drive file=/var/lib/vz/template/iso/Install_macOS_Sierra.iso,if=none,id=drive-ide2,format=raw,cache=none,aio=native,detect-zeroes=on: Could not open '/var/lib/vz/template/iso/Install_macOS_Sierra.iso': Invalid argument
TASK ERROR: start failed: command '/usr/bin/kvm -id 102 -chardev 'socket,id=qmp,path=/var/run/qemu-server/102.qmp,server,nowait' -mon 'chardev=qmp,mode=control' -pidfile /var/run/qemu-server/102.pid -daemonize -smbios 'type=1,uuid=7a065ba4-4094-46df-bb8f-81c82d0da7ed' -name macUL -smp '4,sockets=1,cores=4,maxcpus=4' -nodefaults -boot 'menu=on,strict=on,reboot-timeout=1000,splash=/usr/share/qemu-server/bootsplash.jpg' -vga std -vnc unix:/var/run/qemu-server/102.vnc,x509,password -cpu 'Penryn,+kvm_pv_unhalt,+kvm_pv_eoi,enforce,vendor=GenuineIntel' -m 16096 -k en-us -device 'isa-applesmc,osk=...' -smbios 'type=2' -kernel /var/lib/vz/template/qemu/enoch_rev2839_boot -cpu 'Penryn$,kvm=off,vendor=GenuineIntel' -device 'pci-bridge,id=pci.2,chassis_nr=2,bus=pci.0,addr=0x1f' -device 'pci-bridge,id=pci.1,chassis_nr=1,bus=pci.0,addr=0x1e' -device 'piix3-usb-uhci,id=uhci,bus=pci.0,addr=0x1.0x2' -device 'virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x3' -iscsi 'initiator-name=iqn.1993-08.org.debian:01:e4db2db2c99' -drive 'file=/var/lib/vz/template/iso/Install_macOS_Sierra.iso,if=none,id=drive-ide2,format=raw,cache=none,aio=native,detect-zeroes=on' -device 'ide-hd,bus=ide.1,unit=0,drive=drive-ide2,id=ide2' -drive 'file=/dev/zvol/rpool/data/vm-102-disk-1,if=none,id=drive-ide3,cache=writethrough,format=raw,aio=threads,detect-zeroes=on' -device 'ide-hd,bus=ide.1,unit=1,drive=drive-ide3,id=ide3,bootindex=101' -netdev 'type=tap,id=net0,ifname=tap102i0,script=/var/lib/qemu-server/pve-bridge,downscript=/var/lib/qemu-server/pve-bridgedown' -device 'e1000-82545em,mac=DE:12:FF:22:F6:6B,netdev=net0,bus=pci.0,addr=0x12,id=net0,bootindex=300'' failed: exit code 1
The emulated IDE device only supports two disks, IDE0 and IDE2. Try attaching it to SATA0 instead!
It’s also complaining that the ISO that you have mounted doesn’t exist.
@nick Thank you very much for writing back! i checked and made the changes you suggested then tried to run the VM again with the same errors. The iso is still in the directory that I originally placed it in when I successfully set up the first macOS VM: “/var/lib/vz/template/iso/Install_macOS_Sierra.iso”.
i also followed your suggestion and tried using SATA0 as the new mounting point for the hard disk.
Can you please review the screenshots of my errors and the location of the iso file to see if anyone might be able to pick up something I missed:
Many thanks in advance!
Can you post your vm’s configuration file?
@nick thank you very much for writing back. here is the vm’s conf file:
args: -device isa-applesmc,osk="..." -smbios type=2 -kernel /var/lib/vz/template/qemu/enoch_rev2839_boot -cpu Penryn$
Hm, normally there’s a size argument on the end of the iso line, maybe try removing that line and re-adding it using the GUI? Apart from that I can’t see any issues, assuming that your args line does not actually end in a $ sign.
@nick thank you very much for your help. found 3 reasons why it was not working: (1) i am an idiot and Nano NOOB. didn’t realize that “$” was a continuing line flag in Nano. pulled it up in good ol VI and fixed the arg line (2) i added the size argument at the end of the iso line. not sure if that made a difference (3) i had to add the “cache=writethrough” option for the device that the macOS iso is in (IDE2). thank you again!
Thanks a lot for your tutorial, very helpful and well explained.
I just have one final issue you might be able to help. My screen resolution (on proxmox but especially using Screen Sharing from a Windows client) is very low. If I try to change the macos settings, I have only one option (1024×768).
Any idea how to fix this?
Thank you very much
I was able to do this by updating to UEFI boot, then setting the desired resolution in both the UEFI settings and in Clover’s settings. The instructions for updating to UEFI boot are in one of my other blog posts.
Thanks, I will check that as soon as I can, however I am running proxmox on a remote dedicated server, pretty sure the graphic card won’t support it 🙁
If some other people have the same issue, just doing this enabled to change the resolution easily:
Edit the file /Extra/org.chameleon.boot.plist, and either add (or adjust) the file to contain the following:
Figure I should post on here for future generations. I got this working on proxmox ve 4.4 with sierra and a zfs subvol. Disk utility didn’t show up, so in the end I found a USB harddrive that was approximately the size I wanted. Then I ran dd if=/dev/sdl of=/dev/zvol/backup02/proxmox/vm-103-disk-1 bs=64k. If you try this, you’ll have to change the sdl to your usb drive and the path to your zvol.
It appears the OSK code you get when you’re running a Hackintosh isn’t sufficient to boot the ISO generated in the first step even though it is a legit download from the App Store as I’m getting a kernel panic when it attempts to read the DSMOS to authenticate that it’s running on real Apple approved hardware.
Normally on a Hackintosh, you would use FakeSMC.kext to bypass this but I’m not certain how to do that in this case. Anyone else in the same boat been able to bypass this and get it to boot?
Every boot it asks me which device to boot from. How can I change that so it automatically selects the right device?
The boot wait period should have been set by that Enoch Chameleon plist file that was copied to /Extra. It looks like that file is documented here:
Looks like QEMU’s emulation of the SMC is detected as not-a-real-mac in 10.12.4, halting boot. Here’s a fix:
I gave up on the efi approach and am trying the bios based way. When i try to launch the virtual machine i get:
kvm: -drive file=/var/lib/vz/template/iso/InstallMacOSSierra10_12_3.iso,if=none,id=drive-ide2,format=raw,cache=none,aio=native,detect-zeroes=on: file system may not support O_DIRECT
kvm: -drive file=/var/lib/vz/template/iso/InstallMacOSSierra10_12_3.iso,if=none,id=drive-ide2,format=raw,cache=none,aio=native,detect-zeroes=on: Could not open ‘/var/lib/vz/template/iso/InstallMacOSSierra10_12_3.iso’: Invalid argument
TASK ERROR: start failed: command ‘/usr/bin/kvm -id 103 -chardev ‘socket,id=qmp,path=/var/run/qemu-server/103.qmp,server,nowait’ -mon ‘chardev=qmp,mode=control’ -pidfile /var/run/qemu-server/103.pid -daemonize -smbios ‘type=1,uuid=54406dd1-3ad8-40ba-8f6c-46faea2f8cb7’ -name osXsierraServer -smp ‘4,sockets=1,cores=4,maxcpus=4’ -nodefaults -boot ‘menu=on,strict=on,reboot-timeout=1000,splash=/usr/share/qemu-server/bootsplash.jpg’ -vga std -vnc unix:/var/run/qemu-server/103.vnc,x509,password -cpu ‘Penryn,+kvm_pv_unhalt,+kvm_pv_eoi,enforce,vendor=GenuineIntel’ -m 8192 -k en-us -device ‘isa-applesmc,osk=xxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxxx’ -smbios ‘type=2’ -kernel /var/lib/vz/template/qemu/enoch_rev2877_boot -cpu ‘Penryn,kvm=off,vendor=GenuineIntel’ -readconfig /usr/share/qemu-server/pve-q35.cfg -device ‘usb-tablet,id=tablet,bus=ehci.0,port=1’ -device ‘virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x3’ -iscsi ‘initiator-name=iqn.1993-08.org.debian:01:c1c7f7f43413’ -drive ‘file=/dev/zvol/rpool/data/vm-103-disk-1,if=none,id=drive-ide0,format=raw,cache=none,aio=native,detect-zeroes=on’ -device ‘ide-hd,bus=ide.0,unit=0,drive=drive-ide0,id=ide0,bootindex=200’ -drive ‘file=/var/lib/vz/template/iso/InstallMacOSSierra10_12_3.iso,if=none,id=drive-ide2,format=raw,cache=none,aio=native,detect-zeroes=on’ -device ‘ide-hd,bus=ide.1,unit=0,drive=drive-ide2,id=ide2’ -netdev ‘type=tap,id=net0,ifname=tap103i0,script=/var/lib/qemu-server/pve-bridge,downscript=/var/lib/qemu-server/pve-bridgedown’ -device ‘e1000-82545em,mac=xxxxxxx,netdev=net0,bus=pci.0,addr=0x12,id=net0’ -machine ‘type=pc-q35-2.4” failed: exit code 1
is the iso i created screwed up? or is it the version of enoch that i wget’ed?
Change the cache setting on the hardware tab for the ISO to “writeback (unsafe)”
that gives me:
qemu: invalid kernel header
TASK ERROR: start failed: command ‘/usr/bin/kvm -id 103 -chardev ‘socket,id=qmp,path=/var/run/qemu-server/103.qmp,server,nowait’ -mon ‘chardev=qmp,mode=control’ -pidfile /var/run/qemu-server/103.pid -daemonize -smbios ‘type=1,uuid=54406dd1-3ad8-40ba-8f6c-46faea2f8cb7’ -name osXsierraServer -smp ‘4,sockets=1,cores=4,maxcpus=4’ -nodefaults -boot ‘menu=on,strict=on,reboot-timeout=1000,splash=/usr/share/qemu-server/bootsplash.jpg’ -vga std -vnc unix:/var/run/qemu-server/103.vnc,x509,password -cpu ‘Penryn,+kvm_pv_unhalt,+kvm_pv_eoi,enforce,vendor=GenuineIntel’ -m 8192 -k en-us -device ‘isa-applesmc,osk=xxxxxxxxxxxxx’ -smbios ‘type=2’ -kernel /var/lib/vz/template/qemu/enoch_rev2877_boot -cpu ‘Penryn,kvm=off,vendor=GenuineIntel’ -readconfig /usr/share/qemu-server/pve-q35.cfg -device ‘usb-tablet,id=tablet,bus=ehci.0,port=1’ -device ‘virtio-balloon-pci,id=balloon0,bus=pci.0,addr=0x3’ -iscsi ‘initiator-name=iqn.1993-08.org.debian:01:c1c7f7f43413’ -drive ‘file=/dev/zvol/rpool/data/vm-103-disk-1,if=none,id=drive-ide0,format=raw,cache=none,aio=native,detect-zeroes=on’ -device ‘ide-hd,bus=ide.0,unit=0,drive=drive-ide0,id=ide0,bootindex=200’ -drive ‘file=/var/lib/vz/template/iso/InstallMacOSSierra10_12_3.iso,if=none,id=drive-ide2,cache=unsafe,format=raw,aio=threads,detect-zeroes=on’ -device ‘ide-hd,bus=ide.1,unit=0,drive=drive-ide2,id=ide2’ -netdev ‘type=tap,id=net0,ifname=tap103i0,script=/var/lib/qemu-server/pve-bridge,downscript=/var/lib/qemu-server/pve-bridgedown’ -device ‘e1000-82545em,mac=xxxxxxxxxxxx,netdev=net0,bus=pci.0,addr=0x12,id=net0’ -machine ‘type=pc-q35-2.4” failed: exit code 1
Double check your enoch_rev2877_boot file, maybe you downloaded the github webpage rather than the raw file?
whops! yes i did
then i figured out that my os x iso was bad so i remade that! whew boots to the installer 🙂
Still waiting for root device
Over and over. Not sure what is wrong …
When I run sudo ./create_install_iso.sh it asks for a password?
Can I get some help
Your account needs to be an administrator, then you can just enter your Mac account password there.
For those who are still having issues with not being able to access Disk Utility on startup when installing macOS Sierra, try installing El Capitan, first. Run Disk Utility to create a Journaled HFS+ partition and Terminal from the El Capitan install then stop the install from there and then proceed to install macOS Sierra. You will have to use a different “Enoch” boot file and specify a “core2duo” processor when running the El Capitan install.
Has anyone tried using “VirtIO” or “SCSI” as the bus device to run a macOS VM?
This is a great and working project. Takes some sweat but it is worth it. One thing I’ve noticed on first install is that the geek bench 4 benchmarks for AES are very very low. (10% of where they should be). Compared to a vmware system on same hardware. Yet, all other benchmark performance beats vmware hands down. Running this on an intel NUC – Intel NUC NUC5i5RYK – any ideas? I’ve tried a few different CPU options in proxmox.
I believe this is because the emulated CPU is set to Penryn. AES acceleration instructions were introduced several generations later, in Westmere/Sandy Bridge. I haven’t been able to get macOS to boot with the CPU (in the args: line) set to anything newer than Penryn. Let me know if you get this working!
I had this working on a previous Proxmox build but had a drive issue and had to rebuild. having an issue getting OSX installer to boot for some reason. I am also getting stuck at the grey boot screen w/ apple logo. Below is my conf file. would anyone have any idea what i might be missing or doing wrong?
args: -device isa-applesmc,osk=”-removed-” -smbios type=1 -kernel /var/lib/vz/template/qemu/enoch_rev2889_boot -cpu c$
EDIT: ok ignore me. i had the core2duo for my cpu so once i changed to what was called our above it boots fine. sorry for the confusion. is there any benefits to using enoch for a boot partition compared to something like clover
ok ignore me. i had the core2duo for my cpu so once i changed to what was called our above it boots fine. sorry for the confusion. is there any benefits to using enoch for a boot partition compared to something like clover?
Enoch requires less configuration and fiddling around to successfully boot Sierra. Also I don’t think I’ve ever been able to boot the install DVD with Clover.
You need Clover if you want to boot in UEFI mode though, which is recommended for graphics card pass-through.
My installer was freezeing several times at about 15 min left….This happened when providing more than 4’096MB of RAM to the VM. Install with up to 4’096 MB RAM and works fine….above it rais an error like “error extracting “Essentials.pkg”…
hello ,when i install mac os sierria 10.12
on window 7 64 bit ,cpu is core 2 TM 1.86 GHZ With 4 GB RAM
it show error thread 0crashed
i already add smc.version = 0 and also cpu id .emx………..
This is the wrong place to ask for this problem, this tutorial is about Proxmox.
If you mean the Core 2 Duo E6300, it’s not compatible with Sierra as it is missing SSE4.1.
Just installed El Capitan following these instructions on Proxmox 5.0-30. It boots, went through the initial setup, and I was able to enable screen sharing (I’m just going to use it remotely). Ran into a couple of issues–one very small, the others a little larger:
1. The release of Enoch downloaded from github is newer than what appears in the instructions above (it’s now enoch_rev2889_boot). Not a big deal at all, but it meant the config file edits needed updating.
2. The system won’t boot automatically; I need to select the boot device from the boot menu every time. A little annoying, but I don’t expect to be rebooting the VM very often.
3. I can’t log into the App Store, getting the “device or computer could not be verified” message. Notes above indicate that the NIC needs to be called en0, which it is. Also indicating that the PCI root needs to be set, which it seems to be:
OSX-VM:/ dan$ cat org.chameleon.Boot.plist
OSX-VM:/ dan$ ifconfig
lo0: flags=8049 mtu 16384
inet6 ::1 prefixlen 128
inet 127.0.0.1 netmask 0xff000000
inet6 fe80::1%lo0 prefixlen 64 scopeid 0x1
gif0: flags=8010 mtu 1280
stf0: flags=0 mtu 1280
en0: flags=8863 mtu 1500
inet6 fe80::9c0c:33ff:fe72:e333%en0 prefixlen 64 scopeid 0x4
inet 192.168.1.124 netmask 0xffffff00 broadcast 192.168.1.255
inet6 2603:3022:901:32f0::1027 prefixlen 60 dynamic
media: autoselect (1000baseT )
Got it. Though I thought I used the specified command line exactly, I copied the contents of /Extra to /Volumes/Main, rather than copying the directory itself. When I created /Extra and put org.chameleon.Boot.plist in there, issues 2 and 3 above were resolved. Thanks for the detailed instructions!
When installing macOS Sierra on the Proxmox virtual machine, I get an error saying that macOS cannot be installed on my computer. It continues to tell me how to check my hardware on my mac. Does the issue have to do anything with my virtual hardware or is it something else?
Check that you’ve assigned enough disk space and memory to the VM. Also, which CPU do you have? Sierra has a minimum requirement of Penryn due to its SSE4.1 requirement.
I’m running this on an HP Z400 with an Intel Xeon W3565. I also have a 900 gb virtual hdd assigned to the VM and 8gb of ram. I can install El Capitan but I was having issues with graphics and it wouldn’t boot from Clover, so I decided to try Sierra again and ask for your advice.
Thanks for your guide! I was able to install Sierra with this and it works great. I was trying to do another VM with El Capitan on it, but I can’t get the installer to work. I get a gray screen with the Apple logo on it. I rebooted and tried the -v option and it stucks at the same place everytime, right after:
[ ACPI PATCHER ]
Adding booter spec to the platform Expert
Attempting to load drivers from the standard repositories:
– Third party extensions search path: /Library/Extensions
– Apple extensions search path: /System/Library/Extensions
then I see O o O o like something is loading and then it stops and hangs there. Anybody has seen this problem?
Amazing tutorial! Made me move to Proxmox!
1. Did you try proxmox on MacBook Pro? CPU is virtualization capable there…
2. What is your main server setup? Same ASRock and 2x 32 Xeon?
3. I have a problem w proxmox terminal freezing till I hard restart server (I think it’s USB/keyboard coz cursor is blinking). Any idea? I guess it is not BIOS related problem w screen freezing? Isn’t it?
Looking forward to future tut releases and will move to PVE 5 soon!!!
Haven’t tried it on a macbook, that’d be neat!
Asrock EP2C602 and two E5-2670s.
Hm, I haven’t had that terminal freeze before. I do lose keyboard access once I pass through my USB controller to the guest. Consider controlling Proxmox over SSH from a phone or another machine as a backup.
regarding terminal freez: yep – I guess that´s the issue, all 3 keyboards are lost connection ((
but it´s ok, will leave it till next build w PVE 5
I found a new issue – only 2 monitors are working on my r9-280x ((
internet mostly says it´s a framebuffer, but this link (last post) says IGPU have to be enabled or Clover have no issues.
Update to Clover seems to fix it perfectly!
i’ve succesfully installed 10.12.3 (the newer doesn’t works due the SMC problem and i can use your qemu since my proxmox has a newer version with that patch). However my question is. Since i’m using it on an HP Server with a “stupid” graphic card, is there a way to use a screen resolution higher than 1024×768? Is there a qemu switch or setting to use?
Your QEMU version is newer than my patched copy? You can probably just install it anyway and accept the downgrade to the older QEMU version. I do update that package occasionally, so maybe I’ll update it to the newest version in the next week.
You can achieve a higher resolution if you’re using Clover as a bootloader in UEFI (OVMF) mode: set Clover’s UI screen resolution setting to 1920×1080 (using Clover Configurator), then reboot and change the screen resolution in the UEFI options to match (press escape during booting to enter UEFI settings).
My Clover install guide for Sierra is here: http://www.nicksherlock.com/2016/11/using-clover-uefi-boot-with-sierra-on-proxmox/