SlideShare a Scribd company logo
June 20th, 2016
Getting SQL Spinning with SharePoint - Best
Practices for the Backend
Knut Relbe-Moe, Advania Knowledge Factory
 Office Server & Services MVP
 Nintex vTE (Virtual Technical Evangelist)
 SharePoint evangelist, mentor, speaker
 Migration Expert
 Educator for Glasspaper
 Microsoft Certified Trainer
 Chief Technical Architect with Advania
Knowledge Factory
 @sharePTkarm (Twitter)
Knut Relbe-Moe
knutrelbemoe@outlook.com
About me
BLOG
LINKED IN
TWITTER
EMAIL
MEMBER OF
MEMBER OF
WORKS FOR
JOB TITLE
Microsoft MVP
Office Servers and Services
Chief Technical Architect
https://linkedin.com/in/shareptkarm
knutrelbemoe@outlook.com
http://sharepointblog.no
@shareptkarm
SharePoint Saturday Oslo
NIWUG
AWARDED
AWARDED
Nintex vTE
Nintex Virtual Technical Evangelist
Thanx to @atomicvee
THANK YOU TO THE TEAM BEHIND
MS SQL Server is like the brain of your SharePoint
environment
So if the brain works slow, everything else will be
slow….
99.9% of SharePoint content stored in SQL Server
 Farm Configuration information stored in configuration db
 Central Administration content stored in seperate content db
 Most Service Applications have at least one db
 All Web Applications have at least one content db
How to fix this
 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.
Agenda
 Foundamentals
 13 tips to get your SQL Spinning
 Summary
Unity Connect - Getting SQL Spinning with SharePoint - Best Practices for the Backend
SQL Server configuration
For SharePoint 2013:
• SQL Server 2008 R2 SP1
• SQL Server 2012 (SP1 for BI)
• SQL Server 2014 (SP2013 SP1 & April CU)
For SharePoint 2016:
• SQL Server 2014
• SQL Server 2016
Use a dedicated instance
Run the service with a Managed account
•No specific permission
Use named
instances
 SharePoint
Unity Connect - Getting SQL Spinning with SharePoint - Best Practices for the Backend
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
Unity Connect - Getting SQL Spinning with SharePoint - Best Practices for the Backend
DISKS
 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
