[MDEV-32121] Table size in DB Replication is not same Created: 2023-09-07 Updated: 2024-01-08 Resolved: 2024-01-08 |
|
| Status: | Closed |
| Project: | MariaDB Server |
| Component/s: | Configuration, Replication, Storage Engine - InnoDB |
| Affects Version/s: | 10.11 |
| Fix Version/s: | N/A |
| Type: | Bug | Priority: | Major |
| Reporter: | ASHWANI SINGH | Assignee: | Unassigned |
| Resolution: | Incomplete | Votes: | 0 |
| Labels: | None | ||
| Attachments: |
|
| Description |
|
Hi Team, We have a MariaDB Replication Setup and on the same we had created a database. And we had observed that the table size on Maria DB1 is around 1-2 GB while size on Maria DB2 is around 250-300GB and it keeps on increasing. We have also found that data-free variable from output of show table status command keeps on increasing. When we take backup of that table & restore it again then the size gets decreased & then after some time it gets increased. Please suggest the way forward. |
| Comments |
| Comment by Kristian Nielsen [ 2023-09-07 ] |
|
This sounds more like a support request than a bug report. |
| Comment by ASHWANI SINGH [ 2023-09-07 ] |
|
Hi Kristian, Data on slave & master is identical. Query used to check size: SELECT table_schema as `Database`, table_name AS `Table`, PARTITION_NAME, from_unixtime(SUBSTRING_INDEX(SUBSTRING_INDEX(PARTITION_NAME,"",2),"", Show create table output is mentioned in the file attached. sessions.txt I have also tried to reproduce this scenario for another table & I was able to reproduce it so this is not a schema related issue. |
| Comment by Kristian Nielsen [ 2023-09-07 ] |
|
Sorry, I'm not familiar with exactly how data_length and index_length in INFORMATION_SCHEMA are computed. It's hard to know what would cause these to differ between the servers without more info and a way to reproduce. If the data is correct, then it might not be related to replication. Maybe someone else can have an idea. |
| Comment by ASHWANI SINGH [ 2023-09-07 ] |
|
Can you please suggest to me the best way to calculate the table size? |
| Comment by Sergei Golubchik [ 2023-09-08 ] |
|
what mariadb versions you use? on both nodes |
| Comment by ASHWANI SINGH [ 2023-09-09 ] |
|
Hi Team, We are using MariaDB Version 10.7.4 |
| Comment by Sergei Golubchik [ 2023-09-10 ] |
|
10.7 has reached EOL about half a year ago, the will be no more bug fix releases of 10.7. Please, check whether you still have this issue on one of the still maintained MariaDB versions. See https://mariadb.org/about/#mariadb-general-release-maintenance-periods |
| Comment by ASHWANI SINGH [ 2023-09-18 ] |
|
Hi Team, |
| Comment by Sergei Golubchik [ 2023-10-23 ] |
|
Thanks. So the .ibd file is 348M. What is the .ibd file size on the other node? |
| Comment by ASHWANI SINGH [ 2023-10-24 ] |
|
Hi Sergei, ibd size on another node is 39MB. |
| Comment by Sergei Golubchik [ 2023-11-03 ] |
|
is the table definition identical? |
| Comment by ASHWANI SINGH [ 2023-11-04 ] |
|
Hi Sergei, Replication we enabled using the MASTER LOG File & MASTER LOG POS. |
| Comment by Sergei Golubchik [ 2023-11-04 ] |
|
still, please, show the output of show create table on the master. |
| Comment by ASHWANI SINGH [ 2023-11-16 ] |
|
Hi Sergei, |
| Comment by Sergei Golubchik [ 2023-11-24 ] |
|
Do you have InnoDB page compression enabled? What's the filesystem on the master and on the slave, the same? |