Skip to content

Instantly share code, notes, and snippets.

@wrmack
Last active March 29, 2024 01:06
Show Gist options
  • Star 2 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save wrmack/c4e43aa7b6b14b9601cc2e4d6d575ac7 to your computer and use it in GitHub Desktop.
Save wrmack/c4e43aa7b6b14b9601cc2e4d6d575ac7 to your computer and use it in GitHub Desktop.
Linux on Macbook M1 (ARM64)

Linux on Macbook M1 using Apple virtualization

Tried with UTM but there is an issue with disk corruption. Until this is fixed in UTM I installed Ubuntu Linux using tart. Tart uses NVME.

  1. Install tart:
brew install cirruslabs/cli/tart
  1. I wanted the VM to be on an external SSD so needed to set the environment variable TART_HOME
# Set environment variable
TART_HOME=/Volumes/[path to VM folder] 
export TART_HOME

# Create linux VM with the name: [name]
tart create --linux [name]

# Install Ubuntu server
tart run --disk ~/Downloads/noble-live-server-arm64.iso [name]

# Run Ubuntu server 
tart run [name]

# In Ubuntu server, login and install Ubuntu desktop
sudo apt update
sudo apt upgrade
sudo apt install ubuntu-desktop
  1. For ease of starting the VM each time I created a small script and called it tart-start:
#! /bin/bash

TART_HOME=/Volumes/[path to VM folder] 
export TART_HOME
tart run [name]

Now I just do ./tart-start to start the VM

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment