88 Mb database size normal for single user?

Just wondering if a database of 88Mb is normal for a single user with not that many files or apps. I’m on a shared webhost with a limit of 100 Mb per database…

Well, probaby yes… there are a lot of tables, which each take 128k+ bytes just for being there. My NC instance hosts approx. 8 users and the size on disk of my DB is about 830Mb.

1 Like

my postgres database dir holds 92MB
the database dump is 4.2MB (gzip compressed 1.2MB)

about which size you are writing?

maybe you can tune a bit your database settings. (log file, temp space) just guessing.

Hmm… maybe, but it seems that these InnoDB tables already have some minimal size, even when being empty… and there’re approx. 135 of those… and there’s the oc_filecache, which already is 480M…

Oh dear, any ideas what you could do to manage the size?

Would it decrease if I remove smaller files?

Do you get a warning when there is no more space? What happens then? Any ideas?


100mb is really like nothing. Is there a Paywall after 100mb and you want to stay gratis? I dont know how your webhoster manages these things. For smaller installments i can imagine using a virtual private Server. 15gb space for like 5 bucks a month. There you yould use all 15gigs just for DB if you like, but i dont know much about you overall situation and requirements.

Opinions seem to diverge widely. I currently have 8 users in my Nextcloud. Only one has many files (2 GB), the others almost nothing. But everyone has an address book and a calendar and they are used a lot. The entries are already a few years old. And still my Mysql file is not bigger than 10 MB.

The database size largely depends on what apps you use and how you are using them. As @Ascendancer said, 100 MB of db size is just like nothing.
Have a look with a dbm tool (like phpMyAdmin) on the database to see which tables eat up the space.

Well… to me it’s still the oc_filecache. However, I managed to shrink the overall size of my NC database from 830MB to 560MB by running the optimize query on the largest tables.

My oc_filecache now uses 340MB for 743652 rows in the table. The actual number of folders/files, according to occ files:scan --all is: 929/37069.

I regulary backup my database with mysqldumper. This also optimizes the tables…
30.03.2019 08:10:10 Table 77 oc_vcategory_to_object optimized successfully.
30.03.2019 08:10:10 Table 78 oc_whats_new optimized successfully.
30.03.2019 08:10:10 78 tables have been optimized
30.03.2019 08:10:10 Found 78 tables with 34328 records.

I’m already paying €250 a year for 50GB and with the 100Mb database limitations. It’s a normal webhost, (combell in Belgium) no dedicated nextcloud hosting. But I think it’s already expensive and I might look into changing services next year or do my own raspberry server.

I have two users on my system (with roughly 120k files in total), and the DB dump file is 121MB.
/var/lib/mysql/nextcloud is 193MB, and /var/lib/mysql/ibdata1 is 781MB. The next largest database I have is for roundcube, which is 3MB.

I found this thread because I have the same problem: Large database. I have two users with private data (photos, documents etc.) on 4TB hdd (data about 2TB). My database (dumping with mysqldump) has 6GB. I already tried occ files:cleanup whicht shrinks the size some but not much. The last try of occ files:cleanup runs for 5 days and deleted 5 Mio of rows in the table oc_filecache. All the database size is from oc_filecache. I have to restrain me not to delete this database table.

If you have any tip for me how to get this database (table oc_filecache) smaller I would be very gratefull.

After cleaning up a huge amount of rows in a mysql table, you need to run optimize on that table to free up the reserved space: https://dev.mysql.com/doc/refman/5.7/en/optimize-table.html

You may delete the oc_filecache table…i guess this will render you nextcloud broken…

My database is ~87.1Mb, about 60’000 files (mostly pictures)

I store my data on kimsufi : 2To for about 120$/year - with IPv6
But you need to configure everything… and optimizing Nextcloud is really painful :slight_smile:

what is everything?

so there are 60k thumbnails?

increasing database size is mainly due to thumbnails isn’t it? According to Database configuration in the docs even only administrative data is stored in there

I’m about to get a new NAS what comes either with an M.2 NVMe interface or eMMC and building up GBs tend to be pricey.
What size of the database do I have to expect for the following scenario.

  • 10 users
  • 1000 files per user, 75% pdf, 20 % office
  • 100’000 pictures
  • 20’000 music & video

thank you