SlideShare ist ein Scribd-Unternehmen logo
1 von 35
Required Slide
Managing Microsoft SQL Server:For the “Reluctant” DBA Don Jones Senior Partner and Technologist Concentrated Technology, LLC Required Slide SESSION CODE: DAT203
This slide deck was used in one of our many conference presentations. We hope you enjoy it, and invite you to use it within your own organization however you like. For more information on our company, including information on private classes and upcoming conference appearances, please visit our Web site, www.ConcentratedTech.com.  For links to newly-posted decks, follow us on Twitter:@concentrateddon or @concentratdgreg This work is copyright ©Concentrated Technology, LLC
Introductions Me: Don Jones, Concentrated Technology Microsoft MVP Award recipient Contributing Editor, TechNet Magazine Author of 45+ IT books Blogger at http://ConcentratedTech.com You: The “Microsoft Person” in your environment Not primarily concerned with supporting Microsoft SQL Server… …but more or less forced to do so anyway
Agenda Peeking Under the Hood: How SQL Server Works Backup and Restore Operations About the Query Optimizer Index Maintenance and Tuning Key Database Configuration Options SQL Server Security Model Key Server Configuration Options High Availability and Replication Options
How SQL Server Works, Part 1 SQL Server stores data in 8KB chunks called “pages” It always deals with data in these 8KB chunks Generally speaking, all data for a single table row must fit onto a single page It’s actually possible for certain types of data to spread across multiple pages Sometimes, the page can contain a pointer to a file on disk – the FILESTREAM data type The pages live in one or more files (.MDF, .NDF) on disk, but are always read or written in 8KB units
How SQL Server Works, Part 2 When a query is issued that results in data being changed, added, or deleted: SQL Server makes a note of the query in its transaction log The database engine determines what page(s) are affected by the change The affected pages are loaded into server memory The changes are made in memory ,[object Object]
If something else reads those pages, they’re already handy in memory.,[object Object]
SQL Server Backups Three types: Full – Backs up the entire database and removes (“truncates”) all “checked” entries from the transaction log Differential: Only what’s changed since the last Full; also truncates the log Transaction log: Only grabs the current transaction log; truncates the active log afterward
Restoring a Database Start with the most recent Full backup ,[object Object],Apply the most recent differential ,[object Object],Apply any transaction logs since the differential was made ,[object Object]
Maximum amount of data at-risk: Any changes made since the most recent transaction log backup
Moral: Frequent T-Log backups!,[object Object]
Indexes Two types: Clustered Every table has one, even if it’s just on the row ID number. Governs the order in which data is logically stored Should be on whatever column is used most for lookups or table joins Non-Clustered Every table can have zero or more Acts as a literal index, keeping entries in order by the indexed column and pointing to the full data row A “covering” index is one that contains entries for every column being queried
Indexes: Pros and Cons Pros Indexes can speed up the time it takes to find data Also speed up sort times Ideally, index on all columns that are frequently used in a WHERE or ORDER BY clause Cons Indexes slow down data add/change/delete operations, because indexes must also be updated Ideally, index nothing The reality is a balancing act: Building indexes on columns that deliver the most benefit, with the least downside
Index Problem: Fragmentation Occurs when index pages become full and data needs to be inserted into the middle A “page split” occurs to make room for the new entry, causing the pages to be “out of order” – this decreases performance NEW! Andrew Andrews Batista Barbara Charles Charlie Frank Gary Grossman Hugh Ina Jack Jackson Jones Kimberly Donavan Eric Erin Derek
Fixing Fragementation Reorganizing or Rebuilding the index will put the entries and pages back into the correct order, improving performance You can specify a “fill factor” that leaves empty space for new entries without splitting pages as often However, emptier pages mean SQL Server has to work harder to read the same amount of data – so this is a balancing act
Rebuilding and Reorganizing Indexes DEMO
Index Tuning The indexes that made sense for a database on day 1 might not make sense after it has been in use for some time You can use SQL Profiler to capture real-world, representative query traffic… …and feed that to the Database Engine Tuning Advisor to get recommendations on index improvements The Advisor can even help you implement those changes that you decide to proceed with
Using the Database Engine Tuning Wizard DEMO
Key Database Options and Best Practices Allow statistics to Auto-Create/Update This makes sure the Query Optimizer knows which indexes exist and what kind of condition they are in Consider disabling auto-growth, or at least monitor it Auto-Grow can consume time; better to manually size the database files appropriately Disable Auto Close except on infrequently-used databases Closed databases incur a performance hit when someone queries them since SQL Server has to open the file
Configuring Key Database Options DEMO
SQL Server Security Model Login: Map to a Windows user/group, or an in-server credential; gets you access to the server Server Role: Contains logins, and defines server-wide privileges Database user: Maps to a login, and gets you into a database Database Role: Contains database users, and defines in-database privileges Custom Database Role: Same as the built-in ones, but you define the permissions App Role: Shortcut login+databaseuser+permissions designed to be activated by an application that defines its own security layer for the data.
Server Options Authentication Mode: “Windows” or “Windows+SQL Server” Memory and Processor options (typically, leave alone) Instances Each “instance” is an independent installation of SQL Server Has its own “server-wide” options (“instance-wide” is a better term) Default instance: Connect using server name Other instances: Connect using SERVERNSTANCE format Review list of services to see instances – each instance has its own SQL Server service
Configuring Key Server and Security Options DEMO
High Availability Options Log Shipping Database Mirroring Windows Clustering
Where to Set Up Database Mirroring DEMO
Replication Options Snapshot Transactional Transactional with Updating Subscribers Merge Off-Topic: Microsoft Sync Framework / Sync Services for ADO.NET
Final Thoughts SQL Server Agent (and Jobs, Operators, and Alerts) Multi-Server Admininstration
Agent, Jobs, and Multi-Server Administration DEMO
Conclusion A few basic admin skills can help you perform the most often-needed SQL Server tasks Keep in mind that the SQL Server Management Studio can connect to multiple servers for single-seat administration
Track Resources Required Slide  Track PMs will supply the content for this slide, which will be inserted during the final scrub.  Resource  1 Resource  2 Resource  3 Resource  4
Resources Required Slide Learning Sessions On-Demand & Community Microsoft Certification & Training Resources www.microsoft.com/teched www.microsoft.com/learning Resources for IT Professionals Resources for Developers http://microsoft.com/technet http://microsoft.com/msdn
Related Content Required Slide Speakers, please list the Breakout Sessions, Interactive Sessions, Labs and Demo Stations that are related to your session. Breakout Sessions (session codes and titles) Interactive Sessions (session codes and titles) Hands-on Labs (session codes and titles) Product Demo Stations (demo station title and location)
Required Slide Complete an evaluation on CommNet and enter to win!
© 2010 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista 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.

