Legacy BIOS MBR 安装黑苹果 High sierra

编辑中:

首先看看机器配置,史前时代 2007——2008年的机器,和 UEFI + GPT 没有半毛钱的关系,够老了。应该很少人比这个还老了。

搞错了。这个CPU最多安装 10.13 High Sierra ,是无法安装Mojave的。

 

Legacy BIOS MBR 安装黑苹果 High sierra_第1张图片

 

先说说原理:

传统的引导过程是:

BIOS →MBR(硬盘首扇区)→PBR(分区首扇区)→Boot file/Boot Blocks → OS init

传统Legacy BIOS中,大部分由操作系统来接管从MBR、PBR的引导过程,不过这个过程一般引导单个独立的OS操作系统。如果要引导多个OS,就需要功能更强大的第三方boot loader。bootloader会接管这个 MBR->PBR->Boot file/boot blocks等整个引导链。

UEFI引导过程:

BIOS →UEFI(GPT / ECP分区内的文件)→ \EFI\BOOT\BOOTx64.EFI  →OS init

关键原理:传统Legacy BIOS是通过加载硬盘首扇区MBR 和 分区首扇区PBR(partition boot recoder)/ DBR (Dos partition boot recoder),通过两个关键的首扇区内的代码传递加载控制权的。而UEFI引导就是BIOS内置 FAT32 的文件系统代码。UEFI-BIOS通过解析GPT分区的磁盘,直接寻找ESP分区,加载运行ESP分区(一般是FAT32文件系统)boot目录下 .efi文件,直接获取系统控制权。

所以,支持 UEFI GPT启动的BIOS,必须满足两个条件:1.内置FAT32文件系统;2.可以识别GPT分区表。显然2008的老主板什么都没有。此时就需要grub2或者Clover之类的第三方boot loader了。

由于苹果只支持GPT的分区引导,所以硬盘必然也是GPT分区。不过没关系,对GPT固然是BIOS支持最好,老主板不支持也没关系,只要MBR/PRB(DBP)内能够支持GPT就能完成GPT的引导。这点Grub2和Clover都支持。

Clover的boot0.s 代码中,https://github.com/Clover-EFI-Bootloader/clover/blob/master/BootHFS/boot0.s

    xor     eax, eax
    mov     [my_lba], eax           ; store LBA sector 0 for read_lba function
    mov     al, 2                   ; load two sectors: MBR and LBA1
    mov     bx, kMBRBuffer          ; MBR load address
    call    load
    jc      error                   ; MBR load error

直接读取两个扇区,sec0-1,sector 0是MBR,而sector 1是GPT head,系统会判别并处理。同样,Grub2也有类似的代码。

 

和普通boot loader不同,clover不仅是一个bootloader,实际上是一个高度可定制挂载的BIOS。它做得远远超过了一般的bootloader。它会内置一些用户所需的信息,占用一些RAM来模拟BIOS,特别是模拟苹果的SMC固件,来骗过操作系统苹果的防盗版系统DSMOS系统。

 

安装:

 

实现的原理就是

BIOS →MBR(硬盘首扇区)→PBR(ESP分区首扇区)→Clover→OS loader

Clover直接接管了MBR扇区,叫 boot0ss,通过boot0导入ESP分区的 clover,再通过clover自身对fat32和gpt的支持,来替代UEFI做同样的工作。达到在Legacy BIOS上启动GPT分区操作系统的效果。

其实即便是UEFI,也无法直接使用Mac OS,还是需要通过引导器比如Clover或变色龙来欺骗OS X加载。

UEFI→Clover→OS loader(Mac OS X/Windows/Linux)

 

Mac OS X 的ECP分区是FAT32分区,这点和Windows FAT16不同。

