Blog - comments

Can someone please forward me all the netbackup commands with detail information I want CLI.

Shekhar D

thanks like it

internet shop
Thanks,I have installed AV server successfully but agent deployment failed on windows2008 OS. After ...
Silvere
Hi Eyal, thanks for your comment. I'm not sure to understand what you mean by predicate here but let...
Hi Greg, thanks for your comment. No, it doesn't matter because dbcc checkdb will issue an internal ...
Blog Nathan Courtine Improving your SharePoint performance using SQL Server settings

dbi services Blog

Welcome to the dbi services Blog! This IT blog focuses on database, middleware, and OS technologies such as Oracle, Microsoft SQL Server & SharePoint, EMC Documentum, MySQL, PostgreSQL, Sybase, Unix/Linux, etc. The dbi services blog represents the view of our consultants, not necessarily that of dbi services. Feel free to comment on our blog postings.

  • Home
    Home This is where you can find all the blog posts throughout the site.
  • Categories
    Categories Displays a list of categories from this blog.
  • Tags
    Tags Displays a list of tags that have been used in the blog.
  • Bloggers
    Bloggers Search for your favorite blogger from this site.

Improving your SharePoint performance using SQL Server settings

SharePoint performance is a recursive problem and preoccupation. As a Database Administrator, we have to deal with SharePoint when configuring SQL Server databases.

In this article, I will propose a list of best practices in SQL Server settings aimed to reduce SharePoint performance issues.

This article is inspired from the presentation Optimizing SQL Server for Speedy SharePoint by Sahil Malik held at the European SharePoint Conference 2014 in Barcelona.

 

Autogrowth

Do not keep the default value which is 1 MB. We can illustrate with a simple example why this is a bad idea.

When a document of 5 MB is uploaded, it means there are 5 Autogrowth which are activated. In fact, there are 5 allocations of space which must slow your system.

Moreover, your uploaded document will be fragmented across your different data files. This configuration will decrease your performance a second time.

To avoid performance issues and reduce fragmented data files, you should set the autogrowth value to a fixed number of megabytes.

My recommendation is 1024 MB for data files and 256 MB for log files. But keep in mind, this is a global recommendation. In fact, the bigger the database, the bigger the growth increment should be.

 

SQL Server disk cluster size

The default value of SQL Server is 4 KB. But in fact, it is nearly the worst value you can choose for this configuration!

Globally, 64 KB is a safe value. Indeed, the server reads 64 KB at the time and can deliver larger chunks of data to the SQL Server database.

 

TempDB Optimization

First, the TempDB recovery model should be set to simple. Indeed, this model automatically reclaims log space to keep space requirements small.

Also, you should put your TempDB on the fastest disks you have, because TempDB is heavily used by SharePoint. Do not let SQL Server use this disk for any other needs, except TempDB utilization!

Furthermore, each TempDB file should be 25% larger than the largest content database. Not many DBAs realize how a TempDB is used by SharePoint and to what extent a TempDB can grow!

 

Index Fragmentation

WSS_Content database, for example, is used to store site collection as well as lists and its tables are shared. Therefore, indexes are very important!

So do not forget to manage the fragmentation of your databases.

My recommendation is to perform a Reorganize when your fragmentation is between 10% and 30 % as well as a Rebuild index when your fragmentation is above 30%.

Take care about indexes with more than 1’000 pages!

 

Statistics

Do not enable Auto-Create Statistics on an SQL Server that supports SharePoint Server! Let SharePoint Server configure the required settings alone.

Auto-Create Statistics can significantly change the execution plan of a query from one instance of SQL Server to another.

Therefore, do not enable Auto-Update Statistics and use instead SharePoint Auto-Update capability instead.

 

SQL Server Memory Allocation

The default values of SQL Server for memory allocation are 0 MB for Minimum server memory and 2147483647 MB for Maximum server memory.

The default value of the Maximum server memory is not optimized at all!

You should set a custom value depending on the total amount of physical memory, the number of processors, and the number of cores.

To calculate your SQL Max Memory, I suggest you to read this article.

 

Recycle Bin

Be aware that items in the recycle Bin may affect the performance.

Moreover, after a certain limit of days or after a deletion, these items are moved to a second stage recycle bin that may also affect your performance.

As a result, you have to manage your recycle bin depending on your needs to ensure that the size of your recycle bin will not continue to grow out of control.

 

MAXDOP

The default value of your MAXDOP is 0. But for better performance, you should make sure that a single SQL Server process serves each request.

Therefore, you must set MAXDOP to 1.

 

Fill Factor

The default value is 0, which is equal to 100. It means that you do not provide space for index expansion.

But when a new row is added to a full index page, the Database Engine make a reorganization called Page Split.

Page Split can take time to perform, and can cause fragmentation increasing I/O operations.

 

I recommend to set a Fill Factor value of 70. It means that 30 % of each-level page will be left empty.

Therefore, you can support growth and reduce fragmentation.

 

Instant File initialization

This feature, when enabled, allows SQL Server to initialize database files instantly, without physically zeroing out each and every 8K page in the file.

Therefore, depending on the size of files you have, you can save a lots of time.

 

Conclusion

The default settings of the content database in SQL Server are pretty bad and far from what we really need. You should always opt for a pre-allocate size strategy and not rely on autogrowth.

Monitoring your databases for space and growth to avoid bad surprises is very important.

Also, do not forget to modify your model database for size allocation rules.

Ans if you do not want to suffer from bad performances, do not use the Auto-Shrink capability.

Rate this blog entry:
2

Nathan Courtine is Consultant at dbi services. He has more than four years of experience in Microsoft solutions. He is specialized in SQL Server installation, migration, performance analysis, best practices, etc. Moreover, he has a background in Oracle Java and .NET software and web development. Nathan Courtine is Microsoft Certified in Administering SQL Server 2012 Databases. Nathan Courtine holds an Engineer’s Degree in Computer Science from the ENSISA (Ecole Nationale Supérieure d'Ingénieurs Sud Alsace) in Mulhouse (F). His branch-related experience covers Public Sector, Automotive, IT, Financial Services / Banking, etc.

Comments

  • No comments made yet. Be the first to submit a comment

Leave your comment

Guest Thursday, 21 August 2014
AddThis Social Bookmark Button
Deutsch (DE-CH-AT)   French (Fr)

Contact

Contact us now!

Send us your request!

Our workshops

dbi FlexService SLA - ISO 20000 certified.

dbi FlexService SLA ISO 20000

Expert insight from insiders!

Fixed Price Services

dbi FlexService SLA - ISO 20000 certified.

dbi FlexService SLA ISO 20000

A safe investment: our IT services at fixed prices!

Your flexible SLA

dbi FlexService SLA - ISO 20000 certified.

dbi FlexService SLA ISO 20000

ISO 20000 certified & freely customizable!

dbi services Newsletter