💻

Installing Ubuntu 24.04 on Mac with UTM

Aug 25, 2024,

Installing Ubuntu 24.04 on Mac using UTM

Introduction

  • Objective: Install Ubuntu 24.04 on a Mac (M1, M2, M3 chips).
  • Tool used: UTM (similar to VirtualBox).

Installing UTM

  • Search for UTM on your browser.
  • Click on the first link: mac.getutm.app.
  • Click on the Download button to download the UTM.dmg file.
  • Once downloaded, open UTM.dmg.
  • Drag and drop the UTM icon into the Applications folder.
  • Open UTM from Launchpad.

Downloading Ubuntu ISO

  • Search for Ubuntu in your browser.
  • Click on the first link: ubuntu.com.
  • Choose to download Ubuntu Server (ARM architecture needed for M1/M2).
    • Click on Alternative Architectures
    • Select ARM architecture and download the Ubuntu 24.04 live server.
  • Ensure you do not download the AMD image.

Creating a Virtual Machine in UTM

  • Open UTM and click on Create a New Virtual Machine.
  • Select Virtualize and then choose Linux.
  • Browse and select the downloaded ARM-based ISO file.
  • Adjust hardware settings:
    • Memory: Default is 4000 MB (adjust based on Mac capacity).
    • Processors: Set according to your Mac's cores available (up to 8).
    • Storage: Default is 64 GB (adjust as necessary).
  • Set shared directory (e.g., Downloads folder).
  • Name the VM (e.g., Ubuntu 24.04 LTS).
  • Click Save to create the VM.

Installing Ubuntu Server

  • Click on Run to start the installation.
  • Use arrow keys to select Try or Install Ubuntu Server.
  • Follow the prompts:
    • Select language (e.g., English).
    • Choose keyboard layout (change if necessary, e.g., German).
    • For installation type, ensure Ubuntu Server is selected.
    • Enable Search for third-party drivers.
  • Accept default for network configuration and proxy settings.
  • Choose storage configuration: Use entire disk.
  • Set up profile:
    • Machine name (e.g., CodeBind).
    • Username (e.g., CodeBind) and password.
  • Choose to install OpenSSH for remote access.
  • Continue through prompts to complete installation.

Rebooting and Logging In

  • After installation, select Reboot Now. If it doesn't reboot, manually shut down the VM and restart.
  • Log in using the username and password set during installation.

Installing Ubuntu Desktop GUI

  • Open terminal in Ubuntu.
  • Execute the following commands:
    1. sudo apt update
    2. sudo apt install tasksel
    3. sudo apt install ubuntu-desktop
  • Wait for the installation (20-30 minutes) without interruption.
  • Reboot the system using sudo reboot now after installation.

Enhancing User Experience

  • After logging in, install Spice tools for shared folder and better resolution:
    • Command: sudo apt install spice-vdagent spice-webdavd
  • Adjust UTM settings:
    • Enable sharing of the Downloads folder.
    • Enable Retina Mode for better resolution.
  • Restart the VM and log in to Ubuntu.

Conclusion

  • Successfully installed Ubuntu 24.04 with GUI on Mac using UTM.
  • Shared folders between Mac and Ubuntu allow easy file transfer.
  • Encouragement to explore further and enjoy using Ubuntu.