Installing Ubuntu on Mid 2012 Macbook Air
I recently purchased a Macbook Air 2012 and wanted to install Linux on it. However, I had a few hang ups. Here are the steps and some potential bugs I ran into while tying to install Ubuntu 12.04 on my Mid 2012 Macbook Air.
Step 1: Create a USB Bootable ISO disk
Since the Macbook Air doesn’t have a CD drive, and you might not have the optional Super Drive attachment, you’ll need to have to use a USB flash drive to install Linux.
You can create one by following the steps here:
http://www.ubuntu.com/download/help/create-a-usb-stick-on-mac-osx
Note: After your format it, the Macbook Air might give you popup that says the system doesn’t recognize the drive. Don’t worry about this, just hit ignore and proceed to reboot.
Step 2: Install rEFIt or just use alt/option to choose OS
After you create the bootable USB drive for installing Ubuntu, reboot the computer and hold the alt/option key while the screen starts up. After a few seconds, you should see 3 options to choose from: your Machintosh drive; a recovery drive; and a “Windows” drive that has the USB symbol on it. Choose the “Windows” drive — Don’t worry, you didn’t install Windows, it’s just how the system recognizes it.
If you don’t want to hold the alt/option key, you can install rEFit to have an easier boot loader. This is not necessary, but convenient.
Once you have selected the USB “Windows” option, the computer may begin to load into the live menu for Ubuntu, where you can try out the operating system.
When I tried it, however, I got an error message which said “Kernel panic: timer doesn’t work through interrupt-remapped IO-APIC.” If this happens, restart the computer — the work-around is to hit F8 once you’ve selected the “Windows” option, this will take you to the Ubuntu menu. You can attempt to see if “Try Ubuntu without installing” works, but for me it didn’t. Instead, hit F6 to get into the boot options.
You’ll need to add “noapic acpi=off” to the end of the line beginning with “Linux /boot/…” It should be before the line beginning with “initrd”. From here, press F10 to boot.
You should get a “test run” of Ubuntu going from here!
Step 3: Partition the Drive
After getting into the test area, I noticed my mouse and keyboard (integrated) didn’t work with Ubuntu. Hook up an external mouse and keyboard for now, after installation this problem resolved for me.
Before you are ready to install, you’ll need to partition your drive to make room for Ubuntu. If you want Ubuntu as your primary OS (erasing OSX), you can skip this step.
When on the OSX side, go to the Disk Utility and select your main harddrive. Click the partition tab and enter in the size of the OSX drive you want. I allocated 140 to OSX, leaving about 110 for my Ubuntu partition. If you click on the image on the left, it should update, showing empty space below the OSX partition.
Add a partition by pressing the plus sign button below the image. Don’t worry about the format. You can also create a partition for SWAP space (which may be recommended).
Now reboot and follow Step 2 to boot into Ubuntu from the USB drive.
Step 4: Install Ubuntu
On the desktop should be an icon that says “Install Ubuntu”: click on it.
When prompted, choose MANUAL Partition. Select the partition you just made (you can tell by the size).
When you see the partitions, find the one you created and delete it. Then create a new partition of type ext4 using the harddrive space left by the deleted partition. Set the mount point to “/”. If you didn’t create a SWAP partition, you’ll get a warning. If you don’t want a SWAP partition, then just ignore the warning and keep moving.
Using ext4 instead of ext3 can be better for the ssd because it allows you to tune the frequency of writes.
Make sure to check your keyboard as English Macintosh! Otherwise your Mac keyboard may not work with Ubuntu!
Step 5: Resolving the Kernel Panic
If you experienced a kernel panic when trying to install Ubuntu 12.04 on your Macbook Pro or Macbook Air, then you’ll have to update Grub with the added flags as you did for booting from the USB drive.
First boot into the now installed “Windows” on startup — if you use the alt/option, it should look like a normal harddrive now instead of a USB drive. If it takes you to the Ubuntu menu screen, where you can select the OS, press F6 to edit the boot options again. You should be able to get to the desktop again.
Once you’re on your desktop, open up a terminal and type:
“sudo vi /etc/default/grub”
If you don’t know how to edit in vi, use:
“sudo gedit /etc/default/grub”
Find the line that begins “GRUB_CMDLINE_LINUX_DEFAULT” and change it to the following and save it:
“GRUB_CMDLINE_LINUX_DEFAULT=”quiet splash nomodeset noapic acpi=off”
Now update grub using the following command in the terminal:
“update-grub” to update your /boot/grub/grub.cfg file
From now on, your Macbook should boot just fine into Ubuntu!
Step 6: Configuring
If you’re having trouble with the trackpad, I found this site helpful.
It’s a good idea to check that Ubuntu is accessing all your available RAM. To check run “top” in the terminal. You should see “Mem: N total” on the third line, where N is the number of Kb of RAM total. If you expect 8gb of RAM, you should see a number in Kb that equates to about 8gb (it might be a little less). You can quit top by typing “q”.
Here are some additional resources I used to solve the problem:
http://mindbat.com/2008/01/how-to-install-ubuntu-on-mac-pro/
https://help.ubuntu.com/community/MactelSupportTeam/AppleIntelInstallation
If you have more trouble, consult the Ubuntu forums!
August 23rd, 2012 at 5:09 pm
> and is filed under Computer Science.
Installing an operating system isn’t even _remotely_ related to computer science.
August 23rd, 2012 at 6:17 pm
Apple can kiss my butt for putting the Lion recovery partition at the end of the drive in pos 3. Makes upgrading a HD much more involved.