Being mostly notes to stop me getting frustrated.
Based, in part, from this excellent forum post.
I've always run Linux on my Mac Hardware. I love the physical aspects of the Mac line, but I really can't be bothered with their Play-doh infested software.
Let's assume you have a nice, clean, freshly installed OSX 10.10 Yosemite sat on your MacBook Pro. I'll also assume that you may occasionally want to boot into OSX, so we'll be dual booting with Ubuntu 14.04.
In OSX, open the Disk Utility, select the main disk. We're going to split this in to two parts. Up to you how much you want to dedicate to OSX. Set the 2nd partition to be "Free Space".
Because Apple is a super-special-snowflake, it's not possible to directly install Ubuntu onto the new partition. We need to first install rEFInd. There are specific instructions for Yosemite.
- Download rEFInd.
- Extract it onto your Mac.
- Open a Terminal and navigate to the directory.
- Run this command
sudo ./install.sh --esp
- We need to edit some files. Still in the Terminal
sudo mount -t msdos /dev/disk0s1 /Volumes/esp
- Edit the file "/Volumes/esp/EFI/refind/refind.conf". Change the line
- Save the file. When you reboot, rEFInd should ask you which OS you want to boot to.
Probably the easiest bit! Download the 64 bit version of Ubuntu. I used another Ubuntu machine to create the Boot Disk on a USB stick.
Turn your MacBook off, insert the USB drive, turn the device on. All being well, rEFInd will give you a choice of devices to boot into. You probably want the one which says something like
You should see a grub style boot screen. Use the cursor keys to move down to "Install Ubuntu". Do NOT press enter! Press "e" to edit the boot options.
If you don't do this - your screen will be blank. And a black screen will make you sad.
Remove the words
and replace them with
. Then press the "F10" key to boot.
You'll be taken through the normal Ubuntu installation screen. It's pretty much just clicking "Next" until it is installed.
...With the exception of setting up the partitions!
- Create a 130MB empty partion. Macs get sad if OSX is bundled up next to a proper OS.
- Create a 512MB partition and assign it to "/boot"
- At the end of the free space, create a "Swap" parition. Personally, I use as much swap as there is RAM.
- With the remaining free space, create a partition and assign it to "/".
- Which device to you want to boot from? I chose the partition assigned to "/boot" - that way you go straight into Ubuntu when you start the machine. If you ever need to get into OSX, hold down "alt" while turning the machine on.
Keep clicking next! Eventually Ubuntu will be installed and you can reboot!
When the grub screen comes up, again you'll need to hit "e" to edit the default boot options.
Scroll down to "load_video" and add these lines below it. I don't know what they mean - it's just magic.
outb 0x728 1 outb 0x710 2 outb 0x740 2 outb 0x750 0
That should boot you into Linux. Now we need to make those changes permanent. Open a terminal and run
sudo nano /etc/grub.d/10_linux
Press CTRL+W to find the line containing "gzio".
Add these lines before it, so the new section looks like
echo " outb 0x728 1" | sed "s/^/$submenu_indentation/" echo " outb 0x710 2" | sed "s/^/$submenu_indentation/" echo " outb 0x740 2" | sed "s/^/$submenu_indentation/" echo " outb 0x750 0" | sed "s/^/$submenu_indentation/" echo " insmod gzio" | sed "s/^/$submenu_indentation/"
To apply these changes, run the following commands.
sudo update-grub sudo apt-get update sudo apt-get dist-upgrade
For better fan performance...
sudo apt-get install lm-sensors sudo sensors-detect
Answer yes to all questions. Then:
sudo apt-get install macfanctld
Reboot and enjoy Ubuntu! Everything seems to "just work" - although I'll write another blog post explaining how I've customised it.