Garbage collecting/trimming ibdata1

2010-02-23 Thread Yang Zhang
I recently tried to run INSERT INTO general_log SELECT * FROM mysql.general_log; but that failed a few hours in because I ran out of disk space. 'SELECT COUNT(*) FROM general_log' returns 0, yet ibdata1 is still 49GB (started at 3GB before the INSERT; the source mysql.general_log, a CSV table,

Re: Garbage collecting/trimming ibdata1

2010-02-23 Thread Jim Lyons
Your innodb data file just auto-extended until you either reached its max or ran out of disk space if you had no max. The only way I know to reduce it is to dump all the innodb tables, drop the innodb data file and logs (and drop the innodb tables if you're using file-per-table), restart mysql,