The Compendium · Chapter 9 of 20

Installing Linux

11 min read · 9 sections

Updated October 2026: t2linux is for T2 Macs only (T1 and older Macs use a standard distro). The T2 Ubuntu ISO now sets up Wi-Fi firmware, the kernel repo and snapd for you, so several old steps are now fallbacks. Also new: current Ubuntu releases, the Touch Bar config, how the boot loader really installs, and model-specific gotchas.

If you’re on a Mac without a T2 chip, you can download the Linux distro of your liking. That includes T1 Macs (the 2016 and 2017 MacBook Pros with Touch Bar) and anything older. If you do have a T2 Mac (most Intel Macs from 2018 to 2020, plus the 2017 iMac Pro; Apple’s list is here), then you must download a distro from t2linux.org, which only supports T2 Macs. The process is mostly the same either way; T2-specific steps will have a letter designator after the step number and will be emboldened below. Also note, the instructions will vary depending on your chosen flavor of Linux, especially Arch or Kali Linux. The guidance below is for Ubuntu, which is the preferred flavor of Think quadratic.

On a T2 Mac, Secure Boot has to be set to “No Security” and booting from external media allowed before any of this will work. That’s Step 0, which you should have done already. You’ll also want a USB-C to USB adapter for the installer USB.

Step 4 & 4a: Preinstallation of Linux – Create bootable USB

  • In macOS, download your preferred flavor of Linux; T2 Macs from here (Arch, CachyOS, EndeavourOS, Fedora, Gentoo, NixOS, Ubuntu and its flavors, and Linux Mint all have T2 versions)
    • Don’t try standard downloads on T2 Macs; they won’t work without extra effort (an external keyboard and mouse, and often a wired network adapter)
    • For Ubuntu, use the iso.sh method to make this process easier
      • Download the “iso.sh” file from the assets of the latest T2-Ubuntu release
      • Open Terminal and type “bash “ including the space
      • Drag and drop the iso.sh file into Terminal
        • The command should look something like “bash ~/Downloads/iso.sh”
      • Hit “Enter” and answer the questions in Terminal (which flavor, then which version)
        • The script downloads the ISO in parts, joins them, and checks the sha256 checksum for you
        • Keep in mind, future maintenance will depend on which version you choose:
          • The script only offers long term support (LTS) releases, right now 24.04 (“Noble Numbat”) and 26.04 (“Resolute Raccoon”)
          • LTS versions come every two years (22.04, 24.04, 26.04…) and get 5 years of updates; the releases in between (like 25.10 or 26.10) are full, stable “interim” releases, but they only get 9 months of updates, and there’s no T2 ISO for them
    • Prefer an app to Terminal? The t2linux Installer app can download the ISO for you instead
  • You’ll end up with an Ubuntu iso image in “Downloads”
  • Download balenaEtcher from here (on an Intel Mac, pick the x64 .dmg)
    • Heads up: Etcher collects analytics data; USBImager does the same job, and so does dd in Terminal (see the t2linux wiki)
  • Install balenaEtcher
  • Plug in an 8GB or higher USB
  • Open balenaEtcher
  • Follow prompts to turn the Linux distro you downloaded into a live USB
  • Optional, but safer: make room for Linux now, while you’re still in macOS
    • Open Disk Utility, select the drive, and click “Partition”
    • Click the “+” under the pie chart and choose “Add Partition”, NOT “Volume”
    • Name it something like “Linux”; any format but APFS is fine (it gets erased during the install anyway)
    • Pick the size you want for Linux carefully; you won’t be able to change it later
    • Note this space comes out of macOS, not Windows; if you’d rather take it from Windows, skip this and shrink Windows during the install instead

Step 4b: Preinstallation of Linux – Prepare WiFi and Bluetooth Drivers

This step is now a fallback. The T2 Ubuntu ISO comes with a get-apple-firmware tool that copies the Wi-Fi and Bluetooth firmware from your macOS partition on its own, so in most cases Wi-Fi just works once Linux is installed. It’s still worth doing if you have an iMac19,1, iMac19,2 or iMac Pro (iMacPro1,1), which need one of these macOS-side methods, or if you want a backup plan:

  • Download the necessary script here, be sure it stays in the “Downloads” folder
  • Open Terminal, type “bash ~/Downloads/firmware.sh” and hit “Enter”
    • Enter Password and hit “Enter”
    • When it asks how you want to copy the firmware to Linux, choose “1” (Copy the firmware to the EFI partition and run the same script on Linux to retrieve it)
    • Don’t worry about the commands that appear, We have them rewritten for you in Step 5b
  • Leave Linux Live USB plugged in and reboot

