Lars platzdasch SQL Server Best Practice - SQL PASS RG Thüringen 25.01.2018
SQL Server Configuration, SQL Server Maintenance , High Availability/Disaster Recovery( HA/DR)
3. ACHTUNG:
FALLS JEMAND ETWAS
NACH LESEN MÖCHTE
Hat du Kopp wie Sieb, muttu
auf schreiben ! ( oder … )
Slides sind auf http://www.slideshare.net/larspl ,
PASS Webseite , Scripte auf Github
https://github.com/larspl/SQL-PASS-RG-TH
4. AGENDA: SQL SERVER BEST PRACTICE
Windows Server
SQL Server Configuration
Maintenance
High Availability/Disaster Recovery( HA/DR)
5. SYSTEM KONFIGURATION: OS
System Settings:
«Best
performance»
Windows Server
performance options
Determine page file size
Use the proper power
plan
Create a SQL alias
Factor 1,5 des
RAMS
Sample: 8192 MB
RAM x 1,5 = 12288
MB page file
«High
performance»
instead of
«Balanced»
Create one for
content and
search on every
SP Server
(cliconfg.exe)
6. SQL SERVER BEST PRACTICE
Windows Server
SQL Server Configuration
Maintenance
High Availability/Disaster Recovery( HA/DR)
8. SQL SERVER KONFIGURATION
• SQL Server 2008
• SQL Server 2012
• SQL Server 2014
• SQL Server 2016
• SQL Server 2017
SSMS nicht auf dem
SQL Server installieren
Dedizierte Instance
SQL Service mit einem
Managed Account
Keine besonderen
Rechte
Named Instance
Sharepoint ?
12. SQL SERVER KONFIGURATION
Service Account ( SQL Server )
TraceFlag: -T1117 ( Gleichmässiger
AutoGrow auf allen Files ) < (SQL2014)
TraceFlag: -T1118
( Speicherzuordnung wird optimiert
{eight pages from the same extent })
( SQL 2014/2016)
Lock Pages in Memory
Privileg ( local Policy )
TraceFlags :
-T845 (STD zusätzlich)
13. SQL SERVER KONFIGURATION
Service Account ( SQL Server )
- Instant File Initialization
Recht: (SE_MANAGE_VOLUME_NAME )
Volume Maintenance Task. By default,
only Local Admins have the access to it.
Lock PageOpen Local
Security Policy> Local
Policies > User Rights
Management and go
to the Perform
14. SQL SERVER KONFIGURATION
Kein Simple Recovery
Mode , Ausnahme
ConfigDB / Ex AOAG
Disable Boost SQL
Server Priority Temp DB auf 10GB
und min 4 Files
verteilen,
Autogrowth 1GBT-Log Backup alle
15min bis max. 24h
Content DBs Pre-
Size
Index Maintennance: FRAG <=30% Reorganisation, > Rebuild
16. SQL WartungSHAREPOINT
SQL SERVER BASICS
Tgl. Full backup
15min LOG
Backup
Index Reorg:
Tipp:
Ola Hallengren
( Backup Solution
https://ola.hallengr
en.com/ )
DR Plan?
Kein
DR
Plan
60%
DR
Plan
40%
18. SHAREPOINT SQL SERVER BASICS: ALWAYS ON
Disaster Recovery SQL Server Solution
Potential
Data Loss
(RPO)
Potential
Recovery Time
(RTO)
Automatic
Failover
Readable
Secondaries
AlwaysOn Availability Group - synchronous-commit Zero Seconds Yes 0 - 2
AlwaysOn Availability Group - asynchronous-commit Seconds Minutes No 0 - 4
AlwaysOn Failover Cluster Instance NA Seconds
-to-minutes
Yes NA
Database Mirroring - High-safety (sync + witness) Zero Seconds Yes NA
Database Mirroring - High-performance (async) Seconds Minutes No NA
Log Shipping Minutes Minutes
-to-hours
No Not during
a restore
Backup, Copy, Restore Hours Hours
-to-days
No Not during
a restore
19.
20. Lars Platzdasch | SharePoint and SQL Server
VIELEN DANK FÜR EURE ZEIT
Q & A
21.
22. Resources
• Backup Solution https://ola.hallengren.com/
• SQL Server: Minimize Disk I/O
https://technet.microsoft.com/en-us/magazine/jj643251.aspx
• https://technet.microsoft.com/de-
de/library/ms181007(v=sql.105).aspx (max degree of
parallelism (Option))
• https://technet.microsoft.com/en-
gb/library/ms188603(v=sql.105).aspx (cost threshold for
parallelism Option)