00000000  eb 58 90 42 53 44 20 20  34 2e 34 00 02 01 20 00  |.X.BSD  4.4... .|
00000010  02 00 00 00 00 f0 00 00  3f 00 ff 00 28 00 00 00  |........?...(...|
00000020  00 40 06 00 67 0c 00 00  00 00 00 00 02 00 00 00  |[email protected]...........|
00000030  01 00 06 00 00 00 00 00  00 00 00 00 00 00 00 00  |................|
00000040  00 00 29 f4 11 60 28 45  46 49 20 20 20 20 20 20  |..)..`(EFI      |
00000050  20 20 46 41 54 33 32 20  20 20 fa 31 c0 8e d0 bc  |  FAT32   .1....|
00000060  00 7c fb 8e d8 e8 00 00  5e 83 c6 19 bb 07 00 fc  |.|......^.......|
00000070  ac 84 c0 74 06 b4 0e cd  10 eb f5 30 e4 cd 16 cd  |...t.......0....|
00000080  19 0d 0a 4e 6f 6e 2d 73  79 73 74 65 6d 20 64 69  |...Non-system di|
00000090  73 6b 0d 0a 50 72 65 73  73 20 61 6e 79 20 6b 65  |sk..Press any ke|
000000a0  79 20 74 6f 20 72 65 62  6f 6f 74 0d 0a 00 00 00  |y to reboot.....|
000000b0  00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00  |................|
*
000001f0  00 00 00 00 00 00 00 00  00 00 00 00 00 00 55 aa  |..............U.|

 

 

 

 

但是Clover 不仅是一个bootloader,实际上是一个可挂载的 BIOS

UEFI其实就是BIOS,只不过是一个可扩展的升级版BIOS。

 

 

  安装过程,这里介绍已经有一台白苹果的环境下操作。

下载资源,https://blog.daliansky.net/macOS-Mojave-10.14.6-18G87-Release-version-with-Clover-5033-original-image.html

这个下载包有一个问题,只支持 UEFI+GPT启动,不支持Legacy BIOS + MBR 启动。需要下载Clover V2.5 R5033的安装包处理一下才可以。

Clover : https://github.com/Dids/clover-builder/releases/tag/v2.5k_r5033 

在 mac os x 下操作

1.制作Mojave启动U盘

sudo /Volumes/Install\ macOS\ Mojave\ 1/Install\ macOS\ Mojave.app/Contents/Resources/createinstallmedia --volume /Volumes/INSTALL --applicationpath /Volumes/Install\ macOS\ Mojave\ 1/Install\ macOS\ Mojave.app --nointeraction

2.制作完U盘安装盘 createinstallmedia命令执行完,U盘会有两个分区,其中之一就是EFI分区。可以发现其中的EFI分区是空的。而源dmg的目录内efi分区包含clover引导程序。

照理使用 Clover的 pkg安装盘直接使用即可,但发现无法安装到U盘的EFI分区上。所以,只能自己动手,原理参照上述。具体的操作命令可以参考 /Volumes/Clover-v2.5k-5033-X64/EFI/CLOVER/doc/boot1f32-install.sh (前面是mount的挂载路径,如有不同自行修改)

记住一个原则:先安装Clover到efi分区,再copy dmg中的覆盖文件。顺序不要搞错,否则老机器 BIOS + MBR的方式的U盘启动无法运行。

3.挂载 clover.iso 和 mojave.dmg,分别在  Volumes  下。

SongYingdeMacBook-Pro:~ SongYing$ ls -l /Volumes/
total 8
drwxr-xr-x@  5 SongYing  staff  170  7 29  2019 Clover-v2.5k-5033-X64
drwxrwxr-x  13 SongYing  staff  510  8  2  2019 Install macOS Mojave
lrwxr-xr-x   1 root      admin    1  3  3 08:46 Macintosh HD -> /
SongYingdeMacBook-Pro:~ SongYing$ 

4.插入U盘,查看一下磁盘位置信息  diskutil list ,我efi分区位置是  /dev/disk2s1。记住这个位置

/dev/disk0 (internal, physical):
   #:                       TYPE NAME                    SIZE       IDENTIFIER
   0:      GUID_partition_scheme                        *120.0 GB   disk0
   1:                        EFI EFI                     209.7 MB   disk0s1
   2:                  Apple_HFS Macintosh HD            119.2 GB   disk0s2
   3:                 Apple_Boot Recovery HD             650.0 MB   disk0s3
/dev/disk1 (disk image):
   #:                       TYPE NAME                    SIZE       IDENTIFIER
   0:      GUID_partition_scheme                        +7.2 GB     disk1
   1:                        EFI EFI                     209.7 MB   disk1s1
   2:                  Apple_HFS Install macOS Mojave    6.9 GB     disk1s2
/dev/disk2 (external, physical):
   #:                       TYPE NAME                    SIZE       IDENTIFIER
   0:      GUID_partition_scheme                        *64.4 GB    disk2
   1:                        EFI EFI                     209.7 MB   disk2s1
   2:                  Apple_HFS Install macOS Mojave    64.1 GB    disk2s2
/dev/disk3 (disk image):
   #:                       TYPE NAME                    SIZE       IDENTIFIER
   0:     Apple_partition_scheme                        +10.2 MB    disk3
   1:        Apple_partition_map                         32.3 KB    disk3s1
   2:                  Apple_HFS Clover-v2.5k-5033-X64   9.9 MB     disk3s2

 4. 修改启动代码的顺序是 MBR boot0   ,PBR boot1  ,根目录启动文件 BOOT,启动文件的名称固定在PBR代码内。

原始的U盘 MBR和PBR,本来就为UEFI引导,只有一个空分区表项,没有引导的程序代码(前440都是00)

#原来的MBR,没有引导程序,只保存分配表的数据参数
SongYingdeMacBook-Pro:~ SongYing$ sudo dd if=/dev/disk2 count=1 bs=512| hexdump -C
1+0 records in
1+0 records out
512 bytes transferred in 0.001378 secs (371537 bytes/sec)
00000000  00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00  |................|
*
000001b0  00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 fe  |................|
000001c0  ff ff ee fe ff ff 01 00  00 00 ff ff 7f 07 00 00  |................|
000001d0  00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00  |................|
*
000001f0  00 00 00 00 00 00 00 00  00 00 00 00 00 00 55 aa  |..............U.|
00000200


#原来的PBR,无法引导,只保存分区的基本参数
SongYingdeMacBook-Pro:~ SongYing$ sudo dd if=/dev/disk2s1 count=1 bs=512| hexdump -C
1+0 records in
1+0 records out
512 bytes transferred in 0.003339 secs (153337 bytes/sec)
00000000  eb 58 90 42 53 44 20 20  34 2e 34 00 02 01 20 00  |.X.BSD  4.4... .|
00000010  02 00 00 00 00 f0 00 00  20 00 10 00 00 00 00 00  |........ .......|
00000020  00 40 06 00 4f 0c 00 00  00 00 00 00 02 00 00 00  |[email protected]...........|
00000030  01 00 06 00 00 00 00 00  00 00 00 00 00 00 00 00  |................|
00000040  00 00 29 ed 17 e3 67 45  46 49 20 20 20 20 20 20  |..)...gEFI      |
00000050  20 20 46 41 54 33 32 20  20 20 fa 31 c0 8e d0 bc  |  FAT32   .1....|
00000060  00 7c fb 8e d8 e8 00 00  5e 83 c6 19 bb 07 00 fc  |.|......^.......|
00000070  ac 84 c0 74 06 b4 0e cd  10 eb f5 30 e4 cd 16 cd  |...t.......0....|
00000080  19 0d 0a 4e 6f 6e 2d 73  79 73 74 65 6d 20 64 69  |...Non-system di|
00000090  73 6b 0d 0a 50 72 65 73  73 20 61 6e 79 20 6b 65  |sk..Press any ke|
000000a0  79 20 74 6f 20 72 65 62  6f 6f 74 0d 0a 00 00 00  |y to reboot.....|
000000b0  00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00  |................|
*
000001f0  00 00 00 00 00 00 00 00  00 00 00 00 00 00 55 aa  |..............U.|
00000200

 

修改 MBR,Clover的boot0,有boot0af、boot0ss、boot0md,一共3个,一般我们用boot0ss

boot0af,适用于混合MBR/GPT分区,启动策略MBR优先 ,搜索MBR分区的活动分区,再搜索EFI分区。

              混合MBR hybrid MBR,详见:https://www.v2ex.com/t/466839

boot0ss,适用于纯GPT分区,启动策略GPT优先。先搜索GPT/EFI分区

boot0md,多硬盘启动。

一般黑苹果默认boot0ss。

# 以下命令要小心操作
#读取U盘 MBR 到 /tmp/mod_MBR.bin 文件

SongYingdeMacBook-Pro:~ SongYing$ sudo dd if=/dev/disk2 of=/tmp/mod_MBR.bin bs=512 count=1
1+0 records in
1+0 records out
512 bytes transferred in 0.001389 secs (368603 bytes/sec)

#提取Clover的MBR引导代码,我选择boot0ss,先查找EFI分区,再检查MBR分区。
SongYingdeMacBook-Pro:~ SongYing$ sudo dd if=/Volumes/Clover-v2.5k-5033-X64/usr/standalone/i386/boot0ss of=/tmp/mod_MBR.bin bs=440 count=1 conv=notrunc
1+0 records in
1+0 records out
440 bytes transferred in 0.000027 secs (16331803 bytes/sec)

#写回MBR
SongYingdeMacBook-Pro:~ SongYing$ sudo dd of=/dev/disk2 if=/tmp/mod_MBR.bin bs=512 count=1
dd: /dev/disk2: Resource busy

#一个插曲,无法写回,因为有挂载分区
#把相关分区全部卸载 
SongYingdeMacBook-Pro:~ SongYing$ diskutil umount /dev/disk2s1
disk2s1 was already unmounted
SongYingdeMacBook-Pro:~ SongYing$ diskutil umount /dev/disk2s2
Volume Install macOS Mojave on disk2s2 unmounted

#再次写回U盘 MBR
SongYingdeMacBook-Pro:~ SongYing$ sudo dd of=/dev/disk2 if=/tmp/mod_MBR.bin bs=512 count=1
1+0 records in
1+0 records out
512 bytes transferred in 0.001849 secs (276916 bytes/sec)

#查看一下内容,引导代码已经写入
SongYingdeMacBook-Pro:~ SongYing$ sudo dd if=/dev/disk2 bs=512 count=1 | hexdump -C
1+0 records in
1+0 records out
512 bytes transferred in 0.002200 secs (232739 bytes/sec)
00000000  fa 31 c0 8e d0 bc f0 ff  fb 8e c0 8e d8 be 00 7c  |.1.............||
00000010  bf 00 e0 fc b9 00 01 f2  a5 ea 1e e0 00 00 66 31  |..............f1|
00000020  c0 66 a3 00 e4 b0 02 bb  00 10 e8 25 01 72 06 be  |.f.........%.r..|
00000030  be 11 e8 09 00 bf a3 e1  e8 4a 01 f4 eb fd 81 7c  |.........J.....||
00000040  40 55 aa 75 5e 31 db fe  c7 b9 04 00 66 8b 44 08  |@U.u^1......f.D.|
00000050  66 a3 00 e4 80 7c 04 00  74 36 80 7c 04 ee 75 05  |f....|..t6.|..u.|
00000060  c6 04 00 b3 01 80 ff 01  75 02 eb 09 80 3c 80 75  |........u....<.u|
00000070  1f 30 f6 eb 14 b6 01 80  7c 04 af 74 0c 80 7c 04  |.0......|..t..|.|
00000080  0c 74 06 80 7c 04 07 75  07 e8 90 00 75 02 eb 14  |.t..|..u....u...|
00000090  83 c6 10 e2 b7 fe cb 75  03 e8 0b 00 fe cf be be  |.......u........|
000000a0  11 74 a6 c3 e9 59 9b 53  bf 00 12 66 81 3d 45 46  |.t...Y.S...f.=EF|
000000b0  49 20 75 66 66 81 7d 04  50 41 52 54 75 5c 89 fe  |I uff.}.PARTu\..|
000000c0  66 8b 44 48 66 a3 00 e4  8b 4c 50 8b 5c 54 53 b0  |f.DHf....LP.\TS.|
000000d0  20 bb 00 14 53 e8 7a 00  5e 5b 0f 82 57 ff 66 8b  | ...S.z.^[..W.f.|
000000e0  44 0c 66 3d 65 43 ec ac  74 10 66 3d c9 3e c9 3b  |D.f=eC..t.f=.>.;|
000000f0  74 08 66 3d b7 26 99 c7  75 1c 66 8b 44 20 66 a3  |t.f=.&..u.f.D f.|
00000100  00 e4 b6 01 e8 15 00 75  0d be be 11 66 89 44 08  |.......u....f.D.|
00000110  c6 44 04 af eb 8e 01 de  e2 c4 5b c3 60 b0 03 bb  |.D........[.`...|
00000120  00 7c e8 2d 00 0f 82 0c  ff 08 f6 74 1d a1 00 80  |.|.-.......t....|
00000130  3d 48 2b 74 15 3d 48 58  74 10 a1 03 7c 3d 45 58  |=H+t.=HXt...|=EX|
00000140  74 08 a1 5a 7c 3d 42 4f  75 06 81 3e fe 7d 55 aa  |t..Z|=BOu..>.}U.|
00000150  61 c3 51 b9 05 00 e8 06  00 73 02 e2 f9 59 c3 66  |a.Q......s...Y.f|
00000160  60 89 e5 1e 1e 66 8b 0e  00 e4 66 51 06 53 30 e4  |`....f....fQ.S0.|
00000170  50 6a 10 89 e6 b4 42 cd  13 73 05 31 c0 cd 13 f9  |Pj....B..s.1....|
00000180  89 ec 66 61 c3 60 57 be  ac e1 e8 06 00 5e e8 02  |..fa.`W......^..|
00000190  00 61 c3 bb 01 00 fc ac  3c 00 74 06 b4 0e cd 10  |.a......<.t.....|
000001a0  eb f5 c3 65 72 72 6f 72  00 00 00 00 0a 0d 62 6f  |...error......bo|
000001b0  6f 74 30 73 73 3a 20 00  00 00 00 00 00 00 00 fe  |ot0ss: .........|
000001c0  ff ff ee fe ff ff 01 00  00 00 ff ff 7f 07 00 00  |................|
000001d0  00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00  |................|
*
000001f0  00 00 00 00 00 00 00 00  00 00 00 00 00 00 55 aa  |..............U.|
00000200

 

