I tried to autoinstall ubuntu server providing the user-data file as stated in the documentation but specifically for root on ZFS on Virtualbox. I followed the cloud-init documentation to set the storage part of the user-data file. I implemented both the "ZFS Root Simple" and "ZFS Root" examples shown in the documentation. The simple one works without issues but the second doesn't work and the subiquity error that pops out is "autoinstall config didn't mount root". I can't figure out what is wrong with the configuration whereas it comes from the documentation.
The configuration file looks like this :
#cloud-config
autoinstall:
version: 1
identity:
hostname: ubuntu-server
password: "$6$exDY1mhS4KUYCE/2$zmn9ToZwTKLhCw.b4/b.ZRTIZM30JZ4QrOQ2aOXJ8yk96xpcCof0kxKwuX1kqLG/ygbJ1f8wxED22bTL4F46P0"
username: ubuntu
keyboard:
layout: fr
early-commands:
- "sudo apt-get install zfsutils-linux -y"
storage:
config:
- grub_device: true
id: disk1
name: main_disk
ptable: gpt
path: /dev/sda
type: disk
wipe: superblock
- device: disk1
id: disk1p1
number: 1
size: 9G
type: partition
- device: disk1
flag: bios_grub
id: bios_boot
number: 2
size: 1M
type: partition
- id: disk1_rootpool
mountpoint: /
pool: rpool
type: zpool
vdevs:
- disk1p1
- id: disk1_rootpool_container
pool: disk1_rootpool
properties:
canmount: "off"
mountpoint: "none"
type: zfs
volume: /ROOT
- id: disk1_rootpool_rootfs
pool: disk1_rootpool
properties:
canmount: noauto
mountpoint: /
type: zfs
volume: /ROOT/zfsroot
- id: disk1_rootpool_home
pool: disk1_rootpool
properties:
setuid: "off"
type: zfs
volume: /home
- id: disk1_rootpool_home_root
pool: disk1_rootpool
type: zfs
volume: /home/root
properties:
mountpoint: /root
version: 1