[Sanity Check] MariaDB VM on ZFS-Based Host Storage - Using Virtual SCSI Disks to Control volblocksize on the host? (Am I doing this right?)

Sep 1, 2022
217
35
28
40
Hello,

N.B.: I haven't installed MariaDB yet, or even partitioned/formatted the virtual SCSI disks inside the VM, but I think I just caught myself about to make a mistake and wanted a second opinion.

I've got a Debian 12 VM with storage set up like this:
1721695095736.png

So, above, I'm taking a swing at the four-disk approach for storing MariaDB data in ZFS that a DB admin suggested I experiment with, keeping in mind that each virtual SCSI disk is a zVol.
  1. scsi0: OS boot disk (volblocksize 64k)
  2. scsi1: MariaDB database data disk (volblocksize 16k)
  3. scsi2: MariaDB binlog disk (volblocksize 1M)
  4. scsi3: MariaDB log file disk (volblocksize 1M)
I set this up and felt pretty good about it, then I realized ... for best performance, recordsize on the binlogs and regular log files are supposed to be at 1M, which is a whole different thing than setting the volblocksize.

So, the sanity check part. The virtual SCSI disks are zVols. So they have volblocksize, but do not have recordsize. Right?
And if yes, what's best practice here for MariaDB?

I want to keep all storage local to the VM. I'm aware I could always mount a ZFS backed share via NFS and set recordsize on that share, but I don't feel like I should need to do that.

I think I'm missing something obvious.
 

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!