修改 EFI 分区的 PBR:

前面提到,EFI本质上是一个 FAT32分区,(Windows 默认是FAT16,但兼容FAT32;但Mac OS X 只支持FAT32)

在前面挂载的Clove ISO内,有 /Volumes/Clover-v2.5k-5033-X64/EFI/CLOVER/doc/boot1f32-install.sh ,参照里面的命令如下:

 

#提取原始 PBR 到 /tmp/orgPRB.bin
SongYingdeMacBook-Pro:~ SongYing$ sudo dd if=/dev/disk2s1 of=/tmp/orgPBR.bin count=1 bs=512
Password:
1+0 records in
1+0 records out
512 bytes transferred in 0.004891 secs (104684 bytes/sec)

#Copy boot1f32 作为新的引导扇区 PBR
SongYingdeMacBook-Pro:~ SongYing$ cp /Volumes/Clover-v2.5k-5033-X64/usr/standalone/i386/boot1f32 /tmp/new_PBR.bin

#提取当前分区数据,注入新的PBR
SongYingdeMacBook-Pro:~ SongYing$ dd if=/tmp/orgPBR.bin of=/tmp/new_PBR.bin skip=3 seek=3 bs=1 count=87 conv=notrunc
87+0 records in
87+0 records out
87 bytes transferred in 0.000639 secs (136158 bytes/sec)

