Jump to content
Sign in to follow this  
Followers 0
icefapper

Booting OS X via grub2, _without_ installing clover to a physical disk

9 posts in this topic

Recommended Posts

Hi All!

First, apologies in case this tutorial looks shabby to you; I would be glad to edit it as per your feedback. Now for the actual tutorial!

 

I actually first used this trick to install W7 in Legacy mode to a GPT dsk; MS sure would say installing W7 on a GPT requires UEFI, but the i came across this http://reboot.pro/topic/19516-hack-bootmgr-to-boot-windows-in-bios-to-gpt/page-2?do=findComment&comment=184489

 

Credits then must go to first smart one who came up with the idea, wzyboy

 

This tutorial is aimed towards those users who already have grub2 as their bootloader and don't want to bother install CLOVER alongside it ; sure it is possible through some sorta chainloading thing, but being a total newbie in this matter, I found an arguably much easier, less intrusive way to boot an OS X installation through grub2, and then, with memdisk mojo, through CLOVER. Note please, that this method requires you either have access to an already working OS X installation, or have somewhat working knowledge of dd. So, to sum up, the prerequisites are:

 

Access to working OS X (if it is an OS X just installed on your disk, then you most probably could only boot it throu the media you installed it with)

CLOVER installer

syslinux https://www.kernel.org/pub/linux/utils/boot/syslinux/Testing/

grub2 as the bootloader ;)

 

boot into your OS X; open "Disk Utility", and click on "New Image"; choose a name, like "dmgboot"; its size should be big enough to hold CLOVER; I prodigally chose 120MB; the Format should be "Mac OS X Extended (Journled)"; Encryption must be "None"; Partitions must be "GUID"; "IMAGE FORMAT" must be "read/write";

 

 

 

When you are set, click "Create" and create it!

When created, it must actually be mounted if it already is not (but if it is, you obviously needn't mount it :D )

 

Now, run the CLOVER installer; when asked where to install the bootloader, chose the actual mount point of the dmg that you have created and mounted

when done with the installation, unmount dmg; REMEMBER WHERE IT IS ON YOUR DISK! I would actually recommend you to copy the dmg to / like so :

sudo cp <your dmg> /

 

now, "sudo make" the syslinux you just downloaded; you need the "memdisk" there :)

when done, locate the memdisk; in my case, it's under /syslinux/bios/memdisk/memdisk

 

Now restart! BUT before that, you must know what the "address" of you partition is; in my case, it was the 12th partition on my first dsk, i.e, (hd0,gpt12)

 

in the grub menu, hit 'c'; you'll enter a command-like env.

there, type:

 

linux16 <path to the memdisk>

initrd16 <your OS X partition addr>/path/to/the/dmg/you/just/created

boot

 

for example, mine is:

 

linux16 /syslinux/bios/memdisk/memdisk

initrd16 (hd0,gpt12)/dmgboot.dmg

boot

 

Then, Whoa! the os x will boot!

Share this post


Link to post
Share on other sites
Advertisement

Ok fine, but also you can simply : 1) extract boot from clover 2) copy boot file to OSX partition 3) add to Grub2 the menu item to boot osx

 

menuentry "OS X" {
insmod hfsplus
set root='(hd0,gpt12)'
chainloader /boot
}

Share this post


Link to post
Share on other sites

Ok fine, but also you can simply : 1) extract boot from clover 2) copy boot file to OSX partition 3) add to Grub2 the menu item to boot osx

 

menuentry "OS X" {

insmod hfsplus

set root='(hd0,gpt12)'

chainloader /boot

}

Thanks :) I was so excited about the trick working for W7 that I thought it might be as hard for os x; thanks a lot pard (for proving me wrong  :wink_anim:  )

Share this post


Link to post
Share on other sites

Thanks both, it makes nice reading. But to have 12 partitions on a single disk? Is that a world record?

 

sebus

Share this post


Link to post
Share on other sites

Thanks both, it makes nice reading. But to have 12 partitions on a single disk? Is that a world record?

 

sebus

Haha pretty much i have one  :hysterical:

Share this post


Link to post
Share on other sites

@pippox0

Please help. I have a similar case (laptot Sony Vaio, GPT disk 750GB, EFI partition on /dev/sda3, Windows 10 on /dev/sda5, Ubuntu on /dev/sda7+8+9 and El Capitan on /dev/sda10).

I have copied manually CLOVER folder from the Install USB onto the EFI partition and tried to chainload it from GRUB 2. I have also tried all kinds of alternative methods but...no luck!

Your solution seems promising but HOW do you EXTRACT boot from Clover? I have not seen any such file in CLOVER folder.

 

PS I can boot into El Capitan fine if I boot from USB clover.

Share this post


Link to post
Share on other sites

Ok fine, but also you can simply : 1) extract boot from clover 2) copy boot file to OSX partition 3) add to Grub2 the menu item to boot osx

 

menuentry "OS X" {

insmod hfsplus

set root='(hd0,gpt12)'

chainloader /boot

}

Can you explain the process please ?

