<?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: Help &#8211; Slow MySQL Insert?</title>
	<atom:link href="http://www.darcynorman.net/2006/11/14/help-slow-mysql-insert/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.darcynorman.net/2006/11/14/help-slow-mysql-insert/</link>
	<description>apparently much happier in person</description>
	<lastBuildDate>Sat, 21 Nov 2009 05:03:04 -0700</lastBuildDate>
	<generator>http://wordpress.org/?v=2.8.6</generator>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
		<item>
		<title>By: Press Release</title>
		<link>http://www.darcynorman.net/2006/11/14/help-slow-mysql-insert/#comment-195247</link>
		<dc:creator>Press Release</dc:creator>
		<pubDate>Sun, 07 Jun 2009 21:41:36 +0000</pubDate>
		<guid isPermaLink="false">1110631599#comment-195247</guid>
		<description>One of the little bugs we found with inserts lately is running 64 bit software on NON-64 bit cpus.  The reads seem to work normally as you described but the inserts are nightmarishly slow.   64 bit software deals with buffers differently and while its not technically a bug it is annoying.  So if you have CPU&#039;s that are not dual core and are running 64bit software this will explain your results.</description>
		<content:encoded><![CDATA[<p>One of the little bugs we found with inserts lately is running 64 bit software on NON-64 bit cpus.  The reads seem to work normally as you described but the inserts are nightmarishly slow.   64 bit software deals with buffers differently and while its not technically a bug it is annoying.  So if you have CPU&#8217;s that are not dual core and are running 64bit software this will explain your results.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: alman</title>
		<link>http://www.darcynorman.net/2006/11/14/help-slow-mysql-insert/#comment-194749</link>
		<dc:creator>alman</dc:creator>
		<pubDate>Fri, 27 Mar 2009 14:29:16 +0000</pubDate>
		<guid isPermaLink="false">1110631599#comment-194749</guid>
		<description>I can bulk copy from csv&#039;s into a staging db on Mysql. That process take about 2-3 minutes. I then, make some changes and insert into production - which take almost 2 hours for the same tables. It is painful. I am set to INNDB, have modified pool buffers, removed keys, added keys, flushed tables ... 
Nothing seems to help. Its not network as staging and production are on the same server!

Why is MySQL soo slow with inserts???</description>
		<content:encoded><![CDATA[<p>I can bulk copy from csv&#8217;s into a staging db on Mysql. That process take about 2-3 minutes. I then, make some changes and insert into production &#8211; which take almost 2 hours for the same tables. It is painful. I am set to INNDB, have modified pool buffers, removed keys, added keys, flushed tables &#8230;<br />
Nothing seems to help. Its not network as staging and production are on the same server!</p>
<p>Why is MySQL soo slow with inserts???</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Sami Khan</title>
		<link>http://www.darcynorman.net/2006/11/14/help-slow-mysql-insert/#comment-82648</link>
		<dc:creator>Sami Khan</dc:creator>
		<pubDate>Wed, 31 Dec 1969 17:00:00 +0000</pubDate>
		<guid isPermaLink="false">1110631599#comment-82648</guid>
		<description>If you can get the host to install mtop you can take a look at what query exactly is taking so long and perhaps to to rewrite it... Also how are you producing the sql files, are they made using mysqldump or phpMyAdmin? Also, are both the producer and the consumer of the sql file using the same version of mysql or phpmyadmin?</description>
		<content:encoded><![CDATA[<p>If you can get the host to install mtop you can take a look at what query exactly is taking so long and perhaps to to rewrite it&#8230; Also how are you producing the sql files, are they made using mysqldump or phpMyAdmin? Also, are both the producer and the consumer of the sql file using the same version of mysql or phpmyadmin?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Chris Garrett</title>
		<link>http://www.darcynorman.net/2006/11/14/help-slow-mysql-insert/#comment-82651</link>
		<dc:creator>Chris Garrett</dc:creator>
		<pubDate>Wed, 31 Dec 1969 17:00:00 +0000</pubDate>
		<guid isPermaLink="false">1110631599#comment-82651</guid>
		<description>If you have a bunch of indexes on the tables that can slow inserts down. It could be though that server is just really overloaded. 

Rather than use a .sql file to do inserts bulk import could be faster?

</description>
		<content:encoded><![CDATA[<p>If you have a bunch of indexes on the tables that can slow inserts down. It could be though that server is just really overloaded. </p>
<p>Rather than use a .sql file to do inserts bulk import could be faster?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: greggles</title>
		<link>http://www.darcynorman.net/2006/11/14/help-slow-mysql-insert/#comment-82652</link>
		<dc:creator>greggles</dc:creator>
		<pubDate>Wed, 31 Dec 1969 17:00:00 +0000</pubDate>
		<guid isPermaLink="false">1110631599#comment-82652</guid>
		<description>I was going to guess network speed, but you said &quot;I&#039;ve tried command line mysql directly on the server, with the same range of very slow times.&quot; which I take to mean that you uploaded your file to the server and then used something like mysql -p db_name &lt; myfile.sql

Other than that...you might be able to use some of the &quot;show&quot; statements to see what variables are set on the box to determine the problem.  Or, ask the hosting provider.  It&#039;s a managed box after all - they are paid to make it work, right?</description>
		<content:encoded><![CDATA[<p>I was going to guess network speed, but you said &#8220;I&#8217;ve tried command line mysql directly on the server, with the same range of very slow times.&#8221; which I take to mean that you uploaded your file to the server and then used something like mysql -p db_name < myfile.sql</p>
<p>Other than that&#8230;you might be able to use some of the &#8220;show&#8221; statements to see what variables are set on the box to determine the problem.  Or, ask the hosting provider.  It&#8217;s a managed box after all &#8211; they are paid to make it work, right?</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: dnorman</title>
		<link>http://www.darcynorman.net/2006/11/14/help-slow-mysql-insert/#comment-82653</link>
		<dc:creator>dnorman</dc:creator>
		<pubDate>Wed, 31 Dec 1969 17:00:00 +0000</pubDate>
		<guid isPermaLink="false">1110631599#comment-82653</guid>
		<description>sami - I&#039;ll see if they can install mtop. The .sql files come from a couple sources - some are created by phpMyAdmin from databases on that server, and some are &quot;stock&quot; .sql files like the one that comes with Drupal.

MySQL is actually running on a separate box that I can only access from our hosted server, and the stuff that&#039;s installed on the hosted server is a bit limited.

Chris - this is for new databases, too. create database... import from .sql file... sloooooooowness.  I think we need to find a way to make .sql imports work, since that&#039;s how the web apps package up their default data.

Greggles - it might be network speed. mysql is on a different physical server, but it&#039;s on the same LAN, as our hosted server. I can&#039;t log in via SSH to the actual MySQL server, so I can&#039;t try command-line MySQL from localhost, but running command-line MySQL from our hosted server on the same LAN as the MySQL server shows the same slowness.

I&#039;ve taken a look at the server variables (via phpMyAdmin&#039;s UI) and can&#039;t see anything that would be causing the slowness. The dba provided to us hasn&#039;t found anything either. I keep asking them, and sending suggestions/questions, but they&#039;re being rather unresponsive so I&#039;m getting desperate. We have to use this provider for political reasons - I&#039;d much rather just buy a new XServe and manage the box myself, but we&#039;re not allowed to do that.</description>
		<content:encoded><![CDATA[<p>sami &#8211; I&#8217;ll see if they can install mtop. The .sql files come from a couple sources &#8211; some are created by phpMyAdmin from databases on that server, and some are &#8220;stock&#8221; .sql files like the one that comes with Drupal.</p>
<p>MySQL is actually running on a separate box that I can only access from our hosted server, and the stuff that&#8217;s installed on the hosted server is a bit limited.</p>
<p>Chris &#8211; this is for new databases, too. create database&#8230; import from .sql file&#8230; sloooooooowness.  I think we need to find a way to make .sql imports work, since that&#8217;s how the web apps package up their default data.</p>
<p>Greggles &#8211; it might be network speed. mysql is on a different physical server, but it&#8217;s on the same LAN, as our hosted server. I can&#8217;t log in via SSH to the actual MySQL server, so I can&#8217;t try command-line MySQL from localhost, but running command-line MySQL from our hosted server on the same LAN as the MySQL server shows the same slowness.</p>
<p>I&#8217;ve taken a look at the server variables (via phpMyAdmin&#8217;s UI) and can&#8217;t see anything that would be causing the slowness. The dba provided to us hasn&#8217;t found anything either. I keep asking them, and sending suggestions/questions, but they&#8217;re being rather unresponsive so I&#8217;m getting desperate. We have to use this provider for political reasons &#8211; I&#8217;d much rather just buy a new XServe and manage the box myself, but we&#8217;re not allowed to do that.</p>
]]></content:encoded>
	</item>
</channel>
</rss>