#保存修改,写入U盘分EFI分区
SongYingdeMacBook-Pro:~ SongYing$ sudo dd of=/dev/disk2s1 if=/tmp/new_PBR.bin count=1 bs=512
1+0 records in
1+0 records out
512 bytes transferred in 0.001328 secs (385545 bytes/sec)

#查看一下修改,和先前的原始PBR不一样了,
SongYingdeMacBook-Pro:~ SongYing$ sudo dd if=/dev/disk2s1  count=1 bs=512 | hexdump -C
1+0 records in
1+0 records out
512 bytes transferred in 0.001531 secs (334395 bytes/sec)

00000000  eb 63 90 42 53 44 20 20  34 2e 34 00 02 01 20 00  |.c.BSD  4.4... .|
00000010  02 00 00 00 00 f0 00 00  20 00 10 00 00 00 00 00  |........ .......|
00000020  00 40 06 00 4f 0c 00 00  00 00 00 00 02 00 00 00  |[email protected]...........|
00000030  01 00 06 00 00 00 00 00  00 00 00 00 00 00 00 00  |................|
00000040  00 00 29 ed 17 e3 67 45  46 49 20 20 20 20 20 20  |..)...gEFI      |
00000050  20 20 46 41 54 33 32 20  20 20 42 4f 4f 54 20 20  |  FAT32   BOOT  |
00000060  20 20 20 20 20 fa 66 31  c0 8e d0 bc f0 ff fb 8e  |     .f1........|
00000070  d8 8e c0 a1 0e 7c 66 03  44 08 66 a3 1c 7c 88 16  |.....|f.D.f..|..|
00000080  40 7c 66 31 c0 a0 10 7c  66 f7 26 24 7c 66 a3 24  |@|f1...|f.&$|f.$|
00000090  7c 66 a1 2c 7c 66 ba 00  00 01 00 e8 68 00 72 63  ||f.,|f......h.rc|
000000a0  31 f6 8a 1e 0d 7c c1 e3  09 01 f3 bf 5a 7c 1e 68  |1....|......Z|.h|
000000b0  00 10 1f 8a 0c 84 c9 74  49 b9 0b 00 f3 a6 74 0c  |.......tI.....t.|
000000c0  1f 80 c1 15 01 ce 39 de  74 cb eb df ac a8 18 75  |......9.t......u|
000000d0  ef ff 74 08 ff 74 0e 66  58 1f 66 ba 00 02 02 00  |..t..t.fX.f.....|
000000e0  66 52 e8 21 00 66 5a 9c  66 31 db 8a 1e 0d 7c 66  |fR.!.fZ.f1....|f|
000000f0  c1 e3 09 66 01 da 9d 73  e7 8a 16 40 7c ea 00 02  |...f...s...@|...|
00000100  00 20 1f f4 eb fd 66 3d  f8 ff ff 0f 72 02 f9 c3  |. ....f=....r...|
00000110  66 50 66 31 c9 66 48 66  48 8a 0e 0d 7c 66 52 66  |fPf1.fHfH...|fRf|
00000120  f7 e1 66 5a 66 03 06 24  7c 66 89 c1 30 e4 a0 0d  |..fZf..$|f..0...|
00000130  7c e8 2e 00 72 29 66 59  51 66 c1 e9 07 31 c0 40  ||...r)fYQf...1.@|
00000140  66 ba 00 70 00 00 e8 19  00 72 14 5e 83 e6 7f c1  |f..p.....r.^....|
00000150  e6 02 66 8b 84 00 70 66  25 ff ff ff 0f f8 c3 66  |..f...pf%......f|
00000160  58 c3 66 60 89 c3 66 31  c0 88 d8 83 fb 40 72 02  |X.f`..f1.....@r.|
00000170  b0 40 e8 12 00 29 c3 74  0b 66 01 c1 c1 e0 09 66  |.@...).t.f.....f|
00000180  01 c2 eb e2 66 61 c3 66  60 06 89 e5 89 d3 80 e7  |....fa.f`.......|
00000190  0f 66 c1 ea 04 30 d2 8e  c2 1e 1e 66 03 0e 1c 7c  |.f...0.....f...||
000001a0  66 51 06 53 30 e4 50 6a  10 8a 16 40 7c 89 e6 b4  |fQ.S0.Pj...@|...|
000001b0  42 cd 13 0f 82 4c ff 89  ec 07 66 61 c3 00 00 00  |B....L....fa....|
000001c0  00 00 00 00 00 00 00 00  00 00 00 00 00 00 00 00  |................|
*
000001f0  00 00 00 00 00 00 00 00  00 00 00 00 00 00 55 aa  |..............U.|
00000200

