Not the answer you need?
Register and ask your own question!

innoDB disk file size

arash78arash78 EntrantInactive User Role Beginner
I am setting up a solution that will insert around 100 million rows in a table per month and every row will have a timestamp that will be indexed. The idea is to only store data regarding the last 3 months in this table, so the total row count will be approximately 300 million rows. Therefore every night an event will delete the rows that are older that 3 months.

I understand that the innodb files can never be reduced in size after deletes, but in this case will the innodb file size grow infinitely for every month when new data is inserted? Or will the new data replace the deleted data in the file storage?

Comments

  • przemekprzemek Percona Support Engineer Percona Staff Role
    Have you considered paritioning the table by date and creating new partition for each month? This way you could just drop oldest partitions easily if needed.
Sign In or Register to comment.

MySQL, InnoDB, MariaDB and MongoDB are trademarks of their respective owners.
Copyright ©2005 - 2020 Percona LLC. All rights reserved.