Efi Mounter For Mac



A friend recently gave me his old Apple iMac (Late 2006) after it began having graphics issues. Before freecycling it, I wanted to try to boot Linux on it, just for kicks. That turned out to be harder than I imagined it would be…

Download the latest versions of free software, drivers, trial versions, installers and utilities for your EFI digital printers and productivity software. EFI Mounter v3.1 is now available for macOS Catalina, a 32/64-bit version of everyone's favorite EFI Mounter app. Download now from tonymacx86 Downloads - Community Software. Community Software Useful software from other members of the community- not developed by tonymacx86.com Note: for support please refer to the individual developers. Mount or unmount the EFI system partition for any volume with a mouse click. Next to each volume, ESP Mounter Pro displays a 'Mount' button that you get to use whenever you wish to effortlessly open the EFI partition. When the task is completed, you get to view the ESP in a Finder window and unmount it.

There were two main problems:

  1. Some Macs of this era had only 32-bit EFI bootloaders; and
  2. Many Linux distributions are only designed to do 64-bit UEFI boot.
This page describes how I overcame these obstacles. It assumes you are using a Mac to prepare the USB device, but the instructions can easily be adapted for other situations.

If you want to skip the backstory, jump directly to Booting Linux.

Table of contents:

Booting memtest86

The first thing I wanted to try was memtest86. I downloaded the memtest86 bootable USB image, then used diskutil to find and prepare my USB stick, and dd to copy the memtest86 image to my USB device:

Holding down Option while booting brought up the Startup Manager, which allowed me to select EFI Boot. Worked perfectly! (No memory errors, by the way. ;-)

Mount

In fact, there were two EFI Boot entries, which both worked – more on that later.

Examining the memtest86 image

Unlike many of the Linux distribution images, which come as ISO files, memtest86 came already designed for USB booting. Here are some of its properties, information which would later be useful.

Checking the image file itself, notice that it’s actually a hard drive image:

At first its partition layout looked pretty odd to me: I did some reading, and discovered that partition type EE is known as a protective MBR, used when the drive is partitioned using the newer GUID Partition Table (GPT) standard.

The GPT layout looks like:

The GUIDs have some meaning, which is:
GUIDPurpose
EBD0A0A2-B9E5-4433-87C0-68B6B72699C7Basic data partition
Used for storing the majority of data on the device
C12A7328-F81F-11D2-BA4B-00A0C93EC93BEFI System partition
Contains EFI bootloaders, etc

By default, only the data partition is mounted, but one can mount the EFI System partition also:

Here is a listing of the EFI directory from the data partition:

And here is a listing of the EFI directory from the EFI System partition:

Originally I thought that the two EFI Boot entries were explained by having both BOOTIA32.efi and BOOTX64.efi, but now I know that it is caused by having the EFI bootloader in both partitions.

Summary

For this particular image, we have:

  • a protective MBR, within which is
  • a GUID Partition Table, which has two partitions:
    1. a data partition; and
    2. an EFI System partition
  • within each partition is a directory /EFI/BOOT containing EFI bootloaders named
    • BOOTIA32.efi (for 32-bit EFI); and
    • BOOTX64.efi (64-bit EFI).

32-bit vs 64-bit EFI

Efi mounter for mac mojave

One of the first things I checked on this Mac was whether it had a 32-bit or 64-bit processor. The processor is an Intel® Core™2 Duo Processor T7400 which, according to ARK, is 64-bit. So I mistakenly thought that the EFI would be 64-bit, too. Wrong!

EveryMac.com has an excellent list of machines and which processor and EFI they support. There I found that this Mac had a 32-bit EFI.

Another way to find this information is with a command:

Note that you can boot a 64-bit kernel from a 32-bit EFI, provided that the bootloader and kernel support it.

Booting Linux

General procedure

The goal is to get a USB stick with:

  1. a writeable data partition (so we can, eg, make changes to the grub.cfg file); and
  2. a 32-bit EFI bootloader in /EFI/BOOT/BOOTIA32.efi
Most Linux distributions don’t seem to ship a 32-bit EFI bootloader, but Debian does, so we can just rip it out of there.

What doesn’t work: dding the hybrid ISO directly

