Ubuntu zfs mirror install
Skills shared by soulmachine for improving daily work efficiency with AI Agents (Claude Code, Codex, etc.)
npx -y skills add soulmachine/skills --skill ubuntu-zfs-mirror-installAssembled from the repository path, not quoted from the project. Check it against their README if it does not work.
One thing to look at
- 3 stars3 stars. Stars are a popularity signal and not a quality one, but at this level it is likely that nobody has read this closely except its author, and you would be relying on your own review.
What its author says it does
Copied from the file, not written here
Install Ubuntu Server onto a 2-disk ZFS mirror root (rpool→/) plus a striped data pool (dpool→/data) via debootstrap + ZFSBootMenu, or fall back to a plain single-disk ext4 install (GRUB-EFI) when there aren't two equal-size disks. Use when asked to install Ubuntu on ZFS, build a ZFS mirror root / rpool+dpool layout, set up root-on-ZFS with ZFSBootMenu, or do a scripted Ubuntu Server install on a UEFI x86 server with one or two SSDs/NVMes.
SKILL.md
4.0 KB, as published. Nobody here has run it
Ubuntu ZFS-mirror (or ext4) Server Install
Validated end-to-end (proven on an 8-GPU ASUS ESC8000-E12P). Every fix that makes the ZFS path boot hands-free and reboot-safe is baked into the scripts — see REFERENCE.md for what they are and how to recover if something's off.
Decision rule (choose the path from the disks)
- Exactly two fixed disks of the SAME size → ZFS mirror (
scripts/install.sh): per diskESP | rpool-member | dpool-member;rpoolmirror →/,dpoolstripe →/data(no redundancy). - One disk, or two disks of different sizes → plain ext4 single-disk (
scripts/install-ext4.sh):ESP | ext4 root, GRUB-EFI. (install.shrefuses unequal/single disks and points here.)
Prerequisites
- Target booted into an Ubuntu Server LIVE environment (24.04+/26.04), UEFI mode (CSM off).
- A root shell on it (local console, or SSH — enable
ssh+ set a password in the live env). - Internet reachable from the live env (debootstrap + ZFSBootMenu download).
- Copy
scripts/to the target (e.g.scp -r scripts root@<live-ip>:).
Workflow
- List disks:
sudo bash scripts/install.sh --list— shows fixed disks with by-id paths + sizes; the live/USB medium is marked[LIVE MEDIUM, do NOT pick]. - Gather settings from the user (ask; defaults in parens):
Setting Notes disk(s) by-id path(s); count+size decides ZFS vs ext4 rpool size (ZFS only) 128 / 256 / 512 / 1024 GB → RPOOL_SIZE=+128G/+256G/+512G/+1T(default+1T)admin username default developeradmin password default passw0rd(root gets the same)SSH public key optional; if set, admin is key-only (password auth off) hostname default ubuntutimezone optional (default Etc/UTC) - Run the matching installer (type
ERASEwhen prompted, or pass--yesonce the user has confirmed):
Takes ~10–20 min (debootstrap dominates). Over a flaky SSH link, run detached and tail the log:# ZFS mirror (two equal disks): DISK1=<by-id> DISK2=<by-id> RPOOL_SIZE=+1T ADMIN_USER=developer INSTALL_PASSWORD='...' \ SSH_AUTHORIZED_KEY='ssh-ed25519 ...' HOSTNAME=ubuntu sudo -E bash scripts/install.sh # ext4 single disk: DISK1=<by-id> ADMIN_USER=developer INSTALL_PASSWORD='...' HOSTNAME=ubuntu sudo -E bash scripts/install-ext4.sh… nohup bash scripts/install.sh --yes >/root/install.log 2>&1 &thentail -f /root/install.log. - Reboot — remove the install media (or set the target disk first in UEFI boot order). It should
boot ZFSBootMenu → Ubuntu (or GRUB → Ubuntu) hands-free, with
/and/data(ZFS) mounted. - Validate:
sudo bash scripts/validate.sh— expect pools//dataONLINE (ZFS) or/ext4, andsystemctl is-system-running=running, 0 failed units.
Safety
- Destructive. The installers refuse a disk that has mounted partitions (the live medium) and
require typing
ERASE(skip only with--yesafter the user explicitly confirms the disks). - Single-NVMe failure on the ZFS layout:
rpoolstays bootable (degraded),dpool//datais lost (no redundancy by design). - ZFS path has no GRUB — the kernel cmdline lives in the
org.zfsbootmenu:commandlineZFS property (it's set toquiet zfs_force=1; keepzfs_force=1if you append e.g.intel_iommu=on iommu=pt).
See REFERENCE.md for the baked-in fixes, recovery steps, and hardware notes (incl. ASUS ESC8000 BMC quirks).