Weitere ähnliche Inhalte

Was ist angesagt?

Sql Server 2012 Installation..
Sql Server 2012 Installation..Sql Server 2012 Installation..
Sql Server 2012 Installation..Anand Kumar Rajana
 
Windows Server 2008 Active Directory Components
Windows Server 2008 Active Directory ComponentsWindows Server 2008 Active Directory Components
Windows Server 2008 Active Directory ComponentsTũi Wichets
 
Using MS-SQL Server with Visual DataFlex
Using MS-SQL Server with Visual DataFlexUsing MS-SQL Server with Visual DataFlex
Using MS-SQL Server with Visual DataFlexwebhostingguy
 
Informatica log files
Informatica log filesInformatica log files
Informatica log filesAmit Sharma
 
Windows server 2012_r2_evaluation_guide
Windows server 2012_r2_evaluation_guideWindows server 2012_r2_evaluation_guide
Windows server 2012_r2_evaluation_guideAndre Fortunato
 
Material modulo04 asf6501(6425-a_01)
Material   modulo04 asf6501(6425-a_01)Material   modulo04 asf6501(6425-a_01)
Material modulo04 asf6501(6425-a_01)JSantanderQ
 
Material modulo03 asf6501(6425-b_02)
Material   modulo03 asf6501(6425-b_02)Material   modulo03 asf6501(6425-b_02)
Material modulo03 asf6501(6425-b_02)JSantanderQ
 
Mastering informatica log files
Mastering informatica log filesMastering informatica log files
Mastering informatica log filesAmit Sharma
 
Material modulo01 asf6501(6419-a_01)
Material   modulo01 asf6501(6419-a_01)Material   modulo01 asf6501(6419-a_01)
Material modulo01 asf6501(6419-a_01)JSantanderQ
 
Essbase ASO and BSO tuning
Essbase ASO and BSO tuningEssbase ASO and BSO tuning
Essbase ASO and BSO tuningsodhiranga
 
Informatica Power Center - Workflow Manager
Informatica Power Center - Workflow ManagerInformatica Power Center - Workflow Manager
Informatica Power Center - Workflow ManagerZaranTech LLC
 
Informatica complex transformation i
Informatica complex transformation iInformatica complex transformation i
Informatica complex transformation iAmit Sharma
 
