Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2005 Forums
 SQL Server Administration (2005)
 Fragmentation

Author  Topic 

swekik
Posting Yak Master

126 Posts

Posted - 2008-08-28 : 13:29:51
Can any body tell me what are the acceptable values for the fragmentation??

I know abt the scan density,which has to be >=80%

Wht are the other acceptable values like
1.Logical scan Fragmentation?
2.Extent Scan Fragmentation?

sodeep
Master Smack Fu Yak Hacker

7174 Posts

Posted - 2008-08-28 : 13:41:05
quote:
Originally posted by swekik

Can any body tell me what are the acceptable values for the fragmentation??

I know abt the scan density,which has to be >=80% >95% better

Wht are the other acceptable values like
1.Logical scan Fragmentation? 0 or closer to it is better
2.Extent Scan Fragmentation? 0 or closer to it is better

Go to Top of Page

tkizer
Almighty SQL Goddess

38200 Posts

Posted - 2008-08-28 : 13:41:46
I defragment anything over 10%, but I'm thinking of switching it to 50%.

Here's my script:
http://weblogs.sqlteam.com/tarad/archive/2007/11/27/60415.aspx

Note: I've got a new version of isp_ALTER_INDEX coming out next week.

Tara Kizer
Microsoft MVP for Windows Server System - SQL Server
http://weblogs.sqlteam.com/tarad/

Subscribe to my blog
Go to Top of Page

swekik
Posting Yak Master

126 Posts

Posted - 2008-08-28 : 15:28:34
Is it for 2005 Tkizer?
Go to Top of Page

tkizer
Almighty SQL Goddess

38200 Posts

Posted - 2008-08-28 : 15:33:27
Did you read the first two paragraphs in the link?

Tara Kizer
Microsoft MVP for Windows Server System - SQL Server
http://weblogs.sqlteam.com/tarad/

Subscribe to my blog
Go to Top of Page

swekik
Posting Yak Master

126 Posts

Posted - 2008-08-28 : 15:34:35
I mean the new version which is coming out next week.
Go to Top of Page

tkizer
Almighty SQL Goddess

38200 Posts

Posted - 2008-08-28 : 15:39:31
Yes it's for 2005. It's just an update to the one in the link I posted.

Tara Kizer
Microsoft MVP for Windows Server System - SQL Server
http://weblogs.sqlteam.com/tarad/

Subscribe to my blog
Go to Top of Page

tfountain
Constraint Violating Yak Guru

491 Posts

Posted - 2008-08-28 : 17:39:54
Tara,

Nice script. We have 2 scripts right now that we run. One is for indexes w/o LOB data and the other is for indexes with LOB data (I inherited it this way!). I think yours is more robust since it accounts for scenarios ours does not. Even though we don't use those features yet I see no harm in preparing for the day we do.

But aside from that, what type of schedule do you find yourself running this script on? From prior conversations I know you deal with databases much larger than what we have, but our databases are extremely busy. I'd like to gauge your activity/rebuild schedule against mine since I very well might borrow your code (if you have no objections that is!).
Go to Top of Page

tkizer
Almighty SQL Goddess

38200 Posts

Posted - 2008-08-28 : 17:49:16
I've actually got it as a blog:
http://weblogs.sqlteam.com/tarad/archive/2008/06/30/SQL-Server-jobs-on-production-instances.aspx

Wait for next week's code as it fixes two bugs.

Tara Kizer
Microsoft MVP for Windows Server System - SQL Server
http://weblogs.sqlteam.com/tarad/

Subscribe to my blog
Go to Top of Page

Ola Hallengren
Starting Member

33 Posts

Posted - 2008-08-29 : 20:32:48
Tara's solution is great. I have a stored procedure that works a bit differently that you can look at as well.
http://ola.hallengren.com/sql-server-index-and-statistics-maintenance.html

Ola Hallengren
http://ola.hallengren.com
Go to Top of Page

tkizer
Almighty SQL Goddess

38200 Posts

Posted - 2008-08-30 : 00:32:33
Ola, do you only post here to promote your blog/scripts?

Tara Kizer
Microsoft MVP for Windows Server System - SQL Server
http://weblogs.sqlteam.com/tarad/

Subscribe to my blog
Go to Top of Page
   

- Advertisement -