<?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: How to make Microsoft SQL Server cry like a baby</title>
	<atom:link href="http://programmerjoe.com/2007/11/24/how-to-make-microsoft-sql-server-cry-like-a-baby/feed/" rel="self" type="application/rss+xml" />
	<link>http://programmerjoe.com/2007/11/24/how-to-make-microsoft-sql-server-cry-like-a-baby/</link>
	<description>Joe Ludwig's blog</description>
	<lastBuildDate>Fri, 30 Mar 2012 18:45:28 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.0</generator>
	<item>
		<title>By: Joe</title>
		<link>http://programmerjoe.com/2007/11/24/how-to-make-microsoft-sql-server-cry-like-a-baby/comment-page-1/#comment-463080</link>
		<dc:creator>Joe</dc:creator>
		<pubDate>Sun, 20 Feb 2011 19:19:56 +0000</pubDate>
		<guid isPermaLink="false">http://programmerjoe.com/2007/11/24/how-to-make-microsoft-sql-server-cry-like-a-baby/#comment-463080</guid>
		<description>Well that was over three years ago, so I don&#039;t really remember. I&#039;m much more wise about optimizing SQL schemas these days. (And would never build things that way again in many ways.)</description>
		<content:encoded><![CDATA[<p>Well that was over three years ago, so I don&#8217;t really remember. I&#8217;m much more wise about optimizing SQL schemas these days. (And would never build things that way again in many ways.)</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Paul</title>
		<link>http://programmerjoe.com/2007/11/24/how-to-make-microsoft-sql-server-cry-like-a-baby/comment-page-1/#comment-462288</link>
		<dc:creator>Paul</dc:creator>
		<pubDate>Thu, 17 Feb 2011 18:38:41 +0000</pubDate>
		<guid isPermaLink="false">http://programmerjoe.com/2007/11/24/how-to-make-microsoft-sql-server-cry-like-a-baby/#comment-462288</guid>
		<description>It sounds like you guys are randomly trouble shooting your stress test here.

First thing is find out if the problem is CPU, I/O, Network related, etc...

What are your average disk queue lengths sitting at?
   high, you have a disk I/O bottle neck (controller, slow disk, bad filegroup layout, etc...)

What are your CPU averages?  Over 70%
Bad index, etc...

What type of locking hints are you using in your queries?  Is something blocking/dead locking you?  Try sp_who2 stored procedure and look at the DBCC INPUTBUFFER({spid}) here.

You never mentioned anything about the disk setup.  Usually a DB has issue with I/O before CPU depending upon the type of system it is.  Now if I was talking about a web server... I would probalby be more concerned about CPU.</description>
		<content:encoded><![CDATA[<p>It sounds like you guys are randomly trouble shooting your stress test here.</p>
<p>First thing is find out if the problem is CPU, I/O, Network related, etc&#8230;</p>
<p>What are your average disk queue lengths sitting at?<br />
   high, you have a disk I/O bottle neck (controller, slow disk, bad filegroup layout, etc&#8230;)</p>
<p>What are your CPU averages?  Over 70%<br />
Bad index, etc&#8230;</p>
<p>What type of locking hints are you using in your queries?  Is something blocking/dead locking you?  Try sp_who2 stored procedure and look at the DBCC INPUTBUFFER({spid}) here.</p>
<p>You never mentioned anything about the disk setup.  Usually a DB has issue with I/O before CPU depending upon the type of system it is.  Now if I was talking about a web server&#8230; I would probalby be more concerned about CPU.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: The Professor</title>
		<link>http://programmerjoe.com/2007/11/24/how-to-make-microsoft-sql-server-cry-like-a-baby/comment-page-1/#comment-342447</link>
		<dc:creator>The Professor</dc:creator>
		<pubDate>Wed, 29 Apr 2009 19:25:48 +0000</pubDate>
		<guid isPermaLink="false">http://programmerjoe.com/2007/11/24/how-to-make-microsoft-sql-server-cry-like-a-baby/#comment-342447</guid>
		<description>I know this thread is retired by now but I have to add that I have never seen a more appropriate use of the term &quot;crapping the bed&quot; before in my life.  Anyone who has seen SQL go berzerk on a process can completely relate to this and the mess that results.</description>
		<content:encoded><![CDATA[<p>I know this thread is retired by now but I have to add that I have never seen a more appropriate use of the term &#8220;crapping the bed&#8221; before in my life.  Anyone who has seen SQL go berzerk on a process can completely relate to this and the mess that results.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Joe</title>
		<link>http://programmerjoe.com/2007/11/24/how-to-make-microsoft-sql-server-cry-like-a-baby/comment-page-1/#comment-71549</link>
		<dc:creator>Joe</dc:creator>
		<pubDate>Tue, 11 Dec 2007 23:19:12 +0000</pubDate>
		<guid isPermaLink="false">http://programmerjoe.com/2007/11/24/how-to-make-microsoft-sql-server-cry-like-a-baby/#comment-71549</guid>
		<description>We&#039;re running regular backups and truncating the transaction logs when they run.  We just had a problem with the backups that was preventing the truncation.  They&#039;re working fine now, though.</description>
		<content:encoded><![CDATA[<p>We&#8217;re running regular backups and truncating the transaction logs when they run.  We just had a problem with the backups that was preventing the truncation.  They&#8217;re working fine now, though.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: BigRed</title>
		<link>http://programmerjoe.com/2007/11/24/how-to-make-microsoft-sql-server-cry-like-a-baby/comment-page-1/#comment-71075</link>
		<dc:creator>BigRed</dc:creator>
		<pubDate>Mon, 10 Dec 2007 17:43:15 +0000</pubDate>
		<guid isPermaLink="false">http://programmerjoe.com/2007/11/24/how-to-make-microsoft-sql-server-cry-like-a-baby/#comment-71075</guid>
		<description>You have got your recovery model set to simple or are running regular log backups aren&#039;t you? 

If you have chance, backup your database then shrink your transaction log as small as possible while there is no activity then resize it to a proper size to remove fragmentation of the virtual log files and set the autogrow figure to a sensible size.</description>
		<content:encoded><![CDATA[<p>You have got your recovery model set to simple or are running regular log backups aren&#8217;t you? </p>
<p>If you have chance, backup your database then shrink your transaction log as small as possible while there is no activity then resize it to a proper size to remove fragmentation of the virtual log files and set the autogrow figure to a sensible size.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: sidereal</title>
		<link>http://programmerjoe.com/2007/11/24/how-to-make-microsoft-sql-server-cry-like-a-baby/comment-page-1/#comment-69950</link>
		<dc:creator>sidereal</dc:creator>
		<pubDate>Fri, 07 Dec 2007 02:00:08 +0000</pubDate>
		<guid isPermaLink="false">http://programmerjoe.com/2007/11/24/how-to-make-microsoft-sql-server-cry-like-a-baby/#comment-69950</guid>
		<description>Also, as general SQL Server advice, perfmon your Current Disk Queue Length (Logical Disk), % Processor Time (Processor), Transactions/sec (SQLServer:Databases), User Connections (SQLServer:General Statistics), and Average Wait Time (SQLServer:Locks) all the time.  Generally, when something starts crapping the bed you&#039;ll be able to narrow down what to look for by checking which counters go to hell.

And a quick sp_who active followed by slightly less quick  Profiler run tend to be helpful.

Your transaction log should be getting truncated if it&#039;s getting backed up as part of the maintenance plan.  If it hasn&#039;t happened in a while or for some other reason got really big, you need to shrink it (see dbcc shrinkfile).</description>
		<content:encoded><![CDATA[<p>Also, as general SQL Server advice, perfmon your Current Disk Queue Length (Logical Disk), % Processor Time (Processor), Transactions/sec (SQLServer:Databases), User Connections (SQLServer:General Statistics), and Average Wait Time (SQLServer:Locks) all the time.  Generally, when something starts crapping the bed you&#8217;ll be able to narrow down what to look for by checking which counters go to hell.</p>
<p>And a quick sp_who active followed by slightly less quick  Profiler run tend to be helpful.</p>
<p>Your transaction log should be getting truncated if it&#8217;s getting backed up as part of the maintenance plan.  If it hasn&#8217;t happened in a while or for some other reason got really big, you need to shrink it (see dbcc shrinkfile).</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Joe</title>
		<link>http://programmerjoe.com/2007/11/24/how-to-make-microsoft-sql-server-cry-like-a-baby/comment-page-1/#comment-67754</link>
		<dc:creator>Joe</dc:creator>
		<pubDate>Sat, 01 Dec 2007 19:33:33 +0000</pubDate>
		<guid isPermaLink="false">http://programmerjoe.com/2007/11/24/how-to-make-microsoft-sql-server-cry-like-a-baby/#comment-67754</guid>
		<description>We still aren&#039;t sure exactly what was going on with problem #1. 

Problem #2 we have a better handle on.  Steve was exactly right:  The transaction log was autogrowing and that process was blocking all queries for a full minute.  It seems that there is some issue with the auto-truncation of that log, so it&#039;s growing forever.  It takes a while to grow a 50GB file. :)

Hopefully the dump-to-file solution will resolve the flogger DB problem and both these will be behind us.</description>
		<content:encoded><![CDATA[<p>We still aren&#8217;t sure exactly what was going on with problem #1. </p>
<p>Problem #2 we have a better handle on.  Steve was exactly right:  The transaction log was autogrowing and that process was blocking all queries for a full minute.  It seems that there is some issue with the auto-truncation of that log, so it&#8217;s growing forever.  It takes a while to grow a 50GB file. <img src='http://programmerjoe.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
<p>Hopefully the dump-to-file solution will resolve the flogger DB problem and both these will be behind us.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Steve</title>
		<link>http://programmerjoe.com/2007/11/24/how-to-make-microsoft-sql-server-cry-like-a-baby/comment-page-1/#comment-66102</link>
		<dc:creator>Steve</dc:creator>
		<pubDate>Mon, 26 Nov 2007 21:31:32 +0000</pubDate>
		<guid isPermaLink="false">http://programmerjoe.com/2007/11/24/how-to-make-microsoft-sql-server-cry-like-a-baby/#comment-66102</guid>
		<description>My friend Jeff Ward pointed me at your blog, and you should be able to get substantially better performance on that hardware then what you&#039;ve described with SQL Server 2005.

Regarding your first problem, are you seeing a substantial change in your SQL Server buffer pool size during the connection lock?  What connection authentication mechanism are you using?  Are you using SQL Server connection pooling?

The second indicates that you&#039;re definitely blocking on something.  There are a couple of things that can cause this to happen.  The first is a lock that goes way out of scope, which you should be able to track with the profiler or the lock management views.  The second is if you&#039;re not managing an autogrow tranlog file and the OS is slow at allocating new volume space.  The last is a bad IO drivers, which were common on some of last year&#039;s HP servers if that&#039;s appropriate to you.</description>
		<content:encoded><![CDATA[<p>My friend Jeff Ward pointed me at your blog, and you should be able to get substantially better performance on that hardware then what you&#8217;ve described with SQL Server 2005.</p>
<p>Regarding your first problem, are you seeing a substantial change in your SQL Server buffer pool size during the connection lock?  What connection authentication mechanism are you using?  Are you using SQL Server connection pooling?</p>
<p>The second indicates that you&#8217;re definitely blocking on something.  There are a couple of things that can cause this to happen.  The first is a lock that goes way out of scope, which you should be able to track with the profiler or the lock management views.  The second is if you&#8217;re not managing an autogrow tranlog file and the OS is slow at allocating new volume space.  The last is a bad IO drivers, which were common on some of last year&#8217;s HP servers if that&#8217;s appropriate to you.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Joe</title>
		<link>http://programmerjoe.com/2007/11/24/how-to-make-microsoft-sql-server-cry-like-a-baby/comment-page-1/#comment-66101</link>
		<dc:creator>Joe</dc:creator>
		<pubDate>Mon, 26 Nov 2007 21:31:23 +0000</pubDate>
		<guid isPermaLink="false">http://programmerjoe.com/2007/11/24/how-to-make-microsoft-sql-server-cry-like-a-baby/#comment-66101</guid>
		<description>We&#039;re definitely keeping the connections open and re-using them.  Each server process makes its connections at startup, queries on them a bunch of times, and closes the connection at shutdown. That&#039;s still a fair number of new connections because most zones only last 15 minutes.  When there are 1500 of them that&#039;s 100 new zones per minute or 1.6 per second. Still not nearly as many as there would be if we didn&#039;t persist connections though. :)</description>
		<content:encoded><![CDATA[<p>We&#8217;re definitely keeping the connections open and re-using them.  Each server process makes its connections at startup, queries on them a bunch of times, and closes the connection at shutdown. That&#8217;s still a fair number of new connections because most zones only last 15 minutes.  When there are 1500 of them that&#8217;s 100 new zones per minute or 1.6 per second. Still not nearly as many as there would be if we didn&#8217;t persist connections though. <img src='http://programmerjoe.com/wp-includes/images/smilies/icon_smile.gif' alt=':)' class='wp-smiley' /> </p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Jeff Ward</title>
		<link>http://programmerjoe.com/2007/11/24/how-to-make-microsoft-sql-server-cry-like-a-baby/comment-page-1/#comment-66098</link>
		<dc:creator>Jeff Ward</dc:creator>
		<pubDate>Mon, 26 Nov 2007 21:26:16 +0000</pubDate>
		<guid isPermaLink="false">http://programmerjoe.com/2007/11/24/how-to-make-microsoft-sql-server-cry-like-a-baby/#comment-66098</guid>
		<description>Hey Joe!

Was talking to DB administrator friend of mine about your problem and he had few suggestion for you.

He said to make sure you&#039;re caching SQL connections.  Managing new connections, login, authentication and security is very expensive - your SQL box has better things to do then overhead. By making a new connection per query or request, you&#039;re treating SQL as if it were IIS, which its not - you want to take advantage of SQL connection pools

He does say that you CAN use IIS as a proxy to SQL Server, and that might help.

As for your query problems, he says he&#039;d have to look at it, but if you want he said I can pass along his email.</description>
		<content:encoded><![CDATA[<p>Hey Joe!</p>
<p>Was talking to DB administrator friend of mine about your problem and he had few suggestion for you.</p>
<p>He said to make sure you&#8217;re caching SQL connections.  Managing new connections, login, authentication and security is very expensive &#8211; your SQL box has better things to do then overhead. By making a new connection per query or request, you&#8217;re treating SQL as if it were IIS, which its not &#8211; you want to take advantage of SQL connection pools</p>
<p>He does say that you CAN use IIS as a proxy to SQL Server, and that might help.</p>
<p>As for your query problems, he says he&#8217;d have to look at it, but if you want he said I can pass along his email.</p>
]]></content:encoded>
	</item>
</channel>
</rss>