Windows server 2012 - installing active directory domain server
Windows server 2012 - installing active directory domain serverWindows server 2012 - installing active directory domain server
Windows server 2012 - installing active directory domain serverahmadbahaj
 
Style Intelligence Evaluation Documentation
Style Intelligence Evaluation DocumentationStyle Intelligence Evaluation Documentation
Style Intelligence Evaluation DocumentationArleneWatson
 
Xml transformation-doc
Xml transformation-docXml transformation-doc
Xml transformation-docAmit Sharma
 
Material modulo02 asf6501(6425-b_01)
Material   modulo02 asf6501(6425-b_01)Material   modulo02 asf6501(6425-b_01)
Material modulo02 asf6501(6425-b_01)JSantanderQ
 
Query Store and live Query Statistics
Query Store and live Query StatisticsQuery Store and live Query Statistics
Query Store and live Query StatisticsSolidQ
 

Was ist angesagt? (20)

Sql Server 2012 Installation..
Sql Server 2012 Installation..Sql Server 2012 Installation..
Sql Server 2012 Installation..
 
Windows Server 2008 Active Directory Components
Windows Server 2008 Active Directory ComponentsWindows Server 2008 Active Directory Components
Windows Server 2008 Active Directory Components
 
Using MS-SQL Server with Visual DataFlex
Using MS-SQL Server with Visual DataFlexUsing MS-SQL Server with Visual DataFlex
Using MS-SQL Server with Visual DataFlex
 
Informatica log files
Informatica log filesInformatica log files
Informatica log files
 
Windows server 2012_r2_evaluation_guide
Windows server 2012_r2_evaluation_guideWindows server 2012_r2_evaluation_guide
Windows server 2012_r2_evaluation_guide
 
Material modulo04 asf6501(6425-a_01)
Material   modulo04 asf6501(6425-a_01)Material   modulo04 asf6501(6425-a_01)
Material modulo04 asf6501(6425-a_01)
 
Material modulo03 asf6501(6425-b_02)
Material   modulo03 asf6501(6425-b_02)Material   modulo03 asf6501(6425-b_02)
Material modulo03 asf6501(6425-b_02)
 
Tableau powerpoint
Tableau powerpointTableau powerpoint
Tableau powerpoint
 
Mastering informatica log files
Mastering informatica log filesMastering informatica log files
Mastering informatica log files
 
Readme
ReadmeReadme
Readme
 
Material modulo01 asf6501(6419-a_01)
Material   modulo01 asf6501(6419-a_01)Material   modulo01 asf6501(6419-a_01)
Material modulo01 asf6501(6419-a_01)
 
Essbase ASO and BSO tuning
Essbase ASO and BSO tuningEssbase ASO and BSO tuning
Essbase ASO and BSO tuning
 
Informatica Power Center - Workflow Manager
Informatica Power Center - Workflow ManagerInformatica Power Center - Workflow Manager
Informatica Power Center - Workflow Manager
 
Informatica complex transformation i
Informatica complex transformation iInformatica complex transformation i
Informatica complex transformation i
 
Windows server 2012 - installing active directory domain server
Windows server 2012 - installing active directory domain serverWindows server 2012 - installing active directory domain server
Windows server 2012 - installing active directory domain server
 
Tableau powerpoint
Tableau powerpointTableau powerpoint
Tableau powerpoint
 
Style Intelligence Evaluation Documentation
Style Intelligence Evaluation DocumentationStyle Intelligence Evaluation Documentation
Style Intelligence Evaluation Documentation
 
Xml transformation-doc
Xml transformation-docXml transformation-doc
Xml transformation-doc
 
Material modulo02 asf6501(6425-b_01)
Material   modulo02 asf6501(6425-b_01)Material   modulo02 asf6501(6425-b_01)
Material modulo02 asf6501(6425-b_01)
 
Query Store and live Query Statistics
Query Store and live Query StatisticsQuery Store and live Query Statistics
Query Store and live Query Statistics
 

Andere mochten auch

PowerShell crashcourse for Sharepoint admins
PowerShell crashcourse for Sharepoint adminsPowerShell crashcourse for Sharepoint admins
PowerShell crashcourse for Sharepoint adminsConcentrated Technology
 
Free tools for rapidly deploying software
Free tools for rapidly deploying softwareFree tools for rapidly deploying software
Free tools for rapidly deploying softwareConcentrated Technology
 
PowerShell and the Future of Windows Automation
PowerShell and the Future of Windows AutomationPowerShell and the Future of Windows Automation
PowerShell and the Future of Windows AutomationConcentrated Technology
 
