ROS 2 Setup Guide

An exhaustive guide for installing a ROS 2 development environment

View project on GitHub

Home

https://www.theroboticsspace.com/blog/How-To-Install-ROS-2-in-Ubuntu-22-04-On-M1-Mac/

How To Install ROS 2 in Ubuntu 22.04 On M1/M2 Mac

Table of Contents

The first step is more of a reminder. The Macbooks with M1/M2 Chip are ARM-based platforms compared to older MacBooks and Windows which are AMD/Intel x86-based platforms. Different virtual desktops are available like Parallels Desktop, Oracle’s Virtual Box, and UTM each having its pros and cons.

In this guide, we will use free UTM virtualization software. UTM allows Ubuntu to run with OpenGL, Hardware acceleration providing a highly efficient with near-native speed performance.

Prerequisites

  • MacOS 13 or later
  • 50GB of free space

1. Install UTM

Go to GetUTM and click the Download button. A UTM.dmg file will start downloading.

UTM Download

Once the download is complete, double click on the UTM.dmg file to open it. Drag the UTM icon to the Applications folder.

UTM Install

2. Download Ubuntu 22.04

Go to Ubuntu releases and download the latest Ubuntu 22.04 image for ARMv8/AArch64 architecture.

Ubuntu Download

3. Create a new virtual machine

Open UTM and click on the + icon to create a new virtual machine.

UTM Create VM UTM Create VM

4. Configure the virtual machine

Use Virtualize to simulate the virtual machine with arm64 CPU architecture.

UTM Configure VM

Select Linux as the Guest OS and then the .iso file downloaded for Ubuntu 22.04.

UTM Configure VM UTM Configure VM

Continue with the default settings for CPU, RAM, Storage, and Network.

UTM Configure VM

5. Install Ubuntu 22.04

Click on the Play button to start the virtual machine. Then in the next screen, select Try or Install Ubuntu.

UTM Install Ubuntu

Once the Ubuntu 22.04 screen appears type ubuntu as the password and press enter.

UTM Install Ubuntu

Click on the Install Ubuntu icon on the desktop to start the installation process.

UTM Install Ubuntu

Select the Normal Installation and *Install Third Party Software option and click on the Continue button.

UTM Install Ubuntu

Select the Erase disk and install Ubuntu option and click on the Install Now button.

UTM Install Ubuntu

Proceed with the installation process and create your user account.

UTM Install Ubuntu

Once the installation is complete, close the dialog box power off the system.

UTM Install Ubuntu

Eject the Ubuntu 22.04 iso file from the virtual machine.

UTM Install Ubuntu

Restart the virtual machine and login with your user account.

You have successfully installed Ubuntu 22.04 on your M1/M2 Mac.

6. Next Steps

ROS2 Installation

7. References