• 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
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
Unity Connect - Getting SQL Spinning with SharePoint - Best Practices for the Backend
RAM & CPU
• 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
Deploymen
t
(0-500GB
of Data)
Medium
Farm
Deployme
nt (501-
1TB of
data)
Large Farm
Deploymen
t
(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
Unity Connect - Getting SQL Spinning with SharePoint - Best Practices for the Backend
DISKS
 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%
Use chkdsk
<drive>to Verify
Use Format to Configure:
• Format <drive> /Q /FS:NTFS /A:64K /V:<volume>
/Y
Unity Connect - Getting SQL Spinning with SharePoint - Best Practices for the Backend
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.
Server Configuration
For SharePoint 2013:
• SQL Server 2008 R2 SP1
• SQL Server 2012 (SP1 for BI)
• SQL Server 2014 (SP2013 SP1 & April CU)
For SharePoint 2016:
• SQL Server 2014
• SQL Server 2016
Use named
instances
 SharePoint
Use a dedicated
instance
Run the service
with a Managed
account
•No specific permission
Server Configuration
Use alias for the connection string
• Client alias or DNS alias (preferred)
Good practice : every SP Content db must be created (and documented) by a DBA
after a strict capacity plan
Server Configuration
Use alias for the connection string
• Client alias or DNS alias (preferred)
Good practice : every SP Content db must be created (and documented) by a DBA
after a strict capacity plan
Server Configuration
 Backups
 Compression
Unity Connect - Getting SQL Spinning with SharePoint - Best Practices for the Backend
Thomas Larock from SQL Rockstar explains this:
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.
Max Memory
Unity Connect - Getting SQL Spinning with SharePoint - Best Practices for the Backend
Optimize TempdB
 Split across n locations
 N = total number of physical cores > super myth
 All temp files need to have the same size
 Size of largest content dB or 10 % of Total Content DB’s Size whichever is bigger
 The fastest disk possible | Place on a different Drive than the Content Database
 Simple Recovery mode
 Place on Different Drive Than Content Databases
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.
Script
Unity Connect - Getting SQL Spinning with SharePoint - Best Practices for the Backend
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
Unity Connect - Getting SQL Spinning with SharePoint - Best Practices for the Backend
USE “DBA” created databases
 Sizing
 Autogrowth
 DO NOT USE SIMPLE RECOVERY
 Unless you understand the implications
Unity Connect - Getting SQL Spinning with SharePoint - Best Practices for the Backend
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
Recovery mode
Model db : recovery
model = full
Tempdb : recovery
model = simple
SharePoint DB :
recovery model ?
Contend DB = full Config DB= simple
Services App DBs= it
depends :
•http://technet.micro
soft.com/en-
us/library/cc678868.
aspx
Unity Connect - Getting SQL Spinning with SharePoint - Best Practices for the Backend
Script your SQL Server installation
 https://sqlserverfinebuild.codeplex.com/
Unity Connect - Getting SQL Spinning with SharePoint - Best Practices for the Backend
Always install SQL Alias in SharePoint
Use alias for the connection string
• Client alias or DNS alias (preferred)
C:WindowsSystem32cliconfg.exe
Unity Connect - Getting SQL Spinning with SharePoint - Best Practices for the Backend
Using SQL Server Resource Governor to optimize
Search Database usage
 Part of SQL Server Enterprise (since SQL 2008)
 Limits CPU and memory usage on some DBs (and IO in SQL
Server 2014)
 like search DBs
 Allow less CPU & mem & IO usage during work hours
 Allow more CPU & mem & IO usage during off hours
Unity Connect - Getting SQL Spinning with SharePoint - Best Practices for the Backend
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
STAY TUNED FOR MORE GREAT SESSIONS
http://unityconnect.com/online
Questions?
@shareptkarm
Office Server &
Services
Knut Relbe-Moe
Chief Technical Architect, Advania Knowledge Factory
knutrelbemoe@outlook.com
shareptkarm@outlook.com

More Related Content

PDF
Snowflake SnowPro Certification Exam Cheat Sheet
PPTX
SPSMadrid Get sql spinning with SharePoint. Best practice for the back end
PDF
Optimizing SQL Server 2012 for SharePoint 2013
PDF
Azure Boot Camp 21.04.2018 SQL Server in Azure Iaas PaaS on-prem Lars Platzdasch
PPTX
Tuning SQL Server for Sharepoint-Sharepoint Summit Toronto 2014
PDF
Tuning Sql Server for SharePoint--- Community Day Belgium 2013
PPTX
Tuning SQL Server for Sharepoint 2013- What every sharepoint consultant need...
PPTX
Introduction to SQL Server Internals: How to Think Like the Engine
Snowflake SnowPro Certification Exam Cheat Sheet
SPSMadrid Get sql spinning with SharePoint. Best practice for the back end
Optimizing SQL Server 2012 for SharePoint 2013
Azure Boot Camp 21.04.2018 SQL Server in Azure Iaas PaaS on-prem Lars Platzdasch
Tuning SQL Server for Sharepoint-Sharepoint Summit Toronto 2014
Tuning Sql Server for SharePoint--- Community Day Belgium 2013
Tuning SQL Server for Sharepoint 2013- What every sharepoint consultant need...
Introduction to SQL Server Internals: How to Think Like the Engine

What's hot (18)

PDF
Power BI with Essbase in the Oracle Cloud
PPTX
Hardware planning & sizing for sql server
PPT
Mehta - SharePoint Data And Database Management
PPTX
SQL Server 2016 New Features and Enhancements
PPTX
Diving into sql server 2016
PPTX
SQLIO - measuring storage performance
PPTX
SQL Server 2014 New Features (Sql Server 2014 Yenilikleri)
PDF
Amazon Aurora Let's Talk About Performance
PPTX
How SQL Server 2016 SP1 Changes the Game
PPTX
Amazon Aurora Getting started Guide -level 0
PPTX
Reduce latency and boost sql server io performance
PDF
Amazon (AWS) Aurora
PPTX
SQL Server It Just Runs Faster
PDF
SharePoint & SQL Server Working Together Efficiently
PPTX
Azure Databases with IaaS
PPTX
JSSUG: SQL Sever Performance Tuning
PPTX
How to Make SQL Server Go Faster
PPT
Sql And Storage Considerations For Share Point Server 2010
Power BI with Essbase in the Oracle Cloud
Hardware planning & sizing for sql server
Mehta - SharePoint Data And Database Management
SQL Server 2016 New Features and Enhancements
Diving into sql server 2016
SQLIO - measuring storage performance
SQL Server 2014 New Features (Sql Server 2014 Yenilikleri)
Amazon Aurora Let's Talk About Performance
How SQL Server 2016 SP1 Changes the Game
Amazon Aurora Getting started Guide -level 0
Reduce latency and boost sql server io performance
Amazon (AWS) Aurora
SQL Server It Just Runs Faster
SharePoint & SQL Server Working Together Efficiently
Azure Databases with IaaS
JSSUG: SQL Sever Performance Tuning
How to Make SQL Server Go Faster
Sql And Storage Considerations For Share Point Server 2010
Ad

Similar to Unity Connect - Getting SQL Spinning with SharePoint - Best Practices for the Backend (20)

PPTX
Get your SharePoint spinning with SQL Server
PPT
Large Scale SQL Considerations for SharePoint Deployments
PDF
Introduction to SharePoint for SQLserver DBAs
PPTX
Sql Health in a SharePoint environment
PDF
SQL Server and SharePoint - Best Practices presented by Steffen Krause, Micro...
PPTX
1. SQL Server forSharePoint geeksA gentle introductionThomas Vochten • Septem...
PPTX
SPS Kansas City: What SharePoint Admin need to know about SQL
PPTX
Sql Server Tuning for SharePoint : what every consultant must know (Office 36...
PPTX
What SQL DBA's need to know about SharePoint
PPTX
What SQL DBAs need to know about SharePoint-Indianapolis 2013
PPTX
Espc17 make your share point fly by tuning and optimising sql server
PPTX
Make your SharePoint fly by tuning and optimizing SQL Server
PPTX
What SQL DBAs need to know about SharePoint-Kansas City, Sept 2013
PPTX
What SharePoint Admins need to know about SQL-Cinncinati
PPTX
What SQL DBA's need to know about SharePoint-St. Louis 2013
PPTX
Optimize SQL server performance for SharePoint
PPTX
SharePoint Saturday St. Louis 2014: What SharePoint Admins need to know about...
PPTX
SharePoint Intelligence Real World Business Workflow With Share Point Designe...
PPTX
What SQL DBAs need to know about SharePoint
PPTX
NZSPC 2013 - Ultimate SharePoint Infrastructure Best Practices Session
Get your SharePoint spinning with SQL Server
Large Scale SQL Considerations for SharePoint Deployments
Introduction to SharePoint for SQLserver DBAs
Sql Health in a SharePoint environment
SQL Server and SharePoint - Best Practices presented by Steffen Krause, Micro...
1. SQL Server forSharePoint geeksA gentle introductionThomas Vochten • Septem...
SPS Kansas City: What SharePoint Admin need to know about SQL
Sql Server Tuning for SharePoint : what every consultant must know (Office 36...
What SQL DBA's need to know about SharePoint
What SQL DBAs need to know about SharePoint-Indianapolis 2013
Espc17 make your share point fly by tuning and optimising sql server
Make your SharePoint fly by tuning and optimizing SQL Server
What SQL DBAs need to know about SharePoint-Kansas City, Sept 2013
What SharePoint Admins need to know about SQL-Cinncinati
What SQL DBA's need to know about SharePoint-St. Louis 2013
Optimize SQL server performance for SharePoint
SharePoint Saturday St. Louis 2014: What SharePoint Admins need to know about...
SharePoint Intelligence Real World Business Workflow With Share Point Designe...
What SQL DBAs need to know about SharePoint
NZSPC 2013 - Ultimate SharePoint Infrastructure Best Practices Session
Ad

More from Knut Relbe-Moe [MVP, MCT] (20)

PPTX
Knut relbe moe - teams-tips
PPTX
How to build a Project Hub with Hubsites and Sitedesign and Sitescripts
PPTX
Mobility with Office 365 How to make use of it (different apps) in your organ...
PPTX
How to build a Project Hub with Hubsites and Sitedesign and Sitescripts
PPTX
How hubsites raise SharePoint Intranet potential
PPTX
How hubsites raise SharePoints intranet potential
PPTX
SPSNYC: How Hub Sites Raise SharePoint's Intranet Potential
PPTX
How to automate the SharePoint Provisioning
PPTX
Can you build a Intranet with Modern SharePoint
PPTX
Knut wf 203 get started with designer workflows
PPTX
SEF Unity Connect 2016 Office 365 Groups
PPTX
WF 101 - SharePoint Designer 2013 Workflows: An Introduction
PPTX
SPSToronto: SharePoint 2016 - Hybrid, right choice for you and your organizat...
PPTX
UnityConnect - Office 365 Groups Deep Dive With Planner
PPTX
SharePoint 2016 The Future is Hybrid, what you need to know about it
PPTX
Migrate from Lotus Notes to SharePoint 2013 or SharePoint Online - Tips, Tric...
PPTX
How to create a Windows app with Project Siena, SharePoint and Office 365
PPTX
ESPC15 Power BI - The New Way to Quickly Build Powerful Dashboards (Level 300)
PPTX
ESPC15 Th30 Microsoft Office 365 Groups Deep Dive
PPTX
SharePoint Migrering unngå fallgruver
Knut relbe moe - teams-tips
How to build a Project Hub with Hubsites and Sitedesign and Sitescripts
Mobility with Office 365 How to make use of it (different apps) in your organ...
How to build a Project Hub with Hubsites and Sitedesign and Sitescripts
How hubsites raise SharePoint Intranet potential
How hubsites raise SharePoints intranet potential
SPSNYC: How Hub Sites Raise SharePoint's Intranet Potential
How to automate the SharePoint Provisioning
Can you build a Intranet with Modern SharePoint
Knut wf 203 get started with designer workflows
SEF Unity Connect 2016 Office 365 Groups
WF 101 - SharePoint Designer 2013 Workflows: An Introduction
SPSToronto: SharePoint 2016 - Hybrid, right choice for you and your organizat...
UnityConnect - Office 365 Groups Deep Dive With Planner
SharePoint 2016 The Future is Hybrid, what you need to know about it
Migrate from Lotus Notes to SharePoint 2013 or SharePoint Online - Tips, Tric...
How to create a Windows app with Project Siena, SharePoint and Office 365
ESPC15 Power BI - The New Way to Quickly Build Powerful Dashboards (Level 300)
ESPC15 Th30 Microsoft Office 365 Groups Deep Dive
SharePoint Migrering unngå fallgruver

Recently uploaded (20)

PDF
Instagram's Product Secrets Unveiled with this PPT
PPTX
Relationship Management Presentation In Banking.pptx
PPTX
Tablets And Capsule Preformulation Of Paracetamol
PDF
oil_refinery_presentation_v1 sllfmfls.pdf
DOCX
"Project Management: Ultimate Guide to Tools, Techniques, and Strategies (2025)"
PPTX
Presentation for DGJV QMS (PQP)_12.03.2025.pptx
PPTX
Effective_Handling_Information_Presentation.pptx
PPTX
2025-08-10 Joseph 02 (shared slides).pptx
PDF
Parts of Speech Prepositions Presentation in Colorful Cute Style_20250724_230...
PPTX
INTERNATIONAL LABOUR ORAGNISATION PPT ON SOCIAL SCIENCE
PPTX
The spiral of silence is a theory in communication and political science that...
PPTX
Learning-Plan-5-Policies-and-Practices.pptx
PPTX
Self management and self evaluation presentation
PPTX
Human Mind & its character Characteristics
PPTX
worship songs, in any order, compilation
PPTX
nose tajweed for the arabic alphabets for the responsive
PPTX
Impressionism_PostImpressionism_Presentation.pptx
PPTX
Tour Presentation Educational Activity.pptx
PDF
Nykaa-Strategy-Case-Fixing-Retention-UX-and-D2C-Engagement (1).pdf
PPTX
The Effect of Human Resource Management Practice on Organizational Performanc...
Instagram's Product Secrets Unveiled with this PPT
Relationship Management Presentation In Banking.pptx
Tablets And Capsule Preformulation Of Paracetamol
oil_refinery_presentation_v1 sllfmfls.pdf
"Project Management: Ultimate Guide to Tools, Techniques, and Strategies (2025)"
Presentation for DGJV QMS (PQP)_12.03.2025.pptx
Effective_Handling_Information_Presentation.pptx
2025-08-10 Joseph 02 (shared slides).pptx
Parts of Speech Prepositions Presentation in Colorful Cute Style_20250724_230...
INTERNATIONAL LABOUR ORAGNISATION PPT ON SOCIAL SCIENCE
The spiral of silence is a theory in communication and political science that...
Learning-Plan-5-Policies-and-Practices.pptx
Self management and self evaluation presentation
Human Mind & its character Characteristics
worship songs, in any order, compilation
nose tajweed for the arabic alphabets for the responsive
Impressionism_PostImpressionism_Presentation.pptx
Tour Presentation Educational Activity.pptx
Nykaa-Strategy-Case-Fixing-Retention-UX-and-D2C-Engagement (1).pdf
The Effect of Human Resource Management Practice on Organizational Performanc...

Unity Connect - Getting SQL Spinning with SharePoint - Best Practices for the Backend

  • 1. June 20th, 2016 Getting SQL Spinning with SharePoint - Best Practices for the Backend Knut Relbe-Moe, Advania Knowledge Factory
  • 2.  Office Server & Services MVP  Nintex vTE (Virtual Technical Evangelist)  SharePoint evangelist, mentor, speaker  Migration Expert  Educator for Glasspaper  Microsoft Certified Trainer  Chief Technical Architect with Advania Knowledge Factory  @sharePTkarm (Twitter) Knut Relbe-Moe knutrelbemoe@outlook.com
  • 3. About me BLOG LINKED IN TWITTER EMAIL MEMBER OF MEMBER OF WORKS FOR JOB TITLE Microsoft MVP Office Servers and Services Chief Technical Architect https://linkedin.com/in/shareptkarm knutrelbemoe@outlook.com http://sharepointblog.no @shareptkarm SharePoint Saturday Oslo NIWUG AWARDED AWARDED Nintex vTE Nintex Virtual Technical Evangelist Thanx to @atomicvee
  • 4. THANK YOU TO THE TEAM BEHIND
  • 5. MS SQL Server is like the brain of your SharePoint environment
  • 6. So if the brain works slow, everything else will be slow….
  • 7. 99.9% of SharePoint content stored in SQL Server  Farm Configuration information stored in configuration db  Central Administration content stored in seperate content db  Most Service Applications have at least one db  All Web Applications have at least one content db
  • 8. How to fix this  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.
  • 9. Agenda  Foundamentals  13 tips to get your SQL Spinning  Summary
  • 11. SQL Server configuration For SharePoint 2013: • SQL Server 2008 R2 SP1 • SQL Server 2012 (SP1 for BI) • SQL Server 2014 (SP2013 SP1 & April CU) For SharePoint 2016: • SQL Server 2014 • SQL Server 2016 Use a dedicated instance Run the service with a Managed account •No specific permission Use named instances SharePoint
  • 13. 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
  • 15. DISKS  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
  • 16. DISKS • 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 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
  • 18. RAM & CPU • 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 Deploymen t (0-500GB of Data) Medium Farm Deployme nt (501- 1TB of data) Large Farm Deploymen t (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
  • 20. DISKS  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% Use chkdsk <drive>to Verify Use Format to Configure: • Format <drive> /Q /FS:NTFS /A:64K /V:<volume> /Y
  • 22. 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.
  • 23. Server Configuration For SharePoint 2013: • SQL Server 2008 R2 SP1 • SQL Server 2012 (SP1 for BI) • SQL Server 2014 (SP2013 SP1 & April CU) For SharePoint 2016: • SQL Server 2014 • SQL Server 2016 Use named instances SharePoint Use a dedicated instance Run the service with a Managed account •No specific permission
  • 24. Server Configuration Use alias for the connection string • Client alias or DNS alias (preferred) Good practice : every SP Content db must be created (and documented) by a DBA after a strict capacity plan
  • 25. Server Configuration Use alias for the connection string • Client alias or DNS alias (preferred) Good practice : every SP Content db must be created (and documented) by a DBA after a strict capacity plan
  • 28. Thomas Larock from SQL Rockstar explains this: 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. Max Memory
  • 30. Optimize TempdB  Split across n locations  N = total number of physical cores > super myth  All temp files need to have the same size  Size of largest content dB or 10 % of Total Content DB’s Size whichever is bigger  The fastest disk possible | Place on a different Drive than the Content Database  Simple Recovery mode  Place on Different Drive Than Content Databases
  • 31. 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.
  • 34. 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
  • 36. USE “DBA” created databases  Sizing  Autogrowth  DO NOT USE SIMPLE RECOVERY  Unless you understand the implications
  • 38. 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
  • 39. Recovery mode Model db : recovery model = full Tempdb : recovery model = simple SharePoint DB : recovery model ? Contend DB = full Config DB= simple Services App DBs= it depends : •http://technet.micro soft.com/en- us/library/cc678868. aspx
  • 41. Script your SQL Server installation  https://sqlserverfinebuild.codeplex.com/
  • 43. Always install SQL Alias in SharePoint Use alias for the connection string • Client alias or DNS alias (preferred) C:WindowsSystem32cliconfg.exe
  • 45. Using SQL Server Resource Governor to optimize Search Database usage  Part of SQL Server Enterprise (since SQL 2008)  Limits CPU and memory usage on some DBs (and IO in SQL Server 2014)  like search DBs  Allow less CPU & mem & IO usage during work hours  Allow more CPU & mem & IO usage during off hours
  • 47. 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
  • 48. STAY TUNED FOR MORE GREAT SESSIONS http://unityconnect.com/online
  • 50. Knut Relbe-Moe Chief Technical Architect, Advania Knowledge Factory knutrelbemoe@outlook.com shareptkarm@outlook.com