Quota for MySQL databases?

Is there a solution if i want to avoid that users get unlimited space on their mysql databases? Home Directories are having quotas, but mysql db’s r not saved in those directories.

Any hints?

Some bad user guy might have 10 MB quota for home, but filling up the whole disk by putting loads of junk in his database!?!

the mysql database is included in the quota
I have tested this with a domain which reached the limit of its space when one of the tables almost overloaded. It then had 98% of disk usage before i emptied the table.

I forgot however if this is done automatically or if I have enabled an option somewhere.

Interesting, i’ll try that.

Yeah, I don’t recall what the default is either.

But, look in System Settings -> Server Templates -> Default Template -> MySQL Database, and look for the setting "Set group ownership of MySQL database files".

One other thing to keep in mind…the MySQL database tables need to be stored on the same partition as /home for this to work. I always use one big partition (so, no special partition for /var and /home)…but if you split stuff out a bunch, then you’ll find that quotas don’t apply to databases, regardless of file ownership.