Skip to content

Instantly share code, notes, and snippets.

@alexanderzjs
alexanderzjs / grub2.md
Created May 19, 2022 07:34
Multiboot USB with grub2 x86_64 UEFI

Multiboot USB with grub2 (Please star it if it helps you!!!)

This gist is for x86_64 (amd64) architecture and UEFI boot mode!

Suppose you have 3 partitions: 1. EFI partition (FAT32); 2. macOS partition (Mac OS Extended); 3. WinPE and multiple Linux distros partition (FAT32).

First of all, you need to install grub2 to your EFI partition. You can go to GNU grub2's official website for documentations. Basically, grub-install.exe --no-floppy --target=x86_64-efi --boot-directory=X:\grub --efi-directory=X:\ will work.

  1. EFI partition should have:
@alexanderzjs
alexanderzjs / rEFInd.md
Last active May 19, 2022 07:25
Multiboot USB with rEFInd x86_64 UEFI

Multiboot USB with rEFInd (Please star it if it helps you!!!)

This gist is for x86_64 (amd64) architecture and UEFI boot mode!

Suppose you have 3 partitions: 1. EFI partition (FAT32); 2. macOS partition (Mac OS Extended); 3. WinPE and multiple Linux distros partition (FAT32).

  1. EFI partition should have: a. rEFInd's files: bootx64.efi, refind.conf and icons folder; b. WinPE's boot files: bcd and bootx64.efi (bcd file needs to be modified according to your WinPE's boot.sdi and boot.wim)
  2. macOS patition should have your macOS image file.