<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	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/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>Applied Miscellany &#187; MySQL</title>
	<atom:link href="http://www.appliedmiscellany.com/blog/archives/category/programming/mysql/feed" rel="self" type="application/rss+xml" />
	<link>http://www.appliedmiscellany.com/blog</link>
	<description>Technology, Tech Policy, Internet, Gadgets, Software, ...</description>
	<lastBuildDate>Tue, 15 May 2007 12:07:19 +0000</lastBuildDate>
	<generator>http://wordpress.org/?v=2.9.2</generator>
	<language>en</language>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
			<item>
		<title>Too Many MySQL Sleep Processes</title>
		<link>http://www.appliedmiscellany.com/blog/archives/41</link>
		<comments>http://www.appliedmiscellany.com/blog/archives/41#comments</comments>
		<pubDate>Tue, 15 May 2007 12:07:19 +0000</pubDate>
		<dc:creator>Scott Karlin</dc:creator>
				<category><![CDATA[All]]></category>
		<category><![CDATA[MySQL]]></category>
		<category><![CDATA[PHP]]></category>
		<category><![CDATA[Programming]]></category>

		<guid isPermaLink="false">http://www.appliedmiscellany.com/blog/archives/41</guid>
		<description><![CDATA[I&#8217;ve been using the CodeIgniter PHP framework to develop a web site that connects to a MySQL database using InnoDB tables and transactions.  I ran into some trouble when I filled the MySQL process list with entries with &#8220;Sleep&#8221; in the command column.  This happened even if I was rendering a page that [...]]]></description>
			<content:encoded><![CDATA[<p>I&#8217;ve been using the <a href="http://www.codeigniter.com/">CodeIgniter</a> PHP framework to develop a web site that connects to a MySQL database using InnoDB tables and transactions.  I ran into some trouble when I filled the MySQL process list with entries with &#8220;Sleep&#8221; in the command column.  This happened even if I was rendering a page that only required reading from the database (and not using transactions).  Solutions on the Internet suggesting that I should reduce the MySQL <code>wait_timeout</code> value to 3 seconds (from a setting of 28,800 seconds) or increasing the number of allowed connections didn&#8217;t ring true.  A post on the <a href="http://www.mysqlperformanceblog.com/2006/11/12/are-php-persistent-connections-evil/">MySQL Performance Blog</a> pointed me in the right direction.  Apparently, persistent connections do not currently play nice with transactions and InnoDB.  The fix was to set the <code>$db['default']['pconnect']</code> value to FALSE in the CodeIgniter database configuration file (application/config/database.php).</p>
]]></content:encoded>
			<wfw:commentRss>http://www.appliedmiscellany.com/blog/archives/41/feed</wfw:commentRss>
		<slash:comments>1</slash:comments>
		</item>
	</channel>
</rss>
