Hi all
According to the docs, db storage should be used for small setups and file storage for larger ones. With file storage, I had 13,5 million files in the articles tree. After migrating it all to db storage on mariadb, speed, measured by JMeter, is 2-3 times higher. I tried to migrate to postgres as well, since I find that better, but I got stuck with this error https://github.com/znuny/Znuny/issues/164
So - perhaps the docs shouldn't tell us to use file storage after all? On top of this, many distros uses XFS these days and XFS is very slow on metadata operations compared to ext4, so handling millions of tiny files is again very slow.
DB or file storage?
Moderator: crythias
-
- Administrator
- Posts: 3976
- Joined: 18 Dec 2007, 12:23
- Znuny Version: Znuny and Znuny LTS
- Real Name: Roy Kaldung
- Company: Znuny
- Contact:
Re: DB or file storage?
Hi,
What exactly do you measure with JMeter? Requests, the caching capabilities or the app or the database?
On large systems it is always worth to see which Storagebackend to use, but at the end the individual use case decides it.
You have to take into considerations your storage (disk vs. SSD vs. storage systems like HP XP, IBM DS, etc.) and the possible IOs, how often are attachments used in e-mails, backup and so on. Speed is not the most important part when it comes to the article. If have customers having then on a NFS mount without any problem.
And when comparing XFS vs. ext4 and the metadata operations I would never ignore the inode usage. Having enough space and running out of inodes is a common problem with ext filesystems.
- Roy
What exactly do you measure with JMeter? Requests, the caching capabilities or the app or the database?
On large systems it is always worth to see which Storagebackend to use, but at the end the individual use case decides it.
You have to take into considerations your storage (disk vs. SSD vs. storage systems like HP XP, IBM DS, etc.) and the possible IOs, how often are attachments used in e-mails, backup and so on. Speed is not the most important part when it comes to the article. If have customers having then on a NFS mount without any problem.
And when comparing XFS vs. ext4 and the metadata operations I would never ignore the inode usage. Having enough space and running out of inodes is a common problem with ext filesystems.
- Roy
Znuny and Znuny LTS running on CentOS / RHEL / Debian / SLES / MySQL / PostgreSQL / Oracle / OpenLDAP / Active Directory / SSO
Use a test system - always.
Do you need professional services? Check out https://www.znuny.com/
Do you want to contribute or want to know where it goes ?
Use a test system - always.
Do you need professional services? Check out https://www.znuny.com/
Do you want to contribute or want to know where it goes ?
-
- Znuny newbie
- Posts: 20
- Joined: 12 Oct 2021, 11:10
- Znuny Version: 6.0.36
- Real Name: Roy Sigurd Karlsbakk
- Company: OsloMet
Re: DB or file storage?
I chose a handful of URLs and started 100 threads to poll from a client
Storage used here was Dell Compellent with 1PB of HDDs and 40TB of SSDs (gross), meaning most of the access was to SSDs. Still shared with a large number of other VMs, mind.root wrote: ↑04 Nov 2021, 18:53 On large systems it is always worth to see which Storagebackend to use, but at the end the individual use case decides it.
You have to take into considerations your storage (disk vs. SSD vs. storage systems like HP XP, IBM DS, etc.) and the possible IOs, how often are attachments used in e-mails, backup and so on. Speed is not the most important part when it comes to the article. If have customers having then on a NFS mount without any problem.
I'm aware of that, so I created the fs with a large number of inodes. Still, that's not really a problem when db storage outperforms file storage.
Roy