Creating a Ubuntu Server instance running on ZFS?

dreamcompute

#1

This is a question mainly for curiosity’s sake at the moment, but I do have some use-cases that may warrant it in future; what I’m wondering is what I would need to do in order to setup a Ubuntu Server instance running on ZFS rather than ext4?

I realise that ZFS is semi-redundant since Dream Compute’s Ceph storage presumably uses it for redundancy/integrity already, however it does have some very useful features regardless, such as multiple volumes sharing a single block device (no awkward partitioning), and the ability to run sends between instances (or even to backup services that support it).

While I know how to setup such a system locally, I’m not clear on what is required to do something like this within OpenStack, as somehow I need to be connected to the instance during the installation, or is there a way that I can do it offline and upload the image to boot from?

I realise that one other option would just be to shrink the OS partition and reformat the rest as ZFS, but that still means picking the right size for the OS partition, whereas just doing the whole thing via ZFS is much easier.


#2

Hi Haravikk, you can setup Ubuntu on ZFS in OpenStack/DreamCompute and you have a couple of different options. You need a custom image to boot from. A quick and dirty way to proceed is boot a regular VM, mount a volume, use debootstrap/chroot to install a new ubuntu install in that chroot and select ZFS, then create a new VM to boot from that volume. Boot from the new volume and you have your ZFS system.
Another option is that you create your own Ubuntu-based image with ZFS, upload it in your tenant(user) and boot from there.

hth