SQL Clone
SQLServerCentral is supported by Redgate
 
Log in  ::  Register  ::  Not logged in
 
 
 


clearing SQL cache


clearing SQL cache

Author
Message
vkkrishn
vkkrishn
Forum Newbie
Forum Newbie (1 reputation)Forum Newbie (1 reputation)Forum Newbie (1 reputation)Forum Newbie (1 reputation)Forum Newbie (1 reputation)Forum Newbie (1 reputation)Forum Newbie (1 reputation)Forum Newbie (1 reputation)

Group: General Forum Members
Points: 1 Visits: 11
Hello,
We have our application running on sql server 2005. Recently we started slowing down of the database and timeouts. Once we clear the SQL cache, it turns normal again. What all can be the causes of this issue we are facing. And what can we do to avoid this. Please help!
SQLRNNR
SQLRNNR
SSC-Dedicated
SSC-Dedicated (33K reputation)SSC-Dedicated (33K reputation)SSC-Dedicated (33K reputation)SSC-Dedicated (33K reputation)SSC-Dedicated (33K reputation)SSC-Dedicated (33K reputation)SSC-Dedicated (33K reputation)SSC-Dedicated (33K reputation)

Group: General Forum Members
Points: 33002 Visits: 18560
Are you getting any error messages along with the slowdown or are you just experiencing general slowness? Are you seeing application timeouts?



Jason AKA CirqueDeSQLeil
I have given a name to my pain...
MCM SQL Server, MVP


SQL RNNR

Posting Performance Based Questions - Gail Shaw

Dave Ballantyne
Dave Ballantyne
SSCrazy
SSCrazy (3K reputation)SSCrazy (3K reputation)SSCrazy (3K reputation)SSCrazy (3K reputation)SSCrazy (3K reputation)SSCrazy (3K reputation)SSCrazy (3K reputation)SSCrazy (3K reputation)

Group: General Forum Members
Points: 2976 Visits: 8370
Do you mean the procedure cache (DBCC FREEPROCCACHE) or the buffer cache(DBCC DROPCLEANBUFFERS) ?

Im guessing the former, could potentially be parameter sniffing http://www.sqlpointers.com/2006/11/parameter-sniffing-stored-procedures.html



Clear Sky SQL
My Blog
ALZDBA
ALZDBA
SSChampion
SSChampion (12K reputation)SSChampion (12K reputation)SSChampion (12K reputation)SSChampion (12K reputation)SSChampion (12K reputation)SSChampion (12K reputation)SSChampion (12K reputation)SSChampion (12K reputation)

Group: General Forum Members
Points: 12468 Visits: 8930
What service pack is your sql2005 on ?

Please post the result of
select @@version 



or
Select Serverproperty( 'ProductVersion' ) as ProductVersion 
, Serverproperty( 'ProductLevel' ) as ProductLevel
, Serverproperty( 'ResourceLastUpdateDateTime' ) as ResourceLastUpdateDateTime
, Serverproperty( 'ResourceVersion' ) as ResourceVersion
, Serverproperty( 'Edition' ) as Edition
, Serverproperty( 'EditionID' ) as EditionID



What action did you perform to "clear the cache" ?

Johan


Dont drive faster than your guardian angel can fly ...
but keeping both feet on the ground wont get you anywhere w00t

- How to post Performance Problems
- How to post data/code to get the best help


- How to prevent a sore throat after hours of presenting ppt ?


press F1 for solution, press shift+F1 for urgent solution :-D


Need a bit of Powershell? How about this

Who am I ? Sometimes this is me Alien but most of the time this is me Hehe
Paul White
Paul White
SSCoach
SSCoach (16K reputation)SSCoach (16K reputation)SSCoach (16K reputation)SSCoach (16K reputation)SSCoach (16K reputation)SSCoach (16K reputation)SSCoach (16K reputation)SSCoach (16K reputation)

Group: General Forum Members
Points: 16132 Visits: 11355
Dave Ballantyne (4/7/2010)
Do you mean the procedure cache (DBCC FREEPROCCACHE) or the buffer cache(DBCC DROPCLEANBUFFERS) ?

Im guessing the former, could potentially be parameter sniffing http://www.sqlpointers.com/2006/11/parameter-sniffing-stored-procedures.html

