Install ubuntu on an external drive using macOS

If you are using mac hardware, but also want to use ubuntu, you can install ubuntu on an external hard drive without risk to remove your macOS. Here is how to do it without screw up your bootloader:

  1. Plugin your external SSD/HDD. Open Disk Utility and format it to MS-DOS (FAT)
  2. Open Terminal window and run: diskutil list

Then you can find your external hard drive IDENTIFIER, e.g. disk2 in this example.

3. Install Virtualbox: https://www.virtualbox.org/

4. Run the 2 command below and start virtual box with admin right:

$ sudo VBoxManage internalcommands createrawvmdk -filename bootcamp.vmdk -rawdisk /dev/disk2 
$ sudo /Application/VirtualBox.app/Contents/MacOS/VirtualBox

5. Select New and click on Expert Mode. Select “Use an existing virtual hard disk file.

6. At the System tab, check the checkbox “Enable EFI (special OSes only)”

7. At the Storage tab, mount the ubuntu ISO file to the virtual machine, which you can download from here: https://ubuntu.com/download/desktop

8.Start the machine and continue with the installation.

9. After installation, now you are ready to boot from the drive. For mac, you would also need to decrease the Security level and allow booting from external media. Press and hold Command-R immediately after you see the Apple logo and start macOS recovery.

10.Restart your Mac again and press the Option key. You can now choose your drive with EFI label.

Enjoy the ubuntu on apple hardware (and have fun to sort out the driver issue). I hope this worked for you 🙂

Written by Victor Leung who is a keen traveller to see every country in the world, passionate about cutting edge technologies. Follow me on Twitter


Originally published at https://victorleungtw.com.

By Victor Leung

Experience in software development, consulting services and technical product management. Understanding of business and technology with an MBA in Finance and a Master degree in Computer Science. AWS Certified Solution Architect with experience in building products from scratch and serving as a charismatic leader.

Leave a comment

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google photo

You are commenting using your Google account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s

This site uses Akismet to reduce spam. Learn how your comment data is processed.