ZFS boot pool


The following applies to Ubuntu 22.04.3.
It may work for other versions, YMMV.
Use at your own risk.


I like ZFS, a lot.
It’s my preferred filesystem for most things, in particular Linux Containers (lxc).

I’ve been running one server with a boot pool using ZFS.
When configured this way a service (zsys) runs which should tidy up old kernels and snapshots to release space.
The default settings for zsys (in /etc/zsys.conf) are usually OK, until you run a desktop and/or do frequent apt updates.
Then you will probably start to see errors like this:

ERROR couldn't save system state: Minimum free space to take a snapshot and preserve ZFS performance is 20%.
Free space on pool "bpool" is 17%.

These operations save system state by taking a ZFS snapshot.
The way I free up space is to manually delete these snapshots as follows:

The REFER column tells us that these two snapshots are referencing 1510M disk space.

# zfs list -r -t snapshot -o name,used,referenced,creation bpool/BOOT
NAME                                       USED     REFER  CREATION
bpool/BOOT/ubuntu_cchcgi@autozsys_0ybgy0    88K      755M  Mon Nov 13  7:54 2023
bpool/BOOT/ubuntu_cchcgi@autozsys_8x0r84    88K      755M  Wed Nov 29  8:02 2023

… and disk space should be freed.

# zpool list bpool
NAME           SIZE  ALLOC   FREE  CKPOINT  EXPANDSZ   FRAG    CAP  DEDUP    HEALTH  ALTROOT
bpool         1.88G   909M  1011M        -         -    20%    47%  1.00x    ONLINE  -

Hope this helps someone.

Comment on this article using form below. Requires email login only for authentication. HTML forbidden, Markdown only.