# defragmentation of the tables MySQL Server Enterprise 5.5 Percona with Innodb

**URL:** <https://forums.percona.com/t/defragmentation-of-the-tables-mysql-server-enterprise-5-5-percona-with-innodb/7139>\
**Category:** Percona Server for MySQL 5.6\
**Created:** [July 29, 2019, 9:55am UTC](https://forums.percona.com/t/defragmentation-of-the-tables-mysql-server-enterprise-5-5-percona-with-innodb/7139 "2019-07-29T09:55:20Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![gar1212](https://avatars.discourse-cdn.com/v4/letter/g/9de053/32.png) [@gar1212](https://forums.percona.com/u/gar1212)\
**Post date:** [July 29, 2019, 9:55am UTC](https://forums.percona.com/t/defragmentation-of-the-tables-mysql-server-enterprise-5-5-percona-with-innodb/7139/1 "2019-07-29T09:55:20Z")

</div>

Hi, I have MySQL Server Enterprise 5.5 Percona with Innodb. I have observed that I have several tables with a high level of fragmentation. What tool or command do you recommend to use to defragment the tables?

---

<div class="post-metadata">

**Author:** ![vaibhav\_upadhyay40](https://sea1.discourse-cdn.com/flex019/user_avatar/forums.percona.com/vaibhav_upadhyay40/32/9_2.png) [@vaibhav\_upadhyay40](https://forums.percona.com/u/vaibhav_upadhyay40)\
**Post date:** [June 13, 2020, 3:44pm UTC](https://forums.percona.com/t/defragmentation-of-the-tables-mysql-server-enterprise-5-5-percona-with-innodb/7139/2 "2020-06-13T15:44:45Z")

</div>

@gar1212   
Either you can user alter command.  
alter table table\_name engine=innodb;  
or  
you can use pt-online-schema-change¶  
[https://www.percona.com/doc/percona-toolkit/3.0/index.html](https://www.percona.com/doc/percona-toolkit/3.0/index.html "Link: https://www.percona.com/doc/percona-toolkit/3.0/index.html")  
  
Note: ensure you read the document carefully.&nbsp;  
Tip: ensure you have PK  
  
Hope this helps…