Free tools for win server administration
Free tools for win server administrationFree tools for win server administration
Free tools for win server administrationConcentrated Technology
 
Automating Active Directory mgmt in PowerShell
Automating Active Directory mgmt in PowerShellAutomating Active Directory mgmt in PowerShell
Automating Active Directory mgmt in PowerShellConcentrated Technology
 
Three cool cmdlets I wish PowerShell Had!
Three cool cmdlets I wish PowerShell Had!Three cool cmdlets I wish PowerShell Had!
Three cool cmdlets I wish PowerShell Had!Thomas Lee
 
VDI-in-a-Box: Microsoft Desktop Virtualization for Smaller Businesses and Uses
VDI-in-a-Box:  Microsoft Desktop Virtualization for Smaller Businesses and UsesVDI-in-a-Box:  Microsoft Desktop Virtualization for Smaller Businesses and Uses
VDI-in-a-Box: Microsoft Desktop Virtualization for Smaller Businesses and UsesConcentrated Technology
 
Ive got a powershell secret
Ive got a powershell secretIve got a powershell secret
Ive got a powershell secretChris Conte
 

Andere mochten auch (20)

No-script PowerShell v2
No-script PowerShell v2No-script PowerShell v2
No-script PowerShell v2
 
PowerShell crashcourse for Sharepoint admins
PowerShell crashcourse for Sharepoint adminsPowerShell crashcourse for Sharepoint admins
PowerShell crashcourse for Sharepoint admins
 
Free tools for rapidly deploying software
Free tools for rapidly deploying softwareFree tools for rapidly deploying software
Free tools for rapidly deploying software
 
Iis implementation
Iis implementationIis implementation
Iis implementation
 
Ha & drs gotcha's
Ha & drs gotcha'sHa & drs gotcha's
Ha & drs gotcha's
 
PowerShell crash course
PowerShell crash coursePowerShell crash course
PowerShell crash course
 
PowerShell and the Future of Windows Automation
PowerShell and the Future of Windows AutomationPowerShell and the Future of Windows Automation
PowerShell and the Future of Windows Automation
 
PS error handling and debugging
PS error handling and debuggingPS error handling and debugging
PS error handling and debugging
 
Server Core2
Server Core2Server Core2
Server Core2
 
Free tools for win server administration
Free tools for win server administrationFree tools for win server administration
Free tools for win server administration
 
Best free tools for w d a
Best free tools for w d aBest free tools for w d a
Best free tools for w d a
 
PowerShell 8tips
PowerShell 8tipsPowerShell 8tips
PowerShell 8tips
 
Meet Windows PowerShell
Meet Windows PowerShellMeet Windows PowerShell
Meet Windows PowerShell
 
Implementing dr w. hyper v clustering
Implementing dr w. hyper v clusteringImplementing dr w. hyper v clustering
Implementing dr w. hyper v clustering
 
Automating Active Directory mgmt in PowerShell
Automating Active Directory mgmt in PowerShellAutomating Active Directory mgmt in PowerShell
Automating Active Directory mgmt in PowerShell
 
PowerShell crashcourse
PowerShell crashcoursePowerShell crashcourse
PowerShell crashcourse
 
Three cool cmdlets I wish PowerShell Had!
Three cool cmdlets I wish PowerShell Had!Three cool cmdlets I wish PowerShell Had!
Three cool cmdlets I wish PowerShell Had!
 
From VB Script to PowerShell
From VB Script to PowerShellFrom VB Script to PowerShell
From VB Script to PowerShell
 
VDI-in-a-Box: Microsoft Desktop Virtualization for Smaller Businesses and Uses
VDI-in-a-Box:  Microsoft Desktop Virtualization for Smaller Businesses and UsesVDI-in-a-Box:  Microsoft Desktop Virtualization for Smaller Businesses and Uses
VDI-in-a-Box: Microsoft Desktop Virtualization for Smaller Businesses and Uses
 
Ive got a powershell secret
Ive got a powershell secretIve got a powershell secret
Ive got a powershell secret
 

Ähnlich wie Managing SQLserver for the reluctant DBA

DBA, LEVEL III TTLM Monitoring and Administering Database.docx
DBA, LEVEL III TTLM Monitoring and Administering Database.docxDBA, LEVEL III TTLM Monitoring and Administering Database.docx
DBA, LEVEL III TTLM Monitoring and Administering Database.docxseifusisay06
 