拷贝文件

首先拷贝启动BOOT文件,要确保文件系统的首个拷贝文件是启动文件

#查看磁盘信息,U盘EFI分区是  /dev/disk2s1
SongYingdeMacBook-Pro:~ SongYing$ diskutil list
/dev/disk0 (internal, physical):
   #:                       TYPE NAME                    SIZE       IDENTIFIER
   0:      GUID_partition_scheme                        *120.0 GB   disk0
   1:                        EFI EFI                     209.7 MB   disk0s1
   2:                  Apple_HFS Macintosh HD            119.2 GB   disk0s2
   3:                 Apple_Boot Recovery HD             650.0 MB   disk0s3
/dev/disk1 (disk image):
   #:                       TYPE NAME                    SIZE       IDENTIFIER
   0:      GUID_partition_scheme                        +7.2 GB     disk1
   1:                        EFI EFI                     209.7 MB   disk1s1
   2:                  Apple_HFS Install macOS Mojave    6.9 GB     disk1s2
/dev/disk2 (external, physical):
   #:                       TYPE NAME                    SIZE       IDENTIFIER
   0:      GUID_partition_scheme                        *64.4 GB    disk2
   1:                        EFI EFI                     209.7 MB   disk2s1
   2:                  Apple_HFS Install macOS Mojave    64.1 GB    disk2s2
