bill baer is a senior product marketing manager and microsoft certified master for sharepoint in the...

52
Tuning SQL Server 2012 for SharePoint 2013 Jump Start Bill Baer | Senior Product Marketing Manager, Microsoft Brian Alderman | Chief Executive Officer | MicroTechPoint

Upload: annabel-lamb

Post on 26-Dec-2015

216 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

Tuning SQL Server 2012 for SharePoint 2013 Jump StartBill Baer | Senior Product Marketing Manager, MicrosoftBrian Alderman | Chief Executive Officer | MicroTechPoint

Page 2: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

Introduction

Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington; having previously worked at Hewlett-Packard Bill Baer has a proven background in infrastructure engineering and enterprise deployments of SharePoint Products and Technologies. While at Hewlett-Packard Bill Baer was awarded the MVP award for his contributions in the Technology Solutions Group, now known as HP Enterprise Business, which encompasses server and storage hardware, technology consulting, and software sales.

Twitter @williambaer

LinkedIn /billbaer

TechNet /b/wbaer

Bill Baer (ˈbɛər)Senior Product Marketing Manager

SharePoint Microsoft Corporation

Page 3: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

Introduction

Brian has been focused on helping IT Pros and DBAs better understand core Microsoft technologies for over 25 years. As an industry-recognized consultant, author and conference speaker, Brian’s expertise and designs range across Microsoft operating systems, Active Directory, SQL Server, and SharePoint. A frequent presenter at SharePoint Conferences around the world, he has authored or contributed to several SharePoint and other technical books, and is a MCSE, MCT, MCDBA, and MCITP. Brian has a BS and MS in Computer Information Systems where he graduated summa cum laude from Regis University of Colorado Springs and lives in Scottsdale, AZ where he enjoys playing golf year round and traveling around the world.

Twitter @brianalderman

LinkedIn /brianalderman

Blog http://brianalderman.wordpress.com

Brian AldermanChief Executive Officer

Founder of MicroTechPoint

Page 4: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

Course TopicsTuning SQL Server 2012 for SharePoint 2013 Jump Start01 | Key SQL Server and SharePoint Server Integration Concepts (50

minutes) Dedicated Server or Instance; SQL Database & database files; ldf to mdf checkpoint process; Recovery

model (Simple vs. Full)

02 | Best Practices: SQL Server Database Settings (50 minutes)Model Database; TempDB (Location); Initial size, Autogrowth, and Collation; Recovery model

03 | Server Settings for SQL Server (50 minutes)Default Database File Locations; Memory Settings; MAXDOP

04 | SQL Server and SharePoint Availability (50 minutes)Avoiding large log files; Backups and Location of Backups; SQL Server 2012 AlwaysOn; Best Practices

Page 5: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

Setting Expectations

• Experienced SharePoint Administrators and/or SQL Server Database Administrators−Professional SharePoint experience; working knowledge of SQL

Server

• Suggested Prerequisites/Supporting Material−Hands-on experience with a Microsoft Learning Partner

recommended−Querying Microsoft SQL Server 2012 (course 10774)−Administering Microsoft SQL Server 2012 Databases (course 10775)

Page 6: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

Join the MVA Community!

• Microsoft Virtual Academy (MVA)−Free Online Learning Tailored for IT Pros and Developers −Over 1M Registered Users−Up-to-date, Relevant Training on Several Microsoft Products

Page 7: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

Course TopicsTuning SQL Server 2012 for SharePoint 2013 Jump Start01 | Key SQL Server and SharePoint Server Integration Concepts (50

minutes) Dedicated Server or Instance; SQL Database & database files; ldf to mdf checkpoint process; Recovery

model (Simple vs. Full)

02 | Best Practices: SQL Server Database Settings (50 minutes)Model Database; TempDB (Location); Initial size, Autogrowth, and Collation; Recovery model

03 | Server Settings for SQL Server (50 minutes)Default Database File Locations; Memory Settings; MAXDOP

04 | SQL Server and SharePoint Availability (50 minutes)Avoiding large log files; Backups and Location of Backups; SQL Server 2012 AlwaysOn; Best Practices

Page 8: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

Module Agenda

• SQL Server Deployment Options & Database Types

• Understand SQL Server and SharePoint Integration

• Schema Overview, Database Structure, Schema Restrictions

• SharePoint Database Descriptions−Farm Configuration and Central Administration−Content Databases−Service Application Databases

Page 9: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

SQL Server Deployment Options & Database Types

Page 10: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

Deployment

• Multiple Instances of SQL Server on One Physical Server

• One Default Instance and Multiple Named Instances

• Create SQL Server Alias for SharePoint SQL Server Instance

• Each Instance is Managed Individually−Share SQL Server Management Tools

• Each Instance Shares Server Resources (RAM, CPU)

Page 11: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

SQL Server Database Types

• System Databases:−Master – Configuration database of SQL Server−Msdb – SQL Server automation−Tempdb – Temporary storage area−Model – Template for all new databases

• User Databases:−All Web app databases−All Service app databases−All other non-system databases

Page 12: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

Understand SQL Server and SharePoint Integration

Page 13: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