SQL Server and System Center Advisor
SQL Server and System Center AdvisorSQL Server and System Center Advisor
SQL Server and System Center AdvisorEduardo Castro
 
Sql server 2012 tutorials writing transact-sql statements
Sql server 2012 tutorials   writing transact-sql statementsSql server 2012 tutorials   writing transact-sql statements
Sql server 2012 tutorials writing transact-sql statementsSteve Xu
 
SQL Server - High availability
SQL Server - High availabilitySQL Server - High availability
SQL Server - High availabilityPeter Gfader
 
Novidades do SQL Server 2016
Novidades do SQL Server 2016Novidades do SQL Server 2016
Novidades do SQL Server 2016Marcos Freccia
 
Sql interview question part 8
Sql interview question part 8Sql interview question part 8
Sql interview question part 8kaashiv1
 
Sql interview question part 9
Sql interview question part 9Sql interview question part 9
Sql interview question part 9kaashiv1
 
Sql interview-question-part-9
Sql interview-question-part-9Sql interview-question-part-9
Sql interview-question-part-9kaashiv1
 
KoprowskiT_SQLSat409_MaintenancePlansForBeginners
KoprowskiT_SQLSat409_MaintenancePlansForBeginnersKoprowskiT_SQLSat409_MaintenancePlansForBeginners
KoprowskiT_SQLSat409_MaintenancePlansForBeginnersTobias Koprowski
 
KoprowskiT_SQLSaturday409_MaintenancePlansForBeginners
KoprowskiT_SQLSaturday409_MaintenancePlansForBeginnersKoprowskiT_SQLSaturday409_MaintenancePlansForBeginners
KoprowskiT_SQLSaturday409_MaintenancePlansForBeginnersTobias Koprowski
 
High Performance Mysql
High Performance MysqlHigh Performance Mysql
High Performance Mysqlliufabin 66688
 
High Availbilty In Sql Server
High Availbilty In Sql ServerHigh Availbilty In Sql Server
High Availbilty In Sql ServerRishikesh Tiwari
 
1 extreme performance - part i
1   extreme performance - part i1   extreme performance - part i
1 extreme performance - part isqlserver.co.il
 

Ähnlich wie Managing SQLserver for the reluctant DBA (20)

DBA, LEVEL III TTLM Monitoring and Administering Database.docx
DBA, LEVEL III TTLM Monitoring and Administering Database.docxDBA, LEVEL III TTLM Monitoring and Administering Database.docx
DBA, LEVEL III TTLM Monitoring and Administering Database.docx
 
SQL Server and System Center Advisor
SQL Server and System Center AdvisorSQL Server and System Center Advisor
SQL Server and System Center Advisor
 
Sql server 2012 tutorials writing transact-sql statements
Sql server 2012 tutorials   writing transact-sql statementsSql server 2012 tutorials   writing transact-sql statements
Sql server 2012 tutorials writing transact-sql statements
 
Supporting SQLserver
Supporting SQLserverSupporting SQLserver
Supporting SQLserver
 
12363 database certification
12363 database certification12363 database certification
12363 database certification
 
SQL Server - High availability
SQL Server - High availabilitySQL Server - High availability
SQL Server - High availability
 
Novidades do SQL Server 2016
Novidades do SQL Server 2016Novidades do SQL Server 2016
Novidades do SQL Server 2016
 
Sql interview question part 8
Sql interview question part 8Sql interview question part 8
Sql interview question part 8
 
Ebook8
Ebook8Ebook8
Ebook8
 
Ebook9
Ebook9Ebook9
Ebook9
 
Sql interview question part 9
Sql interview question part 9Sql interview question part 9
Sql interview question part 9
 
Ebook9
Ebook9Ebook9
Ebook9
 
Sql interview-question-part-9
Sql interview-question-part-9Sql interview-question-part-9
Sql interview-question-part-9
 
Intro to Application Express
Intro to Application ExpressIntro to Application Express
Intro to Application Express
 
KoprowskiT_SQLSat409_MaintenancePlansForBeginners
KoprowskiT_SQLSat409_MaintenancePlansForBeginnersKoprowskiT_SQLSat409_MaintenancePlansForBeginners
KoprowskiT_SQLSat409_MaintenancePlansForBeginners
 
KoprowskiT_SQLSaturday409_MaintenancePlansForBeginners
KoprowskiT_SQLSaturday409_MaintenancePlansForBeginnersKoprowskiT_SQLSaturday409_MaintenancePlansForBeginners
KoprowskiT_SQLSaturday409_MaintenancePlansForBeginners
 
High Performance Mysql
High Performance MysqlHigh Performance Mysql
High Performance Mysql
 
