Log in
::
Register
::
Not logged in
Home
Tags
Articles
Editorials
Stairways
Forums
Scripts
Videos
Blogs
QotD
Books
Ask SSC
SQL Jobs
Training
Authors
About us
Contact us
Newsletters
Write for us
Recent Posts
Recent Posts
Popular Topics
Popular Topics
Home
Search
Members
Calendar
Who's On
Home
»
SQL Server 2005
»
Administering
»
fillfactor
fillfactor
Rate Topic
Display Mode
Topic Options
Author
Message
charipg
charipg
Posted Wednesday, July 29, 2009 4:54 AM
Old Hand
Group: General Forum Members
Last Login: Thursday, May 16, 2013 12:43 AM
Points: 378,
Visits: 897
what is fillfactor and what are the advantages and disadvantages?
Post #761380
ps.
ps.
Posted Wednesday, July 29, 2009 6:34 AM
SSCrazy
Group: General Forum Members
Last Login: Thursday, May 02, 2013 2:32 AM
Points: 2,236,
Visits: 3,620
charipg (7/29/2009)
what is fillfactor and what are the advantages and disadvantages?
Refer this BOL link to know about fill factor.
http://msdn.microsoft.com/en-us/library/ms177459.aspx
A fill factor of 30 means 30% of space within the data page will be kept vacant, so that when you insert more rows later, they would be accomodated within this free space. This means sql server will not ask for new pages to accomodate your data every time you insert and hence pages will be contiguous, leading to better performance.
Pradeep Singh
Post #761453
Grant Fritchey
Grant Fritchey
Posted Wednesday, July 29, 2009 6:39 AM
SSChampion
Group: General Forum Members
Last Login: Today @ 3:40 PM
Points: 13,380,
Visits: 25,164
And fill factor is applicable when creating or rebuilding an index. Once an index is operation or it gets reorganized, fill factor is no longer taken into account.
----------------------------------------------------
"The credit belongs to the man who is actually in the arena, whose face is marred by dust and sweat and blood..." Theodore Roosevelt
The Scary DBA
Author of:
SQL Server 2012 Query Performance Tuning
SQL Server 2008 Query Performance Tuning Distilled
and
SQL Server Execution Plans
Product Evangelist for
Red Gate Software
Post #761463
Animal Magic
Animal Magic
Posted Wednesday, July 29, 2009 12:54 PM
SSC Eights!
Group: General Forum Members
Last Login: Today @ 9:08 AM
Points: 983,
Visits: 13,350
ps (7/29/2009)
charipg (7/29/2009)
what is fillfactor and what are the advantages and disadvantages?
Refer this BOL link to know about fill factor.
http://msdn.microsoft.com/en-us/library/ms177459.aspx
A fill factor of 30 means 30% of space within the data page will be kept vacant, so that when you insert more rows later, they would be accomodated within this free space. This means sql server will not ask for new pages to accomodate your data every time you insert and hence pages will be contiguous, leading to better performance.
Just to continue on Pradeeps response, the disadvantage of a low fill factor is that the index takes up more disk space. the space is allocated ready for the data to go into the page/extent but if you have say 10% fill factor then only 10% is acually used, which means your index will take up 10 times more space than the same index will a fill factor of 100 (or 0, which is the same as 100)
The dissadvantage (which you can probably also work out from Pradeeps response) is that if you have a high fill factor and you have a lot of inserts you will have a lot of page splits which will cause fragmentation (the reason we rebuild/reindex indexes).
Post #761901
Steve Jones - SSC Editor
Steve Jones - SSC Editor
Posted Wednesday, July 29, 2009 1:00 PM
SSC-Dedicated
Group: Administrators
Last Login: Today @ 3:26 PM
Points: 31,425,
Visits: 13,738
This also impacts performance. Lower fillfactor, more reads to get the data.
You have to find a good balance for heavily accessed tables that accounts for reads and writes.
Follow me on Twitter:
@way0utwest
Forum Etiquette: How to post data/code on a forum to get the best help
Post #761909
Katmai Stratovolcano
Katmai Stratovolcano
Posted Wednesday, July 29, 2009 1:16 PM
SSC-Enthusiastic
Group: General Forum Members
Last Login: Monday, September 28, 2009 11:23 AM
Points: 184,
Visits: 166
hi,
the fillfactor effect specifies the percentage of space filled on index data pages when an index is initially created. The default fillfactor setting of zero, which can be altered at the global server level through a configuration option, will cause an index to be almost filled to capacity, with only a small amount of space being left at the upper level region of the index. A 100% setting completely fills each index page.
One important thing to remember is that this amount is not adhered to after the index is first built. An index can be rebuilt and the original fillfactor setting re-instituted with the variety of DBCC index rebuild or ALTER INDEX (SQL Server 2005) commands.
So, what exactly are the considerations with fillfactor? Higher fillfactor settings should result in less index pages which in turn should result in fewer pages read during scan operations. As been mentioned many times already, less I/O generally equates to better performance.
However, high fillfactor settings can also result in page splits for clustered indexes when SQL Server enforces the sort order of the clustered index during INSERT or UPDATE actions. This happens because SQL Server does not have room on an index page for the requested change, so it has to split the page to perform the modification. This can result in performance degradation and can be confirmed by carefully watching the page splits counter, available from the page_splits query below:
select
cntr_value
from
master.dbo.sysperfinfo
where
counter_name = 'Page Splits/sec' and
object_name like '%Access methods%'
If there are tables present that are primarily read only, a fillfactor setting of 100 should be used to reduce the number of produced index pages.
If, however, there are tables present with high rates of INSERT, UPDATE and DELETE activity, lower fillfactor settings of 50-60% should be used. This will need to be coupled with periodic index rebuilds that will re-establish the fillfactor setting to keep DML running smooth through the indexes.
A mixed environment can work well with fillfactor settings in the neighborhood of 75%. One last piece of advice: for small indexes that have few pages, time should not be wasted worrying about fillfactor as it will not be capable of impacting the database’s performance for the worse.
Post #761921
homebrew01
homebrew01
Posted Wednesday, July 29, 2009 1:38 PM
SSCrazy
Group: General Forum Members
Last Login: Today @ 8:12 AM
Points: 2,554,
Visits: 7,209
ps (7/29/2009)
charipg (7/29/2009)
what is fillfactor and what are the advantages and disadvantages?
Refer this BOL link to know about fill factor.
http://msdn.microsoft.com/en-us/library/ms177459.aspx
A fill factor of 30 means 30% of space within the data page will be kept vacant, so that when you insert more rows later, they would be accomodated within this free space. This means sql server will not ask for new pages to accomodate your data every time you insert and hence pages will be contiguous, leading to better performance.
I think you meant: A fill factor of 70 means 30% of space within the data page will be kept vacant
Post #761934
ps.
ps.
Posted Wednesday, July 29, 2009 9:00 PM
SSCrazy
Group: General Forum Members
Last Login: Thursday, May 02, 2013 2:32 AM
Points: 2,236,
Visits: 3,620
homebrew01 (7/29/2009)
I think you meant: A fill factor of 70 means 30% of space within the data page will be kept vacant
Thanks for the correction
Pradeep Singh
Post #762083
charipg
charipg
Posted Thursday, July 30, 2009 12:12 AM
Old Hand
Group: General Forum Members
Last Login: Thursday, May 16, 2013 12:43 AM
Points: 378,
Visits: 897
thanks to all........
Post #762170
« Prev Topic
|
Next Topic »
Permissions
You
cannot
post new topics.
You
cannot
post topic replies.
You
cannot
post new polls.
You
cannot
post replies to polls.
You
cannot
edit your own topics.
You
cannot
delete your own topics.
You
cannot
edit other topics.
You
cannot
delete other topics.
You
cannot
edit your own posts.
You
cannot
edit other posts.
You
cannot
delete your own posts.
You
cannot
delete other posts.
You
cannot
post events.
You
cannot
edit your own events.
You
cannot
edit other events.
You
cannot
delete your own events.
You
cannot
delete other events.
You
cannot
send private messages.
You
cannot
send emails.
You
may
read topics.
You
cannot
rate topics.
You
cannot
vote within polls.
You
cannot
upload attachments.
You
may
download attachments.
You
cannot
post HTML code.
You
cannot
edit HTML code.
You
cannot
post IFCode.
You
cannot
post JavaScript.
You
cannot
post EmotIcons.
You
cannot
post or upload images.
Copyright © 2002-2013 Simple Talk Publishing. All Rights Reserved.
Privacy Policy.
Terms of Use.
Report Abuse.