Thanks for idea again :)

HT> Ilya,
HT> actually, it may be safest that you use CREATE TABLE to create
HT> an identical InnoDB table, and then do

HT> INSERT INTO newtable SELECT * FROM oldtable WHERE yourkey > something
HT>                                              AND yourkey < somethingelse;

HT> In this way you can divide the insertion into pieces, and you have
HT> better control on what is happening. After all data is inserted,
HT> you can rename tables.

HT> Regard,

HT> Heikki

HT> At 04:22 PM 5/22/01 +0400, you wrote:
>> 
>> Thanks for info.
>> 
HT> Ilya,
HT> ALTER TABLE should be faster: InnoDB does not have special optimization
HT> for separate index creation. Therefore the fastest way is to do the inserts
HT> directly to an InnoDB table.
>> 
HT> You should set the InnoDB buffer pool size big during the
HT> transition, to reduce disk i/o. Not bigger than 80 % of the physical
HT> memory, though. You should set InnoDB log files big, as described in the
HT> manual at http://www.innobase.fi, and also the log buffer to 8 MB,
HT> for example.
>> 
HT> Make sure you do not run out of tablespace: InnoDB tables take a lot
HT> more space than MyISAM tables. If an ALTER TABLE runs out of space,
HT> it will start a rollback, and that can take hours if it is disk bound.
HT> In that case it is better that you kill the database process and
HT> delete all InnoDB files and all InnoDB table .frm files, and start
HT> your job again, rather than wait millions of disk i/os to complete.
>> 
HT> Regards,
>> 
HT> Heikki Tuuri
HT> Innobase Oy
>> 
>> -- 
>> -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
>> | Ilya Martynov (http://martynov.org/)                                    |
>> | GnuPG 1024D/323BDEE6 D7F7 561E 4C1D 8A15 8E80  E4AE BE1A 53EB 323B DEE6 |
>> | AGAVA Software Company (http://www.agava.com/)                          |
>> -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
>> 


-- 
 -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
| Ilya Martynov (http://martynov.org/)                                    |
| GnuPG 1024D/323BDEE6 D7F7 561E 4C1D 8A15 8E80  E4AE BE1A 53EB 323B DEE6 |
| AGAVA Software Company (http://www.agava.com/)                          |
 -=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-

---------------------------------------------------------------------
Before posting, please check:
   http://www.mysql.com/manual.php   (the manual)
   http://lists.mysql.com/           (the list archive)

To request this thread, e-mail <[EMAIL PROTECTED]>
To unsubscribe, e-mail <[EMAIL PROTECTED]>
Trouble unsubscribing? Try: http://lists.mysql.com/php/unsubscribe.php

Reply via email to