Actually, that buffer is only for sorting queries that use an ORDER BY. Only MyISAM tables can build an index via sorting, and the configuration parameter for that is myisam_sort_buffer_size.

If the table is InnoDB, let it complete, no matter how long it takes. If you kill it, it will have to roll back, which will take just as long, and if you try to stop that by shutting down the server, it will finish rolling back when you start up again.

I have found the best way to reindex large tables is in small chunks, as I wrote here:
http://www.xaprb.com/blog/2006/06/14/how-to-re-index-a-large-database-table/

Baron

Ananda Kumar wrote:
Hi Before creating the index.

set this at you mysql prompt.

set sort_buffer_size=100000000;

This will enable ordering of index happen in the memory and index creation
will be faster.

regards
anandkl


On 8/11/07, Mike Zupan <[EMAIL PROTECTED]> wrote:
Yes it will take a long time depending on the size of the index also

On 8/10/07, x x <[EMAIL PROTECTED]> wrote:
I'm attempting to add an index to a table with 70
million rows.

DB server running on a reasonably fast Intel Mac on a
relatively slow drive.

Should this take hours to complete ?

So far it's taken 5 hours and counting.  I'm afraid
it's going to destroy my drive !





____________________________________________________________________________________
Need a vacation? Get great deals
to amazing places on Yahoo! Travel.
http://travel.yahoo.com/

--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]





--
MySQL General Mailing List
For list archives: http://lists.mysql.com/mysql
To unsubscribe:    http://lists.mysql.com/[EMAIL PROTECTED]

Reply via email to