/dev/disk3 (disk image):
   #:                       TYPE NAME                    SIZE       IDENTIFIER
   0:     Apple_partition_scheme                        +10.2 MB    disk3
   1:        Apple_partition_map                         32.3 KB    disk3s1
   2:                  Apple_HFS Clover-v2.5k-5033-X64   9.9 MB     disk3s2

#挂载 /dev/disk2s1
SongYingdeMacBook-Pro:~ SongYing$ diskutil mount /dev/disk2s1
Volume EFI on /dev/disk2s1 mounted

#copy clover启动文件 boot6 到根目录的 BOOT 文件
SongYingdeMacBook-Pro:~ SongYing$ cp -v /Volumes/Clover-v2.5k-5033-X64/usr/standalone/i386/x64/boot6 /Volumes/EFI/BOOT
/Volumes/Clover-v2.5k-5033-X64/usr/standalone/i386/x64/boot6 -> /Volumes/EFI/BOOT

#至此,EFI分区引导链完成
#BIOS->MBR(boot0ss)->PBR(boot1f32)->BOOT(boot6)

拷贝 Clover 以及驱动资料,dmg文件内

#挂载 mojave+clover dmg文件的EFI分区
SongYingdeMacBook-Pro:~ SongYing$ diskutil mount /dev/disk1s1
Volume EFI on /dev/disk1s1 mounted