I like guessing games :-)
My guess is procedure cache bloat due to ad-hoc queries.
http://blogs.msdn.com/sqlprogrammability/archive/2007/01/23/4-0-useful-queries-on-dmv-s-to-understand-plan-cache-behavior.aspx
DBCC FREESYSTEMCACHE('SQL Plans');



Paul White
SQLPerformance.com
SQLblog.com
@SQL_Kiwi
SQLRNNR
SQLRNNR
SSC-Dedicated
SSC-Dedicated (33K reputation)SSC-Dedicated (33K reputation)SSC-Dedicated (33K reputation)SSC-Dedicated (33K reputation)SSC-Dedicated (33K reputation)SSC-Dedicated (33K reputation)SSC-Dedicated (33K reputation)SSC-Dedicated (33K reputation)

Group: General Forum Members
Points: 33002 Visits: 18560
vkkrishn,
Do you have any of the information / answers for the questions asked?



Jason AKA CirqueDeSQLeil
I have given a name to my pain...
MCM SQL Server, MVP


SQL RNNR

Posting Performance Based Questions - Gail Shaw

Dave Ballantyne
Dave Ballantyne
SSCrazy
SSCrazy (3K reputation)SSCrazy (3K reputation)SSCrazy (3K reputation)SSCrazy (3K reputation)SSCrazy (3K reputation)SSCrazy (3K reputation)SSCrazy (3K reputation)SSCrazy (3K reputation)

Group: General Forum Members
Points: 2976 Visits: 8370
Paul White NZ (4/7/2010)
My guess is procedure cache bloat due to ad-hoc queries.


Which reminds me , ive still got a half finished blog on forced parametrization hanging around.



Clear Sky SQL
My Blog
Paul White
Paul White
SSCoach
SSCoach (16K reputation)SSCoach (16K reputation)SSCoach (16K reputation)SSCoach (16K reputation)SSCoach (16K reputation)SSCoach (16K reputation)SSCoach (16K reputation)SSCoach (16K reputation)

Group: General Forum Members
Points: 16132 Visits: 11355
Dave Ballantyne (4/7/2010)
Paul White NZ (4/7/2010)
My guess is procedure cache bloat due to ad-hoc queries.

Which reminds me , ive still got a half finished blog on forced parametrization hanging around.

Well get on with it then!!!

Laugh :-D :-P



Paul White
SQLPerformance.com
SQLblog.com
@SQL_Kiwi
sam.alexander
sam.alexander
SSC Journeyman
SSC Journeyman (79 reputation)SSC Journeyman (79 reputation)SSC Journeyman (79 reputation)SSC Journeyman (79 reputation)SSC Journeyman (79 reputation)SSC Journeyman (79 reputation)SSC Journeyman (79 reputation)SSC Journeyman (79 reputation)

Group: General Forum Members
Points: 79 Visits: 150
vkkrishn (4/6/2010)
Hello,
We have our application running on sql server 2005. Recently we started slowing down of the database and timeouts. Once we clear the SQL cache, it turns normal again. What all can be the causes of this issue we are facing. And what can we do to avoid this. Please help!


We ran into this exact situation not long ago, and what I found was SQL created different cached execution plans based on the parameters we were passing into a procedure, and in some cases the cached execution plan, though ran speedy for some parameters ran very inefficiency with other parameters.

Once I found the troublesome procedure my fix was to view the execution plan and create a few indexes so the same, more efficient cached execution plan was created regardless of parameters used, which worked.

The first thing you need to do is determine what process is taking the longest to run. You may be able to monitor your processes and see which ones are taking a long time to run and go from there.

Let me know if you need more details and I can send you some of what we did to find the troublesome procedure then remedy the latency.

Take care --

Sam
Go


Permissions

You can't post new topics.
You can't post topic replies.
You can't post new polls.
You can't post replies to polls.
You can't edit your own topics.
You can't delete your own topics.
You can't edit other topics.
You can't delete other topics.
You can't edit your own posts.
You can't edit other posts.
You can't delete your own posts.
You can't delete other posts.
You can't post events.
You can't edit your own events.
You can't edit other events.
You can't delete your own events.
You can't delete other events.
You can't send private messages.
You can't send emails.
You can read topics.
You can't vote in polls.
You can't upload attachments.
You can download attachments.
You can't post HTML code.
You can't edit HTML code.
You can't post IFCode.
You can't post JavaScript.
You can post emoticons.
You can't post or upload images.

Select a forum

































































































































































SQLServerCentral


Search