SQL Server and SharePoint Integration• 93.8% of SharePoint content stored in SQL

Server• Farm Configuration information stored in

configuration db• Central Administration content stored in own

content db• Most Service Applications have at least one

content db• All Web Apps have at least one content db• During SQL Server installation, Set Default

Collation Setting to Latin1_General_CI_AS_KS_WS

Page 14: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

SQL Server and SharePoint Integration• Farm has several databases; >20 if spousal

installation• Site Collections only reside in one database• Content database contains multiple site

collections (2,000 Default Setting)• If Site Collection > 100GB store in own content

database−Soft limit maximum size <= 200 GB

• Use SharePoint to control size of content database

Quota Templates Maximum Number of Site Collections

Page 15: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

DEMOSQL Server Management Studio

Page 16: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

Schema Overview, Database Structure, Schema Restrictions

Page 17: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

Database Structure

Database

Data File.MDF (1).NDF (0-

n)

Log File.LDF (1-n)

Latin1_General_CI_AS_KS_WS

Page 18: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

Content Database Basic TablesName Description

Features Table that holds information about all the activated features for each site collection or site.

Sites Table that holds information about all the site collections for this content database.

Webs Table that holds information about all the specific sites (webs) in each site collection.

UserInfo Table that holds information about all the users for each site collection.

Groups Table that holds information about all the SharePoint groups in each site collection.

Roles Table that holds information about all the SharePoint roles (permission levels) for each site.

All Lists Table that holds information about lists for each site.

GroupMembership Table that holds information about all the SharePoint group members.

AllUserData Table that holds information about all the list items for each list.

AllDocs Table that holds information about all the documents (and all list items) for each document library and list.

RoleAssignment Table that holds information about all the users or SharePoint groups assigned to roles.

Sched Subscriptions

Table that holds information about all the scheduled subscriptions (alerts) for each user.

ImmedSubscriptions

Table that holds information about all the immediate subscriptions (alerts) for each user.

Page 19: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

Pages

• Fundamental Unit of Data Storage in SQL Server• 8 KB of Data Which Can be Index or Data

Related, Large Object Binary (LOB’s, e.g. BLOB) etc...

Page 20: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

Pages cont...

Page

Page Header

Data Row 1

Data Row 2

Data Row 3

123

Data rows are inserted serially immediately following the header.

A row offset table starts at the end of the page, and each row offset table contains one entry for each row on the page.

Page 21: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

Extents

• Group of Eight (8) Consecutive Pages• Aligned on (8) Eight Page Boundaries or 64KB

Page 22: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

Schema Implications (Perceptions)• SharePoint Tables Too Wide, Wraps Rows• SharePoint Manages Own (NVP) Indexes• SharePoint Adds Force-Order, Query Hints• Missing Indexes for Common Operations• Excessive Use of Dynamic Queries• No SQL Referential Integrity OR Key Constraints• DBCC with Data Loss Not Supported• Missing Integration of Back-up/Restore

Page 23: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

Supportability Constraints on Schema Modifications• Some Examples of Such Database Changes

Include: −Adding Database Triggers−Adding Indexes or Modifying Existing Indexes Within Tables −Adding, Modifying, or Deleting Primary or Foreign Key Relationships −Modifying or Deleting Existing Stored Procedures −Adding New Stored Procedures −Making Modification to Database Schema −Adding Tables to a Database of Products Listed in the "Applies to"

Section −Changing the Database Collation

• More Information: http://support.microsoft.com/kb/841057

Page 24: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

Understanding Support Policies and Imposed Limitations• Single Data Platform

−Web Content Management (WCM): Predominantly READ / Structured Queries and Search

−Enterprise Content Management (ECM): 80/20 READ/WRITE Distribution / Ad-hoc Queries

• Upgrade and Patch Management Requires Consistency and Integrity

• Application Logic Expectations on Schema• Enforced Integrity and Constraints

Page 25: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

SharePoint Database Descriptions

Page 26: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

Database Descriptions

• 23 Unique Databases Created in a Complete SharePoint Server 2013 Installation

• Distributed Light > Heavy IO and Scale Up/Out Options

Page 27: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

Configuration Database

• Single Database: Stores Farm Configuration Data, Solutions, and Farm Specific Settings

Default Name SharePoint_Config

Capacity Planning Scale Up / 0-5GB

IO Pattern Read (90/10)

Page 28: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

Central Administration Content

• Content Database for Central Administration

Default Name SharePoint_AdminContent_<GUID>

Capacity Planning Scale Up / 0-2GB

IO Pattern Read (90/10)

Page 29: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

Content Databases

• Stores all Site Content, Documents, Files, and Data

Default Name WSS_Content

Capacity Planning Scale Up, Scale Out / 0-16TB

IO Pattern Read/Write (80/20)

Page 30: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

UPA: Profile Database

• Stores and Manages Users and Social Information

Default Name User Profile Service Application_ProfileDB_<GUID>

Capacity Planning Scale Up, Scale Out / 0-100GB

IO Pattern Read/Write (90/10)

Page 31: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

UPA: Synchronization Database

• Stores Configuration and Staging Data Used During Profile Synchronization