High Availbilty In Sql Server
High Availbilty In Sql ServerHigh Availbilty In Sql Server
High Availbilty In Sql Server
 
1 extreme performance - part i
1   extreme performance - part i1   extreme performance - part i
1 extreme performance - part i
 
Ebook5
Ebook5Ebook5
Ebook5
 

Mehr von Concentrated Technology

Virtualization auditing & security deck v1.0
Virtualization auditing & security deck v1.0Virtualization auditing & security deck v1.0
Virtualization auditing & security deck v1.0Concentrated Technology
 
Securely connecting to apps over the internet using rds
Securely connecting to apps over the internet using rdsSecurely connecting to apps over the internet using rds
Securely connecting to apps over the internet using rdsConcentrated Technology
 
Managing enterprise with PowerShell remoting
Managing enterprise with PowerShell remotingManaging enterprise with PowerShell remoting
Managing enterprise with PowerShell remotingConcentrated Technology
 
Inventory your network and clients with PowerShell
Inventory your network and clients with PowerShellInventory your network and clients with PowerShell
Inventory your network and clients with PowerShellConcentrated Technology
 

Mehr von Concentrated Technology (18)

Wsus sample scripts
Wsus sample scriptsWsus sample scripts
Wsus sample scripts
 
Wsus best practices
Wsus best practicesWsus best practices
Wsus best practices
 
Virtualization today
Virtualization todayVirtualization today
Virtualization today
 
Virtualization auditing & security deck v1.0
Virtualization auditing & security deck v1.0Virtualization auditing & security deck v1.0
Virtualization auditing & security deck v1.0
 
Vdi in-a-box
Vdi in-a-boxVdi in-a-box
Vdi in-a-box
 
Top ESXi command line v2.0
Top ESXi command line v2.0Top ESXi command line v2.0
Top ESXi command line v2.0
 
Securely connecting to apps over the internet using rds
Securely connecting to apps over the internet using rdsSecurely connecting to apps over the internet using rds
Securely connecting to apps over the internet using rds
 
Rapidly deploying software
Rapidly deploying softwareRapidly deploying software
Rapidly deploying software
 
PS scripting and modularization
PS scripting and modularizationPS scripting and modularization
PS scripting and modularization
 
Prepping software for w7 deployment
Prepping software for w7 deploymentPrepping software for w7 deployment
Prepping software for w7 deployment
 
PowerShell Remoting
PowerShell RemotingPowerShell Remoting
PowerShell Remoting
 
PowerShell crashcourse for sharepoint
PowerShell crashcourse for sharepointPowerShell crashcourse for sharepoint
PowerShell crashcourse for sharepoint
 
PowerShell custom properties
PowerShell custom propertiesPowerShell custom properties
PowerShell custom properties
 
PowerShell and WMI
PowerShell and WMIPowerShell and WMI
PowerShell and WMI
 
Managing enterprise with PowerShell remoting
Managing enterprise with PowerShell remotingManaging enterprise with PowerShell remoting
Managing enterprise with PowerShell remoting
 
Inventory your network and clients with PowerShell
Inventory your network and clients with PowerShellInventory your network and clients with PowerShell
Inventory your network and clients with PowerShell
 
Hyper v r2 deep dive
Hyper v r2 deep diveHyper v r2 deep dive
Hyper v r2 deep dive
 
How to configure esx to pass an audit
How to configure esx to pass an auditHow to configure esx to pass an audit
How to configure esx to pass an audit
 

Kürzlich hochgeladen

Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processorsdebabhi2
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobeapidays
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodJuan lago vázquez
 
DBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDropbox
 
A Beginners Guide to Building a RAG App Using Open Source Milvus
A Beginners Guide to Building a RAG App Using Open Source MilvusA Beginners Guide to Building a RAG App Using Open Source Milvus
A Beginners Guide to Building a RAG App Using Open Source MilvusZilliz
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProduct Anonymous
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...apidays
 
FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024The Digital Insurer
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingEdi Saputra
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...DianaGray10
 
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWEREMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWERMadyBayot
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Jeffrey Haguewood
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonAnna Loughnan Colquhoun
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century educationjfdjdjcjdnsjd
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Scriptwesley chun
 
Manulife - Insurer Transformation Award 2024
Manulife - Insurer Transformation Award 2024Manulife - Insurer Transformation Award 2024
Manulife - Insurer Transformation Award 2024The Digital Insurer
 
Navi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Navi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot ModelNavi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Navi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot ModelDeepika Singh
 