Thank you very much

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
Sign in to follow this  
Followers 0

  • Recently Browsing   0 members

    No registered users viewing this page.

  • Similar Content

    • By Pentothal.Z
      Hello all,
      I have a working hackintosh....ok.....but it takes a lot to boot and according to the boot.log there are a few problems.
      One of them is a black screen that stays on for a long time.
      I would like to ask anyone in this community some help to fine tune my machine.
      Boot.log and config.plist attached


      Any help would be appreciated.
      bootlog.txt
      config.plist
    • By Magnality
      I've been happily using macOS Sierra 10.12.6 (16G29) successfully for more than a year (all things working), but now I replaced my old Asus GTX 750 Ti card with a new Zotac GTX 1060 6GB, and it get stuck on boot just before going to the login screen (verbose boot screen attached).
       
      I've updated Clover with all its kexts, and reinstalled the Nvidia Web Drivers (using nvidia-update script), but it's still stuck in the same part. I can only enter using nv_disable=1
       
      My current Hackintosh specs:
      Motherboard MSI H110M Gaming (MS-7994) (LGA 1151/Intel H110/DDR4/SATA 3 & USB 3.1) CPU Intel Core i5-6600 6M Skylake Quad-Core 3.3 GHz LGA 1151 65W RAM HyperX FURY 16GB (2 x 8GB) DDR4 2133 (PC4-17000) HX421C14FBK2/16 Video Zotac GTX 1060 6GB SSD Samsung SSD 850 EVO 250GB HDD Western Digital Black 1TB (32MB Cache) (WDC WD1001FALS-00J7B1)  
      I've read that maybe it can be fixed patching the DSDT, but I don't know how to do it.
       
      My RunMe.app generated zip file and verbose boot screen are attached.
       
      Any kind of help is appreciated. Thanks.
      Send me Coke-iMac.zip

    • By SoThOr
      This was spurred on from a discussion in the Clover General thread. Where there was a debate on bcdedit being able create/read/edit (U)EFI Boot entries. I didn't think it appropriate to post all this information there and somebody may want to make use of this and its likely to get lost in that massive thread.
       
      Out of curiosity I decided to see if I could create an EFI entry using bcdedit. What can I say I like a challenge.  Whilst is not a documented method by Microsoft, as it turns out in a round about way it IS possible to create an EFI entry using bcdedit and these are the steps I went through to add UEFI Shell located on a USB stick to the EFI entries. 
       
      Third party software is available that can create and edit UEFI entries from Windows with better support and more features. I'm just making this information available in case those options are unavailable. 
       
      DISCLAIMER - This is not a supported method. Use at your own risk. I recommend backing up your BCD/Firmware variables/settings beforehand.
       
      1) Copy {bootmgr} entry.
      C:\Windows\System32>bcdedit /copy {bootmgr} /d "UEFI Shell" The entry was successfully copied to {34e8383c-73a7-11e9-9cb0-94de8078a7b5}. 2) Edit the new entry using the new GUID bcdedit generated in the copy step.
        a) Set the device and path for UEFI shell on my USB stick.
      bcdedit /set {34e8383d-73a7-11e9-9cb0-94de8078a7b5} device partition=G: bcdedit /set {34e8383d-73a7-11e9-9cb0-94de8078a7b5} path \EFI\SHELL\SHELLX64.efi   b) Clean up some of the stuff that was copied from {bootmgr} (optional as far as I can tell, just makes things tidier in bcdedit)
      3) Put the new EFI entry first in boot order. (optional)
       
      After completing the steps above, here is what "bcdedit /enum firmware" shows:
       
      I shutdown my computer and when I turned my computer back on it booted up into UEFI Shell. After exiting the shell my PC went on to boot Windows.
      Here is the resulting dump using "bcfg boot dump -v" from that shell:
       
      You may notice that the shell shows as "Windows Boot Manager" in the bcdedit output. This I believe is because of the "WINDOWS" at the beginning of the option data that bcdedit added to the EFI Boot entry. I also believe this why bcdedit shows my Windows 8 installation as "Firmware Application" because it has no option data. I don't know how to remove this data using bcdedit nor do I know how the option data, that bcdedit adds, will affect other EFI applications.

      There might be a way to create the EFI entry without copying the Windows entry but if there is I'm unable to find any documentation on how one would do so. If you use the create command then it just puts it in the BCD and I'm unaware of a way to tell it to create it in EFI instead, other than by doing the above.
    • By Pericles
      I've been trying to boot MacOS Mojave (10.14.4) after installation on a system I've built.
       
      I was able to successfully install Mojave through my USB, it seemed like the installer recognised my gpu and was working with it in the installation screen as it looked like it was outputting video at 4k resolution. When the computer restarted I then booted into the "Preboot" option on clover twice (the first time I tried the progress bar got to a certain point and then the system restarted) and on the second attempt the progress bar filled up completelly and the mac installer counted down to a restart (which I took as meaning that it had successfully finished the installer). After restarting however I tried to boot into MacOS from the SSD I installed it on, the apple logo showed up with a progress bar that filled up completelly before the screen turned black, then grey with a cursor over the grey screen. Also, it's probably worth noting that the GPU's fans continue to spin from turning the system on, up to the point where the screen turns grey after which they stop spinning.
       
      My system specs are as follows:
      CPU: i5 3470
      GPU: RX 570
      RAM: 16GB DDR3 1600MHz 
      MB: Asrock B75m r2
      SSD: Samsung 850 Evo 250gb
      WiFi/BT: Fenvi FV-T919 PCIE Card
       
      I am thinking that it's probably a gpu related issue as everything about the installation process has gone pretty smoothly up to the point where it's displaying a grey screen at bootup (and not going further). I have attached a photo of the output from rebooting with the verbose bootflag (it's missing one line at the bottom "busy timeout[1], (240s): 'AppleACPICPU'"), after the verbose output stays on the screen for a few minutes the screen then turns grey with the cursor and hangs there.

×