2023-10-07, 09:47 AM
(This post was last modified: 2023-10-07, 09:53 AM by vincen. Edited 1 time in total.)
(2023-10-06, 03:57 PM)TheDreadPirate Wrote: Having your database on a ZFS file system is possible, it is very much not recommended. Database READ performance is fine, but when you are writing to a database that is on a ZFS file system there are serious performance penalties.First time I hear such possible issues with ZFS. Do you have any technical references about it ? I use also Plex on that server that uses also flat files DB and storage of it on a ZFS volume has never been a problem
Unhappy right now I'm not able to move the DB on an ext4 storage all the more with all metadatas directories that go with it
(2023-10-06, 11:26 PM)TheDreadPirate Wrote: If the ZFS filesystem is a single SSD, and the file system block size is 4KB or 8KB, it would be acceptable. The problems start to happen when a database is on a multi-disk ZFS array. The block size is usually something larger like 128KB or more.Thanks for clarification about "issue" with ZFS but I would have 2 additional questions:
ZFS is a copy-on-write file system. Meaning that instead of just modifying the block in place, it makes a copy of the entire block being modified. So no matter how small of a change you are making you are, at minimum, writing a single block. So if your are making A LOT of write transactions to the jellyfin database, which would happen during a library scan, there is a lot of unnecessary writing happening. And this seriously reduces database performance. Probably not noticeable for a small library with the database on a SSD.
But if the database is on a hard drive based ZFS array with, probably, larger block sizes, combined with a large library and, thus, large database, you are going to run into serious performance issues. You are going to experience something called "write amplification". If you want to write 50MB to your database, the file system forces you do write 1GB (numbers pulled out of my butt).
-> is It still a problem on a ZFS array that have high speed (mine read/writes at around 2.5g/s which should compensate the problem no ?
-> the issue is only for write operations so nearly only when you scan libraries right ? out of it amount of data written in db is ridiculous no ?