MS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsMS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsNanddeep Nachan
 
Corporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxCorporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxRustici Software
 

Kürzlich hochgeladen (20)

Exploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone ProcessorsExploring the Future Potential of AI-Enabled Smartphone Processors
Exploring the Future Potential of AI-Enabled Smartphone Processors
 
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law DevelopmentsTrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
TrustArc Webinar - Stay Ahead of US State Data Privacy Law Developments
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
 
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin WoodPolkadot JAM Slides - Token2049 - By Dr. Gavin Wood
Polkadot JAM Slides - Token2049 - By Dr. Gavin Wood
 
DBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor PresentationDBX First Quarter 2024 Investor Presentation
DBX First Quarter 2024 Investor Presentation
 
A Beginners Guide to Building a RAG App Using Open Source Milvus
A Beginners Guide to Building a RAG App Using Open Source MilvusA Beginners Guide to Building a RAG App Using Open Source Milvus
A Beginners Guide to Building a RAG App Using Open Source Milvus
 
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024FWD Group - Insurer Innovation Award 2024
FWD Group - Insurer Innovation Award 2024
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
 
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
Connector Corner: Accelerate revenue generation using UiPath API-centric busi...
 
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWEREMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
 
Data Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt RobisonData Cloud, More than a CDP by Matt Robison
Data Cloud, More than a CDP by Matt Robison
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
Automating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps ScriptAutomating Google Workspace (GWS) & more with Apps Script
Automating Google Workspace (GWS) & more with Apps Script
 
Manulife - Insurer Transformation Award 2024
Manulife - Insurer Transformation Award 2024Manulife - Insurer Transformation Award 2024
Manulife - Insurer Transformation Award 2024
 
Navi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Navi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot ModelNavi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot Model
Navi Mumbai Call Girls 🥰 8617370543 Service Offer VIP Hot Model
 
MS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectorsMS Copilot expands with MS Graph connectors
MS Copilot expands with MS Graph connectors
 
Corporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptxCorporate and higher education May webinar.pptx
Corporate and higher education May webinar.pptx
 

