List:General Discussion« Previous MessageNext Message »
From:Rolando Edwards Date:January 21 2011 3:31am
Subject:RE: Interrupt ALTER Process
View as plain text  
Remember, the InnoDB table has a full table lock now since it is doing and ALTER TABLE.
You may want to kill it and try this instead:

In this example, the table with 12M rows is called BigTable

1) CREATE TABLE BigTable2 LIKE BigTable;
2) ALTER TABLE BigTable MODIFY COLUMN <column-name> VARCHAR(<new size>);
3) INSERT INTO BigTable2 SELECT * FROM BigTable;
4) DROP TABLE BigTable;
5) ALTER TABLE BigTable2 RENAME BigTable;

Give it a try !!!

Rolando A. Edwards
MySQL DBA (SCMDBA)

155 Avenue of the Americas, Fifth Floor
New York, NY 10013
212-625-5307 (Work)
201-660-3221 (Cell)
AIM & Skype : RolandoLogicWorx
redwards@stripped
http://www.linkedin.com/in/rolandoedwards


-----Original Message-----
From: Willy Mularto [mailto:sangprabv@stripped] 
Sent: Thursday, January 20, 2011 10:19 PM
To: mysql@stripped
Subject: Interrupt ALTER Process

Hi,
I have an InnoDB with 12 millions of data. For some reason I need to alter the table
structure by expanding the varchars value. It's been an hour and slow down the
performance. Is it safe to kill the process? Thanks.



Willy
-- 
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/mysql?unsub=1

Thread
Interrupt ALTER ProcessWilly Mularto21 Jan
  • RE: Interrupt ALTER ProcessRolando Edwards21 Jan