Before you install: known issues on some T2 Macs

  • MacBookPro16,1 (16-inch, 2019), and possibly 16,4: the Mac may turn off in the middle of the install. To get past it, plug in an external USB keyboard, highlight the “Try Ubuntu” option in the live USB’s boot menu, press “e”, go to the end of the kernel line and add efi=noruntime, then press Ctrl+X or F10 to boot
  • iMac19,1, iMac19,2 and iMac Pro (iMacPro1,1): Wi-Fi firmware has to come from macOS (Step 4b, or methods 1–3 of the t2linux Wi-Fi guide); downloading it online won’t work on these models
  • Never install the broadcom-wl driver, even if a forum post tells you to. These Macs use brcmfmac, which is already part of the Linux kernel
  • Macs with an AMD graphics card: changing resolution and similar things can crash; adding amdgpu.dpm=0 to the kernel parameters stops that
  • Thunderbolt not working: try adding pcie_ports=native to the kernel parameters
  • To add a kernel parameter for good, open sudo nano /etc/default/grub, add it inside the quotes on the GRUB_CMDLINE_LINUX_DEFAULT line, save, then run sudo update-grub

Step 5 & 5a: Install Linux

  • rEFInd should see the Live USB and show a logo with three circles, select it
    • If not, hit the “Escape” key
    • If it still does not show, the creation of the live USB did not work
  • Choose to install Linux, not try it
    • Go through the installation process
      • Select to install third party software and hit “Next”
      • On the disk setup screen, choose manual partitioning: “Something else” on the 24.04 installer, “Manual installation” on the newer 26.04 installer (NEVER let it erase the disk or partition automatically; that wipes macOS too)
        • If you made a Linux partition in Disk Utility (end of Step 4): select it (double-check the size so you get the right one), click “-” to delete it, and skip down to the free-space step below
        • Otherwise: in the new popup window, select the Windows partition (typically the third one, with NTFS in “type” column
          • Click the “Change” button, popup window appears
          • Shrink the Windows partition to the size of your liking (half the size is ideal)
          • IF THIS POPUP DOES NOT ALLOW YOU TO CHANGE THE PARTITION, GO TO OPTIONAL STEP B
          • Leave “do not use the partition” as is; just hit “OK”
          • Click “Continue” on the warning that appears
        • Select the remaining free space and click the “+” sign
          • START BACK HERE IF YOU HAD TO FOLLOW OPTIONAL STEP B
          • In the popup, set its size to half the free space and format it to EXT4 (btrfs works too)
          • Choose the “/” option for the “Mount point”
          • A Swap partition is optional; Ubuntu uses a swap file by default, so you can skip it
            1. If you still want one, select free space, click “+” sign, add 1GB or more of Swap
        • Leave the EFI partition (the first one, /dev/nvme0n1p1) alone: don’t delete it or format it. On a Mac, GRUB, Ubuntu’s boot loader, always installs into that EFI partition, mounted at /boot/efi, alongside Windows’ boot files. You can leave the “Device for boot loader installation” drop-down at its default
        • That’s also why the next boot goes straight into Linux: GRUB takes over the Windows (“EFI Boot”) entry in the Mac’s boot menu, so it can look like you have only a Linux machine. Nothing is lost; Step 6, reblessing rEFInd and, if needed, Optional Step C sort it out
        • Click “Install Now”
          • Click “Continue” to write changes to disk
    • Finish installation setup, including admin-level account creation
  • Remove the USB drive and reboot when prompted

The EFI drive will be a wreck now, and it will boot into Linux automatically, but don’t bother following Step 3 to rebless rEFInd just yet. Let your Mac automatically boot into Linux until it is completely set up. For those without a T2 Mac, this is mostly a simple matter of getting the additional drivers and software updates through the usual means. The T2 Ubuntu ISO now handles most of the extra work for you, but there are still a few steps to check before Linux will be fully usable. Don’t worry, it will be worth it in the end though!

Step 5b: Install WiFi and Bluetooth drivers for T2 Macs

  • Log into the admin-level account in Linux
  • Try connecting to WiFi; in most cases it already works and you can skip to the last item
  • If it doesn’t, open Terminal and run:
    • “get-apple-firmware get_from_macos” if macOS is still installed (it should be)
    • “get-apple-firmware get_from_online” if that doesn’t work (this one needs a wired internet connection)
  • If you did Step 4b and still have no WiFi, open Terminal and execute each of the following:
    • “sudo mkdir -p /tmp/apple-wifi-efi”
    • “sudo mount /dev/nvme0n1p1 /tmp/apple-wifi-efi”
    • “bash /tmp/apple-wifi-efi/firmware.sh”
      • When asked, choose “1” (Retrieve the firmware from the EFI partition)
    • “sudo umount /tmp/apple-wifi-efi”
  • No need to restart, you can now connect to WiFi
  • Complete all updates

The T2 version of Ubuntu already has snapd installed, but depending on the version, it may not come with the App Center (the snap store); if it’s missing and you want it, follow these steps:

Step 5c: Install Snapd Store

  • Open Terminal and type
    • “sudo snap install snap-store” (this is the App Center)
  • Install “snaps” (apps) to your heart’s content
  • Reboot when done

T2 Macs need a patched kernel, which comes from a trusted repository maintained by Aditya instead of the usual updates from Canonical; be sure to thank them! The T2 Ubuntu ISO already adds this repository and installs the kernel for you, so you only need the next step if you installed Linux some other way, or after you upgrade Ubuntu to a newer release (the release-specific line has to be added again each time).

Step 5d: Configure Updates for T2 Macs’ kernel

  • Find your release’s “Codename” with “lsb_release -cs”. It’s “jammy” for Ubuntu 22.04, “noble” for 24.04, “resolute” for 26.04 and “stonking” for 26.10 (Debian: “bookworm”, “trixie” or “testing”)
  • Open Terminal and paste in the commands below, one at a time, swapping in your Codename on the first line:
    • CODENAME=noble
    • curl -s --compressed "https://adityagarg8.github.io/t2-ubuntu-repo/KEY.gpg" | gpg --dearmor | sudo tee /etc/apt/trusted.gpg.d/t2-ubuntu-repo.gpg >/dev/null
    • sudo curl -s --compressed -o /etc/apt/sources.list.d/t2.list "https://adityagarg8.github.io/t2-ubuntu-repo/t2.list"
    • echo "deb [signed-by=/etc/apt/trusted.gpg.d/t2-ubuntu-repo.gpg] https://github.com/AdityaGarg8/t2-ubuntu-repo/releases/download/${CODENAME} ./" | sudo tee -a /etc/apt/sources.list.d/t2.list
    • sudo apt update
  • Then install one kernel. Which one is your choice; it doesn’t depend on your Ubuntu version:
    • “sudo apt install linux-t2” for the latest mainline kernel (what the T2 ISO installs)
    • “sudo apt install linux-t2-lts” for an LTS kernel
    • (Xanmod versions exist too: linux-t2-xanmod and linux-t2-xanmod-lts)
  • Don’t close Terminal; need it for next step

Now, whenever you use the built-in Software Updater app, it will update as normal. But we’re not quite done setting up our T2 Macs yet if they came with that pesky Touchbar, which requires special coding to configure.

Step 5e - Setting up the Touch Bar

The Touch Bar driver has been part of the Linux kernel since version 6.15, and the repo from Step 5d is already set up on the T2 ISO, so all you need is the tiny-dfr app. (These packages come from the t2linux project, which supports T2 Macs only.)

  • Open Terminal and type:
    • “sudo apt update”
    • “sudo apt install tiny-dfr”
  • Hit “Enter” and Touchbar should activate
  • If not, it will after restarting
  • Restart

After restarting, you can change how the Touchbar behaves (for example, showing the media keys instead of F1–F12 by default). The old “sudo touchbar” command is gone; instead, copy the default settings file and edit the copy, following the notes inside it:

  • “sudo mkdir -p /etc/tiny-dfr”
  • “sudo cp /usr/share/tiny-dfr/config.toml /etc/tiny-dfr/config.toml”
  • “sudo nano /etc/tiny-dfr/config.toml”, make your changes, save, and restart

Before we can rebless rEFInd, we have to “repair” the Guid Partition Table, otherwise, Windows won’t boot until we do. This step is the same regardless of the presence of a T2 chip.

Step 6: Convert GPT

  • Reboot into admin-level account in Linux
  • Open Terminal and type:
    • “sudo apt-get update -y”
  • Hit “Enter” then type:
    • “sudo apt-get install -y gdisk” (the T2 ISO already includes gdisk, so this just makes sure)
  • Hit “Enter” then type:
    • “lsblk” and hit “Enter” (this gives you a clear name for the entire disk)
    • Most guides say the disk is “/dev/sdX” but on later Macs it’s “/dev/nvmeXnX”
    • More than likely, it’s going to be “/dev/nvme0n1”
  • Type “sudo gdisk /dev/nvme0n1” and hit “Enter”
    • Should see four lines with “MBR: hybrid” at the top
    • Type “x” and hit Enter
    • Type “n” and hit Enter
    • Type “m” and hit Enter
    • Type “w” and hit Enter
    • Type “y” and hit Enter
  • Type “sudo gdisk /dev/nvme0n1” again and hit Enter
    • Verify the MBR line now reads “protective” in stead of “hybrid”
    • Immediately type “q” and hit “Enter” (to avoid messing anything up)
  • Close Terminal and reboot

As mentioned, the Linux installation will break rEFInd again…follow Step 3 again. Note: you don’t need to retype the commands, just arrow up to scroll through history of commands.

All three OS logos should now be visible when you reboot, along with another three circles logo (backup kernel for Linux), which can be removed, simply by arrowing over to it and hitting the “-“ sign, then “Yes”