These are notes on installing linux (Fedora Core 17 [FC17]) on the
2011 or 2012 macbook air. They likely apply to other distros as well. In my
case I replaced OS X (10.7- snow lion) with linux, but keeping the
restore partition.
- It works!
- wifi doesn't seem to support ad-hoc mode.
- camera not tested.
- First create a USB boot disk.
- Download your favorite Linux distro ( I used FC 17 live CD ).
- On Mac OS X:
- hdiutil convert -format UDRW -o usbimage.img cd.iso
- diskutil list
- diskutil unmountDisk /dev/diskX
- dd if=usbimage.img of=/dev/diskX
- where X is the usb disk from diskutil list.
- reboot holding down alt. Select the USB disk (labeled windows by Mac)
- Once you are ready to install.
- Choose custom disk layout.
- Create a 200MB or larger fat partition and have it mount as /boot
- Create a swap partition
- Everything else in / (unless you prefer otherwise... )
- You may be able to use LVM as well, but be careful with boot partition.
- Make sure grub2-efi is installed as part of the installation, otherwise
you will need to install it manually after the installation is complete.
- The fat/msdos EFI partition may be separate from the system. If
you go that route, copy over the efi files from /boot (cp -r /boot /msdos)
- At this point, linux should be installed, but you need to make it bootable.
- Boot mac os x into rescue mode
- either hold alt after the mac sound, then select mac rescue
- or hold command-r
- select your language, then find the menu bar, choose the terminal
- Your boot partition should be mounted under /Volumes/Untitled,
if it isn't mount the fat/msdos partition to /Volumes/Untitled.
- bless efi file.
- bless --folder /Volumes/Untitled --file /Volumes/Untitled/boot/efi/EFI/redhat/grub2-efi/grub.efi --setBoot
- alternate syntax is volume instead of folder.
- sync ;; reboot
- You should have booted into a grub shell. If it found the menu
automatically, great your done. If not, do the following:
- you want to execute something like:
configfile (hd0,gpt5)/boot/grub2/grub.cfg
- but you need the correct path to your configfile. To find that
start by typing configfile, then hit tab.
- It should show you what root devices you have. Pick the one that
seems like it contains your boot partition, then type /boot/grub2/grub.cfg
- Use tab for file name completion.
- To save yourself having to type that every time, you can create a custom
grub image. Do the following :
- back up your previous /boot/efi/EFI/redhat/grub2-edi/grub.efi
- replace (hd0,gpt5) with your root device from the previous step.
grub2-mkimage -d /usr/lib/grub/x86_64-efi/ \
-o /boot/efi/EFI/redhat/grub2-efi/grub.efi \
-O x86_64-efi --prefix "(hd0,gpt5)/boot/grub2" \
part_gpt part_msdos lvm fat ext2 chain boot configfile normal minicmd \
linux reboot halt search gfxterm gfxmenu efi_gop efi_uga video loadbios \
gzio video_bochs video_cirrus echo true loadenv all_video test
- make sure to copy the generated efi image to wherever it should be if
that isn't the correct path.
- If you made it here, Congratulations! You now have Linux on your MB(A).
<-- Questions / Comments