<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: MySQL, 40 Million Rows, MyISAM to InnoDB, 45 Minutes</title>
	<atom:link href="http://www.justincarmony.com/blog/2009/01/12/mysql-40-million-rows-myisam-innodb/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.justincarmony.com/blog/2009/01/12/mysql-40-million-rows-myisam-innodb/</link>
	<description>Web Designer &#38; Software Engineer</description>
	<lastBuildDate>Tue, 15 May 2012 02:22:31 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.2</generator>
	<item>
		<title>By: Restoring Large MySQL Dump &#8211; 900 Million Rows &#124; Justin Carmony&#8217;s Blog</title>
		<link>http://www.justincarmony.com/blog/2009/01/12/mysql-40-million-rows-myisam-innodb/comment-page-1/#comment-48516</link>
		<dc:creator>Restoring Large MySQL Dump &#8211; 900 Million Rows &#124; Justin Carmony&#8217;s Blog</dc:creator>
		<pubDate>Thu, 07 Apr 2011 03:05:16 +0000</pubDate>
		<guid isPermaLink="false">http://www.justincarmony.com/blog/?p=356#comment-48516</guid>
		<description>[...] Million belonged to one single table (902,966,645 rows, to be exact). To give an idea of growth, the last time I blogged about this database we had about 40 million rows. This giant table, the &quot;Scores&quot; table, is has a [...]</description>
		<content:encoded><![CDATA[<p>[...] Million belonged to one single table (902,966,645 rows, to be exact). To give an idea of growth, the last time I blogged about this database we had about 40 million rows. This giant table, the &quot;Scores&quot; table, is has a [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Lubor Nosek</title>
		<link>http://www.justincarmony.com/blog/2009/01/12/mysql-40-million-rows-myisam-innodb/comment-page-1/#comment-46485</link>
		<dc:creator>Lubor Nosek</dc:creator>
		<pubDate>Wed, 10 Nov 2010 09:09:02 +0000</pubDate>
		<guid isPermaLink="false">http://www.justincarmony.com/blog/?p=356#comment-46485</guid>
		<description>If you&#039;re having trouble with tmp tables being created on disk, you could modify tmp_table_size for the thread doing the conversion.

Something like:

SET tmp_table_size=4*1024*1024*1024; -- 4 GB

INSERT INTO ... SELECT ... FROM ... ORDER BY ...;

This way you end with simpler query and still use memory for the temporary table.</description>
		<content:encoded><![CDATA[<p>If you&#8217;re having trouble with tmp tables being created on disk, you could modify tmp_table_size for the thread doing the conversion.</p>
<p>Something like:</p>
<p>SET tmp_table_size=4*1024*1024*1024; &#8212; 4 GB</p>
<p>INSERT INTO &#8230; SELECT &#8230; FROM &#8230; ORDER BY &#8230;;</p>
<p>This way you end with simpler query and still use memory for the temporary table.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Large MySQL Conversion &#38; InnoDB &#124; Justin Carmony&#8217;s Blog</title>
		<link>http://www.justincarmony.com/blog/2009/01/12/mysql-40-million-rows-myisam-innodb/comment-page-1/#comment-46206</link>
		<dc:creator>Large MySQL Conversion &#38; InnoDB &#124; Justin Carmony&#8217;s Blog</dc:creator>
		<pubDate>Sat, 16 Oct 2010 03:02:41 +0000</pubDate>
		<guid isPermaLink="false">http://www.justincarmony.com/blog/?p=356#comment-46206</guid>
		<description>[...] off, converting from one large set of InnoDB tables to a new structure. I&#8217;ve done something similar in the past, and I think I&#8217;ve honed in a little bit more the technique. So here are some thoughts [...]</description>
		<content:encoded><![CDATA[<p>[...] off, converting from one large set of InnoDB tables to a new structure. I&#8217;ve done something similar in the past, and I think I&#8217;ve honed in a little bit more the technique. So here are some thoughts [...]</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Justin Carmony</title>
		<link>http://www.justincarmony.com/blog/2009/01/12/mysql-40-million-rows-myisam-innodb/comment-page-1/#comment-45741</link>
		<dc:creator>Justin Carmony</dc:creator>
		<pubDate>Thu, 07 Oct 2010 06:37:25 +0000</pubDate>
		<guid isPermaLink="false">http://www.justincarmony.com/blog/?p=356#comment-45741</guid>
		<description>Looking at some of the latest comments, I thought I should post an update to my story. I had tried to have MySQL dump the data in an ordered fashion. However, it would have to sort through the 40 million rows and because of the memory limits on the DB server, it would have to do this with a temporary table on the disk. So I would issue the command, and it would sit there for an hour while I waited for it to perform it&#039;s operations, and I had no idea how close or far I was for the query to finish, so I aborted it.

Having mysql dump the data as it was stored was much, much faster, and then inserting into a memory table, reorganizing the data, and re-exporting it was much faster than just summerizing it all into one query. I could look back and see why dumping it in an ordered fashion wasn&#039;t working like I expected, but at the time, this was the shortest distance I could think of to get our website back up and running.</description>
		<content:encoded><![CDATA[<p>Looking at some of the latest comments, I thought I should post an update to my story. I had tried to have MySQL dump the data in an ordered fashion. However, it would have to sort through the 40 million rows and because of the memory limits on the DB server, it would have to do this with a temporary table on the disk. So I would issue the command, and it would sit there for an hour while I waited for it to perform it&#8217;s operations, and I had no idea how close or far I was for the query to finish, so I aborted it.</p>
<p>Having mysql dump the data as it was stored was much, much faster, and then inserting into a memory table, reorganizing the data, and re-exporting it was much faster than just summerizing it all into one query. I could look back and see why dumping it in an ordered fashion wasn&#8217;t working like I expected, but at the time, this was the shortest distance I could think of to get our website back up and running.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Derek</title>
		<link>http://www.justincarmony.com/blog/2009/01/12/mysql-40-million-rows-myisam-innodb/comment-page-1/#comment-45180</link>
		<dc:creator>Derek</dc:creator>
		<pubDate>Mon, 27 Sep 2010 22:05:46 +0000</pubDate>
		<guid isPermaLink="false">http://www.justincarmony.com/blog/?p=356#comment-45180</guid>
		<description>this doesn&#039;t sound like an advanced topic.. more like someone who doesn&#039;t know what they are doing...</description>
		<content:encoded><![CDATA[<p>this doesn&#8217;t sound like an advanced topic.. more like someone who doesn&#8217;t know what they are doing&#8230;</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Joris Machielse</title>
		<link>http://www.justincarmony.com/blog/2009/01/12/mysql-40-million-rows-myisam-innodb/comment-page-1/#comment-43425</link>
		<dc:creator>Joris Machielse</dc:creator>
		<pubDate>Thu, 12 Aug 2010 21:05:04 +0000</pubDate>
		<guid isPermaLink="false">http://www.justincarmony.com/blog/?p=356#comment-43425</guid>
		<description>Or actually: you don&#039;t even have to do a dump. Just do:
Step 2, and then:
INSERT INTO new_table (id, etc) VALUES (SELECT id, etc FROM old_table ORDER BY id, etc);
Then step 4 and 5.</description>
		<content:encoded><![CDATA[<p>Or actually: you don&#8217;t even have to do a dump. Just do:<br />
Step 2, and then:<br />
INSERT INTO new_table (id, etc) VALUES (SELECT id, etc FROM old_table ORDER BY id, etc);<br />
Then step 4 and 5.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Joris Machielse</title>
		<link>http://www.justincarmony.com/blog/2009/01/12/mysql-40-million-rows-myisam-innodb/comment-page-1/#comment-43423</link>
		<dc:creator>Joris Machielse</dc:creator>
		<pubDate>Thu, 12 Aug 2010 20:54:16 +0000</pubDate>
		<guid isPermaLink="false">http://www.justincarmony.com/blog/?p=356#comment-43423</guid>
		<description>Wouldn&#039;t using mysqldump with an order by argument, have been much simpler?
So:
1- mysqldump that outputs the rows in sorted order (without schema)
2- create new table (with new name) with existing schema but new engine. 
3- import data into new table.
4- drop old table
5- rename new table to the original table&#039;s name.
Cheers!</description>
		<content:encoded><![CDATA[<p>Wouldn&#8217;t using mysqldump with an order by argument, have been much simpler?<br />
So:<br />
1- mysqldump that outputs the rows in sorted order (without schema)<br />
2- create new table (with new name) with existing schema but new engine.<br />
3- import data into new table.<br />
4- drop old table<br />
5- rename new table to the original table&#8217;s name.<br />
Cheers!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Augustina Dziedzic</title>
		<link>http://www.justincarmony.com/blog/2009/01/12/mysql-40-million-rows-myisam-innodb/comment-page-1/#comment-42066</link>
		<dc:creator>Augustina Dziedzic</dc:creator>
		<pubDate>Thu, 15 Jul 2010 04:29:28 +0000</pubDate>
		<guid isPermaLink="false">http://www.justincarmony.com/blog/?p=356#comment-42066</guid>
		<description>Terrific do the job! This could be the sort of information that ought to be shared around the web. Shame about the search engines for not positioning this post higher!</description>
		<content:encoded><![CDATA[<p>Terrific do the job! This could be the sort of information that ought to be shared around the web. Shame about the search engines for not positioning this post higher!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: imran ahmed rahi</title>
		<link>http://www.justincarmony.com/blog/2009/01/12/mysql-40-million-rows-myisam-innodb/comment-page-1/#comment-33653</link>
		<dc:creator>imran ahmed rahi</dc:creator>
		<pubDate>Mon, 08 Feb 2010 19:18:52 +0000</pubDate>
		<guid isPermaLink="false">http://www.justincarmony.com/blog/?p=356#comment-33653</guid>
		<description>Hi,

I read your article after searching google for many hours and visiting several sites. I really liked the MEMORY Storage engine. I knew it theoratically, but never thought how useful it could in situation like yours.
I am facing similar problem but with inserts of 3 million records from csv file into mysql db.
I am uploading a csv file with 3 million email lists, parsing them and storing information in INNODB Table. The problem is it takes around 45 minutes to upload 1 lakh contacts. I am targetting to upload 3 million contacts and looking for optimal way to do that.
Can you give me suggestions towards my approach? I would be very happy.

Thanks,</description>
		<content:encoded><![CDATA[<p>Hi,</p>
<p>I read your article after searching google for many hours and visiting several sites. I really liked the MEMORY Storage engine. I knew it theoratically, but never thought how useful it could in situation like yours.<br />
I am facing similar problem but with inserts of 3 million records from csv file into mysql db.<br />
I am uploading a csv file with 3 million email lists, parsing them and storing information in INNODB Table. The problem is it takes around 45 minutes to upload 1 lakh contacts. I am targetting to upload 3 million contacts and looking for optimal way to do that.<br />
Can you give me suggestions towards my approach? I would be very happy.</p>
<p>Thanks,</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Justin Carmony</title>
		<link>http://www.justincarmony.com/blog/2009/01/12/mysql-40-million-rows-myisam-innodb/comment-page-1/#comment-30274</link>
		<dc:creator>Justin Carmony</dc:creator>
		<pubDate>Fri, 16 Oct 2009 06:35:24 +0000</pubDate>
		<guid isPermaLink="false">http://www.justincarmony.com/blog/?p=356#comment-30274</guid>
		<description>@JDS

Interesting, I&#039;ll have to try that out. My guess is that going between files like that skips any type of temporary tables that are created. I&#039;ll have to test that out, because while putting everything into memory was cool, sometimes that much memory isn&#039;t available. That table that has 40 Million Rows now has around 450 Million Rows, and I don&#039;t think it could hold it in memory entirely.</description>
		<content:encoded><![CDATA[<p>@JDS</p>
<p>Interesting, I&#8217;ll have to try that out. My guess is that going between files like that skips any type of temporary tables that are created. I&#8217;ll have to test that out, because while putting everything into memory was cool, sometimes that much memory isn&#8217;t available. That table that has 40 Million Rows now has around 450 Million Rows, and I don&#8217;t think it could hold it in memory entirely.</p>
]]></content:encoded>
	</item>
</channel>
</rss>

<!-- Performance optimized by W3 Total Cache. Learn more: http://www.w3-edge.com/wordpress-plugins/

Page Caching using memcached
Database Caching 15/26 queries in 0.009 seconds using memcached
Content Delivery Network via Rackspace Cloud Files: c747925.r25.cf2.rackcdn.com

Served from: www.justincarmony.com @ 2012-05-17 23:33:49 -->