#挂载结果,挂载在 /Volumes/EFI 1

SongYingdeMacBook-Pro:~ SongYing$ ls /Volumes/EFI\ 1/
EFI		README.md

#copy 文件
SongYingdeMacBook-Pro:~ SongYing$ cp -R /Volumes/EFI\ 1/* /Volumes/EFI
SongYingdeMacBook-Pro:~ SongYing$ ls -l  /Volumes/EFI
total 899
-rwxrwxrwx@ 1 SongYing  staff  450048  3  3 21:00 BOOT
drwxrwxrwx  1 SongYing  staff     512  3  3 21:10 EFI
-rwxrwxrwx@ 1 SongYing  staff    9488  3  3 21:11 README.md


 

 

Clover 启动成功

 

系统安装:

每个版本有差异。折腾了好久,找到一个版本

资料下载:https://www.dianruan.org/4686.html  MacOS Mojave 10.14.6 18G84原版镜像

用这个作为母盘启动。

注意:fix rtc 否则会改写CMOS,每次都要恢复CMOS。

看了下,这个CPU版本最高支持 10.13 High serria 

参考资料:

 

BIOS + GPT + GRUB + Linux + Windows 折腾笔记 https://blog.csdn.net/o_alpha/article/details/102959192

详解黑苹果引导程序clover小白教程 (分区位置)http://www.tzit.net/htmlitjs/2019-03-27/3387.html

clover教程和机制  https://www.ozmacos.com/3911.html

Clover引导Windows10,Mac OS High Sierra,CentOS7(黑哥) https://blog.csdn.net/qq_43348643/article/details/82956282

SMBIOS/Apple ID 设定 https://zhuanlan.zhihu.com/p/23932863

【让天下没有难装的黑果】3 在legacy传统BIOS下使用CLOVER模拟EFI引导在GPT格式硬盘上安装OS X+WIN双系统 (单/双硬盘) (分区位置分配)  http://blog.sina.com.cn/s/blog_9cdacc870102wtka.html

传统BIOS传统MBR分区,Clover硬盘安装基础教程 http://www.memacx.com/thread-5201-1-1.html

Clover MBR https://github.com/Clover-EFI-Bootloader/clover/tree/master/BootHFS

(启动扇区  MBR/DBR 或者叫 PBR )详解: http://www.360doc.com/content/11/0531/11/1074365_120667417.shtml

grub2 https://wenku.baidu.com/view/77c60ac2d4bbfd0a79563c1ec5da50e2524dd153?pcf=2&re=view

grub2 手册 https://www.cnblogs.com/f-ck-need-u/archive/2017/06/29/7094693.html

 

 

 

 

你可能感兴趣的:(黑苹果,黑苹果,MBR,BIOS)