On 08/29/2014 08:15 AM, geetanjali mehra wrote:
> But after doing *optimize table*, the value inside
> data_free is still the same. If there is no change in the value of
> data_free, then what *optimize table* does here?
Without seeing actual values I can only give an educated
guess:
* If you are not using innodb_file_per_table then
data_free is for the whole table space, not just
the individual table you're looking at.
Even if that table was fragmented before running
OPTIMIZE the overall unallocated storage space
within the table space won't change much ...
* If you have innodb_file_per_table=1 and you are
seeing data_free values round about 4MB what
you're seeing is simply pre-allocated space.
See also the last paragraph on
http://dev.mysql.com/doc/refman/5.6/en/innodb-multiple-tablespaces.html
File-per-table tablespace files are auto-extending regardless
of the value of innodb_autoextend_increment. The initial extensions
are by small amounts, after which extensions occur in increments
of 4MB.
So unless you have innodb_file_per_table set and
see data_free values substantially larger than 4MB
there's nothing to worry about ...
--
Hartmut Holzgraefe, Principal Support Engineer (EMEA)
SkySQL - The MariaDB Company | http://www.skysql.com/
--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe: http://lists.mysql.com/mysql