Managing SQLserver for the reluctant DBA

  • 2. Managing Microsoft SQL Server:For the “Reluctant” DBA Don Jones Senior Partner and Technologist Concentrated Technology, LLC Required Slide SESSION CODE: DAT203
  • 3. This slide deck was used in one of our many conference presentations. We hope you enjoy it, and invite you to use it within your own organization however you like. For more information on our company, including information on private classes and upcoming conference appearances, please visit our Web site, www.ConcentratedTech.com. For links to newly-posted decks, follow us on Twitter:@concentrateddon or @concentratdgreg This work is copyright ©Concentrated Technology, LLC
  • 4. Introductions Me: Don Jones, Concentrated Technology Microsoft MVP Award recipient Contributing Editor, TechNet Magazine Author of 45+ IT books Blogger at http://ConcentratedTech.com You: The “Microsoft Person” in your environment Not primarily concerned with supporting Microsoft SQL Server… …but more or less forced to do so anyway
  • 5. Agenda Peeking Under the Hood: How SQL Server Works Backup and Restore Operations About the Query Optimizer Index Maintenance and Tuning Key Database Configuration Options SQL Server Security Model Key Server Configuration Options High Availability and Replication Options
  • 6. How SQL Server Works, Part 1 SQL Server stores data in 8KB chunks called “pages” It always deals with data in these 8KB chunks Generally speaking, all data for a single table row must fit onto a single page It’s actually possible for certain types of data to spread across multiple pages Sometimes, the page can contain a pointer to a file on disk – the FILESTREAM data type The pages live in one or more files (.MDF, .NDF) on disk, but are always read or written in 8KB units
  • 7.
  • 8.
  • 9. SQL Server Backups Three types: Full – Backs up the entire database and removes (“truncates”) all “checked” entries from the transaction log Differential: Only what’s changed since the last Full; also truncates the log Transaction log: Only grabs the current transaction log; truncates the active log afterward
  • 10.
  • 11. Maximum amount of data at-risk: Any changes made since the most recent transaction log backup
  • 12.
  • 13. Indexes Two types: Clustered Every table has one, even if it’s just on the row ID number. Governs the order in which data is logically stored Should be on whatever column is used most for lookups or table joins Non-Clustered Every table can have zero or more Acts as a literal index, keeping entries in order by the indexed column and pointing to the full data row A “covering” index is one that contains entries for every column being queried
  • 14. Indexes: Pros and Cons Pros Indexes can speed up the time it takes to find data Also speed up sort times Ideally, index on all columns that are frequently used in a WHERE or ORDER BY clause Cons Indexes slow down data add/change/delete operations, because indexes must also be updated Ideally, index nothing The reality is a balancing act: Building indexes on columns that deliver the most benefit, with the least downside
  • 15. Index Problem: Fragmentation Occurs when index pages become full and data needs to be inserted into the middle A “page split” occurs to make room for the new entry, causing the pages to be “out of order” – this decreases performance NEW! Andrew Andrews Batista Barbara Charles Charlie Frank Gary Grossman Hugh Ina Jack Jackson Jones Kimberly Donavan Eric Erin Derek
  • 16. Fixing Fragementation Reorganizing or Rebuilding the index will put the entries and pages back into the correct order, improving performance You can specify a “fill factor” that leaves empty space for new entries without splitting pages as often However, emptier pages mean SQL Server has to work harder to read the same amount of data – so this is a balancing act
  • 18. Index Tuning The indexes that made sense for a database on day 1 might not make sense after it has been in use for some time You can use SQL Profiler to capture real-world, representative query traffic… …and feed that to the Database Engine Tuning Advisor to get recommendations on index improvements The Advisor can even help you implement those changes that you decide to proceed with
  • 19. Using the Database Engine Tuning Wizard DEMO
  • 20. Key Database Options and Best Practices Allow statistics to Auto-Create/Update This makes sure the Query Optimizer knows which indexes exist and what kind of condition they are in Consider disabling auto-growth, or at least monitor it Auto-Grow can consume time; better to manually size the database files appropriately Disable Auto Close except on infrequently-used databases Closed databases incur a performance hit when someone queries them since SQL Server has to open the file
  • 21. Configuring Key Database Options DEMO
  • 22. SQL Server Security Model Login: Map to a Windows user/group, or an in-server credential; gets you access to the server Server Role: Contains logins, and defines server-wide privileges Database user: Maps to a login, and gets you into a database Database Role: Contains database users, and defines in-database privileges Custom Database Role: Same as the built-in ones, but you define the permissions App Role: Shortcut login+databaseuser+permissions designed to be activated by an application that defines its own security layer for the data.
  • 23. Server Options Authentication Mode: “Windows” or “Windows+SQL Server” Memory and Processor options (typically, leave alone) Instances Each “instance” is an independent installation of SQL Server Has its own “server-wide” options (“instance-wide” is a better term) Default instance: Connect using server name Other instances: Connect using SERVERNSTANCE format Review list of services to see instances – each instance has its own SQL Server service
  • 24. Configuring Key Server and Security Options DEMO
  • 25. High Availability Options Log Shipping Database Mirroring Windows Clustering
  • 26. Where to Set Up Database Mirroring DEMO
  • 27. Replication Options Snapshot Transactional Transactional with Updating Subscribers Merge Off-Topic: Microsoft Sync Framework / Sync Services for ADO.NET
  • 28. Final Thoughts SQL Server Agent (and Jobs, Operators, and Alerts) Multi-Server Admininstration
  • 29. Agent, Jobs, and Multi-Server Administration DEMO
  • 30. Conclusion A few basic admin skills can help you perform the most often-needed SQL Server tasks Keep in mind that the SQL Server Management Studio can connect to multiple servers for single-seat administration
  • 31. Track Resources Required Slide Track PMs will supply the content for this slide, which will be inserted during the final scrub. Resource 1 Resource 2 Resource 3 Resource 4
  • 32. Resources Required Slide Learning Sessions On-Demand & Community Microsoft Certification & Training Resources www.microsoft.com/teched www.microsoft.com/learning Resources for IT Professionals Resources for Developers http://microsoft.com/technet http://microsoft.com/msdn
  • 33. Related Content Required Slide Speakers, please list the Breakout Sessions, Interactive Sessions, Labs and Demo Stations that are related to your session. Breakout Sessions (session codes and titles) Interactive Sessions (session codes and titles) Hands-on Labs (session codes and titles) Product Demo Stations (demo station title and location)
  • 34. Required Slide Complete an evaluation on CommNet and enter to win!
  • 35. © 2010 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista 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.
  • 36. This slide deck was used in one of our many conference presentations. We hope you enjoy it, and invite you to use it within your own organization however you like. For more information on our company, including information on private classes and upcoming conference appearances, please visit our Web site, www.ConcentratedTech.com. For links to newly-posted decks, follow us on Twitter:@concentrateddon or @concentratdgreg This work is copyright ©Concentrated Technology, LLC