Skip to content

Instantly share code, notes, and snippets.

@jessegoodier
jessegoodier / install-nextcloud-snap-zfs-dedupe-compression
Last active September 30, 2022 16:49
Steps to install nextcloud on ubuntu using snap and moving the data to a new disk using zfs compression and deduplication
# sample code, use at your own risk
# script to install zfs, nextcloud using snap and moving the data to the new volume with compression and deduplication enabled.
# Do your own research as to pros and cons of zfs dedupe and compression.
# Short advice is that compression works well unless you're mostly storing compressed file formats like media.
# install and configure zfs, assuming 2nd disk is where you want your data stored.
sudo apt install zfsutils-linux
sudo zpool create nextcloud /dev/sdb
sudo zfs create nextcloud/data
sudo zfs set compression=lzjb nextcloud/data