Default Name User Profile Service Application_SyncDB_<GUID>

Capacity Planning Scale Up, Scale Out / 0-100GB

IO Pattern Read/Write (50/50)

Page 32: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

UPA: Social Tagging Database

• Stores Social Tags, Notes, and Ratings

Default Name User Profile Service Application_SocialDB_<GUID>

Capacity Planning Scale Up, Scale Out / 0-100GB

IO Pattern Read (80/20)

Page 33: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

Search: Administration Database

• Stores Search Application Configuration and ACL for Crawl Component

Default Name Search_Service_Application_DB_<GUID>

Capacity Planning Scale Up, Scale Out / 0-10GB

IO Pattern Read (80/20)

Page 34: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

Search: Analytics Reporting Database• Stores Results for Usage Analysis Reports

Default Name Search_Service_Application_AnalyticsReportingStoreDB_<GUID>

Capacity Planning Scale Out / 0-200GB

IO Pattern Write (90/10)

Page 35: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

Search: Crawl Database

• Stores State of Crawled Data and Crawl History

Default Name Search_Service_Application_CrawlStoreDB_<GUID>

Capacity Planning Scale Out / 0-200GB

IO Pattern Read (90/10)

Page 36: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

Search: Link Database

• Stores Information Extracted by Content Processing and Click-Through Information

Default Name Search_Service_Application_LinkStoreDB_<GUID>

Capacity Planning Scale Out / 0-200GB

IO Pattern Write (90/10)

Page 37: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

Summary

• SharePoint Deployment Should Have Dedicated Instance of SQL Server

• Unique SharePoint Database Schema Does Not Support Modification

• Several Databases Created for Web Apps and Service Apps with Different IO Impact

Page 38: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

©2013 Microsoft Corporation. All rights reserved. Microsoft, Windows, Office, Azure, System Center, Dynamics and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

Page 39: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

Appendix A

SharePoint Foundation 2013 and SharePoint Server 2013 Database Descriptions

Page 40: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

Apps: App Management Database• Stores App Licenses and Permissions

Default Name App_Management_<GUID>

Capacity Planning Scale Out / 0-10GB

IO Pattern Read (80/20)

Page 41: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

Apps: Apps for SharePoint Database• Stores Information About Apps for SharePoint

and Access Apps

Default Name Apps_<GUID>

Capacity Planning Scale Up / 0-10GB

IO Pattern Read (80/20)

Page 42: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

Secure Store Service Database

• Stores App Licenses and Permissions

Default Name Secure_Store_Service_DB_<GUID>

Capacity Planning Scale Up / 0-10GB

IO Pattern Read (80/20)

Page 43: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

Usage Database

• Stores Health Monitoring and Usage Data

Default Name WSS_Logging

Capacity Planning Scale Up / 0-500GB

IO Pattern Write (80/20)

Page 44: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

Subscription Settings Service Database• Stores Features and Settings for Hosted

Customers

Default Name SettingsServiceDB

Capacity Planning Scale Up / 0-50GB

IO Pattern Read (90/10)

Page 45: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

Business Data Connectivity Database• Stores External Content Types and Objects

Default Name Bdc_Service_DB_<GUID>

Capacity Planning Scale Up / 0-10GB

IO Pattern Read (90/10)

Page 46: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

Project Server 2013 Database

• Stores Data for Project Web App Sites

Default Name ProjectWebApp

Capacity Planning Scale Up / 0-100GB

IO Pattern Read (80/20)

Page 47: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

PowerPivot Service Database

• Stores Data Refresh Schedules and PowerPivot Usage Data

Default Name DefaultPowerPivotServiceApplicationDB_<GUID>

Capacity Planning Scale Up / 0-100GB

IO Pattern Read (80/20)

Page 48: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

PerformancePoint Services Database• Stores Temporary Objects and Persisted User

Comments and Settings

Default Name PerformancePoint Service _<GUID>

Capacity Planning Scale Up / 0-100GB

IO Pattern Read (80/20)

Page 49: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

State Service Database

• Stores Temporary State Information for InfoPath Forms Services, Exchange, Visio Services, and Chart Web Part

Default Name SessionStateService_<GUID>

Capacity Planning Scale Out / 0-100GB

IO Pattern Read (80/20)

Page 50: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

Word Automation Services Database• Stores Information About Pending and

Completed Document Conversions and Updates

Default Name WordAutomationServices_<GUID>

Capacity Planning Scale Up / 0-10GB

IO Pattern Read/Write (50/50)

Page 51: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

MMS: Managed Metadata Database• Stores Managed Metadata and Syndicated

Content Types

Default Name Managed Metadata Service Application_Metadata_<GUID>

Capacity Planning Scale Out / 0-100GB

IO Pattern Read (80/20)

Page 52: Bill Baer is a Senior Product Marketing Manager and Microsoft Certified Master for SharePoint in the SharePoint product group in Redmond, Washington;

MMS: Taxonomy Database

• Stores Hierarchical Structure of Terms Used for Tagging Content and Building Site Collections

Default Name Managed Metadata Service_<GUID>

Capacity Planning Scale Up / 0-10GB

IO Pattern Read (80/20)