Qonfused / OSX-Hyper-V

OpenCore configuration for running macOS on Windows Hyper-V.
https://github.com/Qonfused/OSX-Hyper-V
BSD 3-Clause "New" or "Revised" License
212 stars 11 forks source link

Unable to start VM #21

Open owaingeek opened 5 days ago

owaingeek commented 5 days ago

When attempting to start the VM, the screen just flickers the Hyper-V logo and turns off. Screen cap is below: https://drive.google.com/file/d/1bTqvy4Bg9l8WsxFIvlfjzW9D6548GgEv/view?usp=sharing

Qonfused commented 5 days ago

What virtual disks do you have connected to the VM? I'd double check that boot order under the hardware section for 'SCSI Controller' prioritizes the EFI virtual disk:

  • Navigate to 'SCSI Controller' and add a new hard drive for your EFI VHDX (and installer VHDX if applicable).
  • You'll need to attach your EFI VHDX with a location value of 0 and change the location value for your main virtual hard disk to a different value (e.g. 1 or 2). This is to ensure that the EFI disk is the first disk in the boot order.

If you have your com.apple.recovery.boot macOS base image on the EFI virtual disk, that is also fine.

owaingeek commented 5 days ago

Hiya, I did have my EFI on 0 and my main virtual hard disk on 1. I also had my com.apple.recovery.boot image on the EFI disk also.

owaingeek commented 3 days ago

Hi, Is there an update with this? Thanks

Qonfused commented 2 days ago

Sorry, I had meant to follow up sooner.

What does your EFI disk look like? If you created it manually, I'd make sure that there exists an EFI folder on that disk so that the root has both directories:

com.apple.recovery.boot/
EFI/
owaingeek commented 2 days ago

Hi, EFI does exist. I used the already created one on the GitHub.

Qonfused commented 2 days ago

I'd try cloning this repository and running the build script with .\scripts/build.ps1. This uses a much more modern configuration than the v0.1.0 release (from February) and should better help with debugging.

It'll create a dist/ directory where you can also run the create-virtual-machine.ps1 script from:

# Build the repository
.\scripts\build.ps1

# Use the latest version of macOS (cpu=2 cores, ram=8 GB, size=50 GB)
$ .\dist\Scripts\create-virtual-machine.ps1 -name "My New Virtual Machine"
owaingeek commented 2 days ago

I’ll try again soon. I was having issues with this previously. I will get back to you as soon as possible.

Qonfused commented 2 days ago

The README before wasn't quite correct syntactically for running those scripts (a huge oversight on my part). It was previously missing the .\ at the start which wouldn't be runnable if you tried copy/pasting from it from the README.

owaingeek commented 2 days ago

Hi, this is as far as I am getting now. Still flashing on and off the screen but it says this

image
owaingeek commented 2 days ago

Let me grab a better screenshot.

image
Qonfused commented 1 day ago

What CPU are you using and macOS version are you trying to boot?

If you're using a DEBUG build of the project (which it should by default), you should see an OpenCore log if you mount the EFI virtual disk. I'd upload it here just to verify that OpenCore isn't trying to boot into something else.

It's also possible one of the drivers (under EFI/OC/Drivers) can't run on your CPU. For older CPUs (that don't support RDRAND, i.e. Sandy Bridge and older), you'll need to use HfsPlusLegacy instead of HfsPlus (also refer to https://github.com/Qonfused/OSX-Hyper-V/issues/7#issue-2240654974 if booting a legacy macOS version). If that's the case you just change this line to HfsPlusLegacy and create a new virtual machine from the new build: https://github.com/Qonfused/OSX-Hyper-V/blob/f0e99b5695b1bd6ae571e79c1bccaa4d623fabfb/src/build.yml#L11-L12

owaingeek commented 1 day ago

It's an Ivy-Bridge CPU, I will try that now.

owaingeek commented 1 day ago

That worked, this is now as far as I get now

image