Performance problems in SharePoint are most commonly caused by a poorly configured or ineffectively optimised SQL Server back end. In this fast-paced session, Chief Technical Architect and International speaker Knut Relbe-Moe will walk through his top 10 tips for ensuring your SQL back end is perfectly pert and performing well for SharePoint. Compiled from his experiences in designing, deploying and managing truly cloud-scale instances of SharePoint and SQL Server, this session is one not to miss if you want to squeeze the best out of your SharePoint power-plant.
2. Knut Relbe-Moe
My Experience:
SharePoint evangelist, mentor, speaker
Old developer, turned Architect / ITPro
Have worked with SharePoint since the 2003 version.
Worked with several clients upgrading their solution from 2007/2010 to 2013.
Works as a Lead Architect and advisor creating SharePoint Farm
architecture/infrastructure on many projects. With up to 25.000 users.
Worked with automating the installation and configuration of SharePoint.
Chief TechnicalArchitect
Knowledge Factory,Oslo, Norway
Office365 MVP
Migration Expert
Educator forGlasspaper
Nintex VirtualTechnicalEvangelist
Knut.Relbe-
moe@knowledgefa
ctory.no
http://www.sharepointblog.no@shareptkarm +47 982 24 609
3. MS SQL Server is like the brain of your
SharePoint environment
4. So if the brain works slow, everything
else will be slow….
5. • Follow the guidelines in this presentation
• Read and understand this whitepaper from Vlad Catrienscu
• Maximizing SQL 2012 Performance for SharePoint 2013 WhitePaper
• If you have to reinstall MS SQL server as a new instance with the
correct settings.
How to fix this
6.
7. • Physical SQL Server will always outperform a virtual SQL server with
the same specs, but what shall you choose.
• Pros :
• High availability because of the hypervisor, not because of clustering
• Easier to scale up & down
• Can be easier to recover at Disaster Recovery
• Cons:
• Very heavily loaded VMs have seen disk I/O issues
• Over allocation of a virtual host. If you have too much running on a host,
it's not just I/O that could be impacted.
• Harder to protect
Physical vs Virtual
8.
9. • You should invest in as fast disk as possible
• If you run on a Virtual Server, consider physical disks for the SQL
server
• SSD or SAN
• If you have physical SQL server you should use at least 6 Disks:
1. TempDB
2. TempDB Logs
3. SharePoint Databases
4. SharePoint Databases Logs
5. OS
6. SQL binaries and other application Installs
DISKS
10. • You have a farm where most of the content is only read and
downloaded
• Your users will be collaborating, uploading documents, content
Speed/Scenario Read Intensive Scenario (ex Public Website)
Fastest Tempdb data files and transaction logs
. Database data files
. Search databases, except for the Search administration database
Slowest Database transaction log files
DISKS
Speed/Scenario Write Intensive Scenario ( collaborative workspace)
Fastest Tempdb data files and transaction logs
. Database transaction log files
. Search databases, except for the Search administration database
Slowest Database data files
11.
12. • Your SQL Server needs to have enough RAM to function properly.
• If your SQL Server runs only SharePoint, here are the minimum
requirements
Small Farm
Deployment
(0-500GB of
Data)
Medium Farm
Deployment
(501-1TB of
data)
Large Farm
Deployment
(1-2TB of Data)
Very Large
Farm Deployment
(2-5 TB of Data)
Special
Cases
Ram Required 8GB 16GB 32 GB 64GB 64GB+
CPU 4 4 8 8 8
RAM & CPU
13.
14. • SQL server reads and writes 64k at a time
• So change your allocation size from the 4K default to 64K.
• This small change alone, will improve your SQL performance by up
to 30%
NTFS Allocation size
15.
16. Server Configuration – Collation
• SharePoint server 2013 is built to use Latin1_General_CI_AS_KS_WS.
This is a quote from Microsoft to prove it:
• “We support any CI collation for the SQL instance (for master, tempdb
databases). However we recommend using
Latin1_General_CI_AS_KS_WS as the instance default collation
(master, tempdb databases).”
• CI – (Case Insensitive) A and a ARE treated as the same character.
• AS – (Accent Sensitive) a and á are NOT treated as the same character.
• KS – (Kana Sensitive) Japanese Hirakana and Katakana characters which look
the same are NOT treated as the same character.
• WS – (Width Sensitive) Single-Byte and Double-Byte versions of the same
character are NOT treated as the same character.
17.
18. Max Memory
SQL Server (and other database systems such as
Oracle and Sybase) need to read data pages into their
internal memory before they can be used. Of course
your server needs memory to operate as well. When
your database engine and your server are competing
for the same memory resources, you get bad
performance. You want your server and your database
engine to be like dancing partners, and less like my
kids fighting over the last cupcake.
Thomas Larock from SQL Rockstar explains this:
19.
20. Optimize TempdB
• Split across n locations
• N = total number of physical cores > super myth
• 25% of largest content dB
• The fastest disk possible
21.
22. Default fill factor to 80
“SharePoint, a server wide setting of 80 is optimal to support
growth and minimize fragmentation.”
23.
24. Model Database
• SQL Server uses the Model database as a template for creating new
user databases
• So therefor make sure that Model database have correct initial size
and growth settings.
• The log should be around 25% of the initial size.
• The auto growth is your insurance policy if your current database size has
been reached.
27. Auto Create Statistics
• Do not enable auto-create statistics on a server that hosts SQL Server
and SharePoint Server
• Enabling auto-create statistics is not supported for SharePoint Server
28.
29. USE “DBA” created databases
• Sizing
• Autogrowth
• DO NOT USE SIMPLE RECOVERY
• Unless you understand the implications
30.
31. Maintenance Plan
• Create a maintenance plan to backup databases, rebuild indexes and
checking the logical and physical integrity of your database
• Make sure you don’t run backup when heavy timer jobs runs in the
SharePoint environment, like midnight
32.
33. Script your SQL Server installation
• https://sqlserverfinebuild.codeplex.com/
37. 10 simple tips to maximize
performance
http://www.sharepointblog.no/?p=85
1. SSD Disk or better
2. Formating disk with 64K
3. Language corralation Latin_CI_AS_KS_WS
4. Maximum memory
5. Changed Sizes on Model database
6. Default fill factor to 80
7. Switched of autocreate statistics
8. Max Degree of Parallelism – set to 1 (it has to be)
9. Changed Initial Size & Autogrow on temp database, and created extra temp files for the
amount of processors.
10. Don’t do backups at midnight.
Maximizing SQL 2012 Performance for SharePoint 2013 WhitePaper by Vlad Catrinescu