Skip to main content

MergerFS on Proxmox and pass-through to LXC

·1 min

Motivation #

I have a couple of hard drives on my Proxmox server that I’d like to combine through MergerFS. Earlier, I did that through an OpenMediaVault VM but that gave me a fair amount of grief (because of the dependency between that OMV VM and the LXC that mounted the NFS storage).

So, I got rid of OMV and setup MergerFS directly on Proxmox.

Step 1 #

Add the hard drive as a Directory on the Proxmox node (not the Datacenter). Name it hdd-foo, where foo could be hard drive serial or something.

Step 2 #

Add the following to /etc/fstab on the Proxmox node:

/mnt/pve/hdd-* /mnt/merged-hard-drives-1 mergerfs cache.files=partial,dropcacheonclose=true,category.create=mfs,fsname=mergerfs 0 0

Step 3 #

Bind mount the merged directory into the LXC by running the following and restarting it:

pct set 100 -mp1 /mnt/merged-hard-drives-1,mp=/spinning-rust