Creating Fast, Compressed Tables with myisampack

By now you'll be familiar with the MyISAM table type. MySQL has the facility for creating compressed, faster versions of MyISAM tables using a utility called myisampack.

myisampack creates tables that are around 50% smaller in disk size than normal MyISAM tables. They are therefore faster to access because disk seek time is reduced. You can use myisampack as part of an optimization strategy for your database.

The main limitation of packed MyISAM tables is that they are read-only. They really are only useful in situations where you have a large table containing information that doesn't change.

For example, you may have a table called cities that holds data about cities around the world. The following ...

Get Sams Teach Yourself MySQL in 21 Days, Second Edition now with the O’Reilly learning platform.

O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.