I recently decided to run Kali Linux on my MacBook. I originally thought I'd just build it into a Virtual Machine (using Parallels), but was concerned that I might not have the control over the hardware that I'd need in order to make Kali effective as a learning environment. So, I set about working on a dual-boot scenario. Needless to say, I failed miserably when I opted to have Kali install Grub and it overwrote my primary Boot Manager on the Mac and rendered the system unbootable (and eventually unrecoverable). Thank goodness for good backups...
WARNING: Do not proceed with any of these steps unless you have the ability to restore a bare-metal backup. Everything I'm doing has the potential to trash all of the data on your computer, requiring a clean installation of macOS and subsequent data recovery from backups. I use a combination of Time Machine, CrashPlan, and Arq to back up my system, you should too.
Dual-booting on a PC is easy: you stick in a LiveCD disk, drum your fingers for a few minutes then let the installer take care of all the difficult stuff. But how does one dual-boot Ubuntu on a Mac? It’s actually not that difficult; there are various guides and how-to’s on the internet. The definitive guide to installing Linux on a Macintosh Includes Installing EFI boot manager Converting Linux for mac Partitioning your hard drive & install.
I hope the above steps were helpful and now you can easily Change Default OS in Dual-Boot Setup, but if you still have any. Selected ubuntu as the main. How to dual boot Tails and ubuntu on usb. October 23, 2020 in Linux, macOS and Everything Not-Windows. Tails operating system. Posted October 23, 2020. So i want to dual boot tails with persistent storage and also have ubuntu installed on a sigle usb. If you want to remove Ubuntu, and find that grub is still hanging around (or somehow end up with an extraneous grub), run the following from macOS. Mkdir mnt sudo mount -t msdos /dev/disk0s1 mnt sudo rm -rf mnt/EFI/ubuntu System upgrades of either macOS or ubuntu may cause refind to lose priority and make it more difficult to dual-boot.
If you're interested in triple booting your MacBook Pro, and Windows is going to be one of the Operating Systems you're going to boot, then take my word for it, this is the only way you want to accomplish this feat.
At a high level, the process goes like this:
To be fair, a lot of my instructions and the guide I initially followed, can be found here. However, several of the steps in that guide I didn't have to use at all, so I'm documenting my process here.
Apple provides a supported method of installing Windows as a dual-boot option for Macintosh owners. There are several advantages to using Apple's process:
Apple's official documentation for Boot Camp is found here.
Follow Apple's instructions for installing Windows, but make sure you create the Windows partition approximately 64GB larger than what you want to end up with for Windows, that space will end up being given to Linux. Adjust if you wish, I used a 196GB partition for Windows 10, then split it into 128GB for Windows and 64GB for Linux (FYI, a Windows 10 installation with Office 365 installed takes up 68GB, so give yourself enough room under Windows).
Note: Apple only supports Windows 8.1, or newer, for hardware released after 2014. There is no way to install an earlier version of Windows using Boot Camp on newer hardware. See this table to check your hardware and what versions of Windows are supported on it.
Now that you have an Apple-supported dual-boot system running macOS and Windows 10 (presumably), it's time to perform the Linux installation.
For the purposes of this article, I'm going to install Kali Linux, that's what I used, but installation with ANY version of Linux should work the same way.
The first step is to shrink the Windows partition to make some space for Linux:
This image is AFTER I did my initial shrink and subsequent installation of Kali linux, you'll have fewer partitions when you do this. I also have an SD card mounted.
The shrinking process took a LONG time (~30 minutes), don't worry about it, let it run to completion and do not interrupt.
After the Volume shrinking process is completed, it's time to download some files to perform the installation; however, you probably want to do this under macOS, so first boot back to your macOS volume and the download them both:
Place all of the rEFInd files (after unzipping) on a removable volume (SD Card, USB drive, or even a secondary HFS+ volume) so you can use it in the next step.
For all macOS versions starting with El Capitan (10.11) Apple has enabled System Integrity Protection (SIP). This security feature of macOS prevents changes to various areas of the Operating System including System-owned files. That means that you cannot install rEFInd directly on drives where SIP is enabled. In order to install rEFInd you will have to boot into Recovery. Make sure the rEFInd files are available on a drive that macOS can see and use, then follow these instructions:
Full installation instructions can be found on the rEFInd site.
You may also want to theme rEFInd to look more 'mac-like'. I used the OSX Standard Theme 1.0 found here. Upate 20200906: This theme's installation instructions ask you to 'replace the EFI folder' in the rEFInd install you just did, it ALSO replaces the more curent version of rEFInd and the cryptographic keys that were provided. You probably shouldn't do that, though your milage may vary on getting this to work. At the time of this article's original publication, they were both the same version, but now, 3 years later, the theme's version of rEFInd is woefully outdated. Use with caution or update the components in the theme with the newer versions. (thank you Phillip!)
Test that rEFInd is installed and operational. Just reboot and you should be taken to the rEFInd boot menu, from there you should be able to boot into either macOS or Windows 10.
Note: rEFInd will automatically find what it believes to be bootable volumes. They probably all won't be bootable, through trial-and-error you should be able to find the correct macOS and Windows 10 volumes. You can then configure rEFInd to ignore some volumes, but save that for after you have everything working properly.
Boot into macOS and have a USB key available to be reformatted, it can be pretty small (small works better), an 8GB drive is perfect.
In order to create a bootable USB drive, you can use the Terminal:
Alternatively, if you want a graphical imaging process, you can use UNetbootin as documented here for Ubuntu (just use Kali or whatever image you want).
You're now ready to install Linux. The reason you had to install rEFInd before installing Linux was that, in my experience, I could not get the standard macOS boot manager to recognize the USB drive I had prepared with Kali Linux. However, if you reboot now, you'll see the rEFInd boot menu. You can then insert your USB drive, then hit ESC to refresh the volumes and you should see the Linux installation drive appear. Select it for booting.
Follow the instructions for installing Linux, making sure to select the correct partition that you created while you were under Windows 10 earlier.
You should now have a triple-booting MacBook Pro. Using rEFInd you can select the appropriate OS and it should boot cleanly on your hardware.
In the event that rEFInd gets clobbered (you'll know, because a power-cycle takes you to the built-in macOS boot manager) you should still be able to boot into Windows, but you'll probably lose the ability to boot into Linux. Just follow the instructions and re-install rEFInd again and it should come back and allow you to boot again.
Dual-booting on a PC is easy: you stick in a LiveCD disk, drum your fingers for a few minutes then let the installer take care of all the difficult stuff.
But how does one dual-boot Ubuntu on a Mac?
It’s actually not that difficult; there are various guides and how-to’s on the internet. But to help clarify the process I thought I would share the method I use.
Whilst I don’t guarantee that it will work for you (although in all honesty it should), be sure to make a back up of anything vital before attempting this. Seriously, do it.
Ready? Let’s begin…
Unlike a typical PC where the GRUB boot-loader is used to present your dual-boot options, Intel Mac users need to install something extra: ‘rEFIt’.
‘rEFIt’ is a visually slick (think BURG) boot-interrupter that allows you to boot between OS X and your Linux distribution(s) of choice.
rEFIt should be installed from within OS X, and doesn’t require the use of too many braincells to accomplish: –
If everything went well you will see the rEFIt boot menu appear on your next restart.
For extra peace of mind create a bookmark to the ‘Troubleshooting section‘ of the rEFIt website incase any issues arise.
The next step is to make some space for your Ubuntu install. I typically do this in OS X because it’s easier.
Be generous when allocating disk space you need as trying to change it later can lead to all sorts of problems.
Once you’re all set you just need to pop your LiveCD into the disk drive and reboot.
Press the ‘C’ after the start ‘chimes’ sound to boot from the Live CD.
If you’re an iMac user using bluetooth peripherals do be aware that these will not work out of the box in Ubuntu, so have a wired keyboard and mouse to hand.
Proceed to install Ubuntu on the ‘free space’ partition you created earlier. Ubuntu may prompt you to install it on freespace (double check the size) or, if it doesn’t or you just want to be super-cautious choose the ‘Advanced’ option from the partition screen.
From here select (check the box under ‘format’) ‘free space‘ and choose the ‘EXT4’ filesystem when asked, and mount point should be set as ‘/’.
The above looks a bit crazy, but once you’re in the partition editor of the LiveCD it’s straightforward.
I should also add that I don’t usually bother adding Swap space but you may wish to.
Once all is done you just need to reboot your Mac and select ‘Linux’ from the REFit bootloader when it appears.
If you’re using a bluetooth keyboard you will need to press a button on your keyboard and wait a second before you are able to select boot entries with rEFIt.
Thanks to Beau for the idea