Your initial thought might be to use dd to write a hybrid ISO (as most Linux distributions come these days) directly to the USB stick, just as you’d do for a PC. That’s going to fail.

The Ubuntu 15.10 (amd64) ISO looks like this:While you could theoretically modify the EFI System partition, there really isn’t enough space on there to put everything. The data partition is ISO9660 format, which some systems might let you mount read-write, but I couldn’t see how in OS X.

Using UNetbootin

By using UNetbootin, one can prepare the USB key for editing. I won’t go into the operation of UNetbootin since I think it’s fairly self-explanatory. (One tip, though: erase the disk in Disk Utility first.)

The new USB disk looks like:

Adding 32-bit GRUB EFI

Now that you have a read-write partition, you can add the 32-bit GRUB EFI bootloader. I took the one from the Debian netinst (“network install”) CD image. From that image, you need:

  • efi/boot/bootia32.efi
  • boot/grub/i386-efi/*
which, conveniently, need to be placed in the exact same location on your USB device. I used 7-Zip to extract the contents from the ISO, but you could use any program you find convenient.

Here are the commands I used:

And that’s it! You now have a USB device that will boot on a Mac with 32-bit EFI.

Odds & sods

There are a couple of quirks I found (not related to EFI booting) which I thought I’d include here for reference.

Video modes

I found it was necessary to edit boot/grub/grub.cfg to include the kernel option nomodeset to prevent the console video from being trashed. I changed the original:

linux /casper/vmlinuz.efi file=/cdrom/preseed/ubuntu.seed boot=casper quiet splash ---
to:
linux /casper/vmlinuz.efi file=/cdrom/preseed/ubuntu.seed boot=casper nomodeset ---

You may find a slightly different command necessary depending on your hardware and kernel release. digium has a good article on their site for this: How to disable the Linux frame buffer if it’s causing problems.

Efi Mounter For Mac

Console-only boots

For somewhat murky reasons, many distributions have switched over to the confusing systemd. On these systems (eg Ubuntu), the text kernel option no longer does what it’s supposed to. (One would think the systemd folks could’ve made it work but I guess they chose not to.)

Anyhow, there is a (much longer and less obvious) option which does work. Add systemd.unit=multi-user.target to your kernel parameters, eg:

linux /casper/vmlinuz.efi file=/cdrom/preseed/ubuntu.seed boot=casper nomodeset systemd.unit=multi-user.target ---

Typically I’ll have a graphical entry and a text entry so I can decide at boot time without having to remember that particular incantation.

References

Recently, I got an issue with my OpenCore EFI partition on my Hackintosh system. I messed up the config.plist and it makes my macOS Catalina Hackintosh won’t boot properly. Fortunately, I have another hard drive with Windows 10 installed on it. So, I can edit my config.plist in the EFI partition and now it works again.

By default, you cannot see the macOS EFI partition from Windows Explorer, even if your macOS hard drive is connected to your PC. But, there is an easy way to mount the macOS EFI partition under Windows 10. I will show you how to do this in a moment.

Mount the EFI partition on Windows 10

Open Windows 10 command prompt as administrator. And then, run “diskpart” command.

Mount Efi Windows 10 Hackintosh

Output:

Next, list the disk

Output

As you can see, I have 5 hard drives connected to my PC. In this case, my macOS/Hackintosh disk is Disk 3. Yours might be different. Now I will select disk 3

Output

As you can see, my Disk 3 is now the selected disk. Next, we will show the partitions in Disk 3.

As you can see, there are 4 partitions in Disk 3. In my case, the EFI partition is Partition 1. It is easy to know which one is the EFI partition. The EFI partition volume size is exactly 200 MB.

Mount Efi Partition Mac Os

Efi mounter for mac os

Now let’s mount the Partition 1 and assign drive letter to it.

Now, open Windows Explorer and you should see your EFI partition is mounted there.

Common Issue

Mac Efi Partition

In some cases, Windows 10 users cannot open the mounted EFI partition and got the error:

Efi Mounter For Mac Os

You don’t currently have permission to access this folder.

Efi Mounter

In case you get this error, I would recommend you to download Explorer ++ program and then run it as administrator. It can open the EFI folder perfectly without issue.