This post shows how to boot recent Ubunt based Linux distributions from a USB drive, when using an early-2010 Macbook pro 5,5.
Booting live Linux images from a USB drive is a fairly straightforward process. However, this process becomes notoriously difficult on Apple Macbook laptops because
- Recent Apple computers do not have a BIOS. Rather, they use something known as EFI
- Apple's EFI implementation is a bit.. special, shall we say?.. so even though most modern Linux distributions are capable of booting using EFI, they may not boot on Apple computers
Given the two limitations above, it is nevertheless desirable to have a method to download the .iso CD/DVD image of a Linux distribution you wish to try out, dump it to a USB stick and boot off that stick from your Macbook pro. This post describes the process to do exactly that.
This approach has been tested with elementaryOS (Luna), Linux Mint 17 KDE and Bodhi Linux 3.0 RC1, all of which are based on Ubuntu. At the moment, debian and debian based distributions (incuding Linux Mint Debian Edition) DO NOT work with this method. Debian based distributions will drop you to a GRUB prompt right after boot, instead of proceeding to boot the live image.
The steps below should be carried out on a computer running Linux.
Step 1: Prepare the USB drive
We need a bootable usb drive with a single fat32 formatted partition and a Master Boot Record. To make such a drive, we use the parted tool
- Invoke parted for the USB drive, e.g.
parted /dev/sdi(replace sdi with the appropriate device on your system)
- Display the current partitions with the command
(parted) print Model: Generic Flash Disk (scsi) Disk /dev/sdi: 2076MB Sector size (logical/physical): 512B/512B Partition Table: msdos Number Start End Size Type File system Flags 1 16.4kB 2076MB 2076MB primary fat16 boot (parted)
- Remove the original partition with
- Create a new partition with
mkpart primary fat32 0 2076MB. The last value is the size shown by the
- Create a VFAT(32) filesystem with the command
mkfs 1 fat32
- Mark the partition as bootable with the command
toggle 1 boot.
- The partition table shown by print should look like
(parted) print Model: Generic Flash Disk (scsi) Disk /dev/sdi: 2076MB Sector size (logical/physical): 512B/512B Partition Table: msdos Number Start End Size Type File system Flags 1 512B 2076MB 2076MB primary fat32 boot, lba (parted)
- Exit parted with the command
Step 2: Add the efi loader and Linux
- Mount the newly formatted drive, for example under /mnt
- mkdir -p /mnt/efi/boot
- Copy bootX64.eif to /mnt/efi/boot
- Copy the Linux .iso to /mnt/efi/boot/boot.iso
Step 3: Boot
Insert the USB drive in the Macbook and power it on while holding the Alt/Option key. Choose the option to boot from the USB EFI drive and hopefully, your Linux image will start booting.