acidanthera / bugtracker

Acidanthera Bugtracker
384 stars 44 forks source link

Can't boot BaseSystem (11.4) with SecureBootModel=Default #1712

Closed 82ghost82 closed 3 years ago

82ghost82 commented 3 years ago

I decided to open an issue after writing to the forum, as it seems to me a bug, if it isn't I'm very sorry for having your time wasted.

OpenCore DBG-070-2021-06-07, but tried also with newer version Qemu 6.0. BaseSystem.dmg extracted from InstallAssistant.pkg of Big Sur 11.4, converted to img with dmg2img If SecureBootModel=Default oc bootloops if BaseSystem is choosen, attached log. opencore-2021-06-29-162752.txt If SecureBootModel=Disabled oc is able to boot BaseSystem.

SecureBootModel=Default/Disabled both are able to boot an installation image created with the createinstallmedia.

vit9696 commented 3 years ago
  1. Please provide the one with AppleDebug = YES. It is not clear what is going on here.
  2. Provide a clear explanation of how the installation image was made.
  3. Did this approach work earlier with e.g. 11.3?
82ghost82 commented 3 years ago

Thanks vit9696 for looking at it.

  1. Here attached a log with AppleDebug=true opencore-2021-06-30-052728.txt I'm sharing also the config.plist: config.txt

  2. The whole thing is part of a container of a linux distro, to help user to install a mac os vm with all the hardware emulated with an automatic behavior. It contains two methods to download the BaseSystem.dmg, I slightly modify the code to be able to run them on mac os, outside of the linux container; here are the 2 scripts: fetch2.txt fetch.txt

How I obtained the BaseSystem.img in details: fetch.py is called with the command: python3 fetch.py -v 10.16 -c PublicRelease -p 071-00696 and it downloads InstallAssistant.pkg + other files: InstallAssistant.pkg extraction (in mac os): pkgutil --expand-full ~/Desktop/InstallAssistant.pkg ~/Desktop/extracted/ Double click on SharedSupport.dmg (in mac os) to mount it Browse inside com_apple_MobileAsset_MacSoftwareUpdate Extraction of BaseSystem.dmg which is inside 0ff07e22b367f4fe0f6d2047ad5c917202716c8b.zip Moved BaseSystem.dmg to linux box dmg to img conversion: dmg2img BaseSystem.dmg BaseSystem.img BaseSystem.img is used as installer in qemu

fetch2.py is called with the command: python3 fetch2.py and it downloads directly BaseSystem.dmg from apple, from this address: http://oscdn.apple.com/content/downloads/48/11/071-00704/casmdwchg8570pz1chb2ri5eo07azjygad/RecoveryImage/BaseSystem.dmg Then again: Moved BaseSystem.dmg to linux box dmg to img conversion: dmg2img BaseSystem.dmg BaseSystem.img BaseSystem.img is used as installer in qemu

The issue is with both images.

  1. I never installed mac os from the BaseSystem, I saw a lot of users having bootloops issues, so yesterday I started to look at it, so I don't know if that work with 11.3; I'm trying, just need sometime to download it and test. I will attach a new log if that hangs too.

Let me know if additional info are required.

Thanks

dreamwhite commented 3 years ago

I have a stupid question: have you ever tried using HFSPlus instead of OpenHfsPlus? I had quite similar issue a while ago while trying to install from a internet recovery bootable media :/

82ghost82 commented 3 years ago

have you ever tried using HFSPlus instead of OpenHfsPlus?

Just tried now the legacy version of HFSPlus, same behavior, same log.

vit9696 commented 3 years ago

Well, the issue is that EfiBoot rightly complains that the Apple Secure Boot signature file (System\Library\KernelCollections\BootKernelExtensions.kc.j137ap.im4m) does not exist. For this reason it reboots the platform. What I can say here is that the created installer is essentially corrupted and the fact that it boots without Apple Secure Boot is mere luck.

It's a good question on how to properly download the macOS installer on a non-mac. My personal choice is using macrecovery (bundled with OpenCore) and then going with an online installation. As for a completely offline method I would better ask somebody more familiar with this. E.g. @dhinakg @khronokernel @corpnewt.

1alessandro1 commented 3 years ago

For offline installs, it's a good option to use macadmin scripts, a simple python program to create a read only DMG with the full apple installer:

cd /Users/Shared || exit 1
mkdir macOSInstaller || exit 1
cd macOSInstaller || exit 1
curl -O https://raw.githubusercontent.com/munki/macadmin-scripts/main/installinstallmacos.py || exit 1
sudo python installinstallmacos.py --seedprogram DeveloperSeed
82ghost82 commented 3 years ago

My personal choice is using macrecovery (bundled with OpenCore) and then going with an online installation

mmmm, I tried macrecovery (python3 macrecovery.py download) and there's the same issue: looking at the code it seems the same as the attached fetch2.py (it downloads directly the BaseSystem.dmg). In real fetch2.py has your copyright in the header.

Update: mhaeuser provided info on this non-issue in the forum.

vit9696 commented 3 years ago

Flashing BaseSystem.dmg contents (downloaded from macrecovery) to a media is unsupported, yes. You must put it to com.apple.recovery.boot directory along with the chunklist file. This is how Apple does it.