
After completing this chapter you will be familiar with the overall understanding of the course.
After completing this chapter you will be able to understand the purpose of this course.
After completing this chapter you will understand the importance of automation of the database performance monitoring process.
After completing this chapter the students will be able to understand the type of data that needs to be collected as part of the database performance data collection.
Learn how the query optimizer selects the lowest-cost execution plan using statistics and cost estimates, stores the plan in memory, and how parameter sniffing can undermine this optimization.
After completing this lecture students will be able to understand the concept of Parameter Sniffing and how to fix it.
Schedule regular maintenance activities such as index updates, statistics updates, and database health checks to prevent performance degradation and downtime.
Identify expensive stored procedures or queries that drive high execution time and CPU usage, apply best practices, and continuously collect metrics to optimize performance and maintain business continuity.
Blocking occurs when one transaction locks a resource and another waits for it, creating a chain of incidents. Transactions E and B illustrate how a table lock makes B wait.
Demonstrates how deadlock arises when two transactions hold locks on resources and wait for each other, forcing a rollback of a victim to resume execution.
Examine how a flawed index strategy harms performance metrics by indexing unused columns, managing many operations on the same column, and identifying missing or unwanted indexes for business-aligned design.
Identify root causes of high cpu consumption by analyzing compilation and procedure execution, and monitor cpu usage with dynamic management views for daily monitoring on the production database server.
Learn memory configurations and parameters that influence SQL Server performance under heavy load, including memory pressure and large-sort query impacts. Explore lazy writer, checkpoint, and memory metrics like min/max memory.
Diagnose disk i/o bottlenecks by examining read and write operations on physical disks across storage types; use DMVs to gather disk-level performance data for diagnosis.
Plan for database design with thorough planning, normalization for data integrity, and clear naming standards; document table relationships and domain data to avoid single-table designs and performance issues.
Explore index management concepts, including clustered and nonclustered indexes, and learn to diagnose blocking and deadlocks, analyze execution plans, and optimize performance with practical examples.
Analyze execution plans to see how indexes are used, distinguishing index seeks and scans. Use DMV scripts to identify missing indexes and estimate their potential performance impact.
After completing this lecture, students will be able to understand and implement how to detect and reduce the index fragmentation.
Learn how wait statistics guide performance troubleshooting by analyzing wait types and cumulative data from the wait statistics view. Identify dominating waits by total wait time to diagnose CPU contention.
Identify tempdb contention by monitoring DMV waits and heavy temp table usage. Increase data files to maximize disk bandwidth and match logical processors, as SQL Server 2019 auto-tunes the count.
Learn temporary table caching in SQL Server to keep data in memory for faster reads, understand when it applies and its limitations, and use the DMV to monitor creation rate.
Evaluate temporary tables and table variables to optimize performance by data volume and scope; temp tables offer more control but risk contention, while table variables suit small datasets.
Identify expensive stored procedures and queries by using DMVs to capture execution time, CPU time, and resource usage, and analyze trends with average metrics and execution counts.
Identify blocking incidents with the DMV, examining how locks on resources affect transactions and queries, and use blocking text, cpu time, and logical reads to diagnose blocking scenarios.
After completion of this lecture, students will be able to understand what is Deadlock incident and how to monitor it.
Enable optimize for ad hoc workload to reduce plan cache bloat from single-use queries. The first execution stores a small, combined plan; subsequent executions reuse the full cached plan.
Analyze execution plans using estimated and actual methods to observe runtime information and resource usage. Inspect operators such as table scans, index scans, bookmarks lookups, and nested loops.
Automate SQL Server performance monitoring by categorizing jobs into continuous, five-minute, and daily data collection, and collect CPU, memory, deadlocks, blocking incidents, and resource usage to guide tuning.
This course equips you with the skills required to manage the SQL Server database efficiently. The course mainly focuses on performance monitoring and tuning and how to automate the monitoring process. The most valuable gift of this course is to have ready to implement scripts including schema and other required objects at the end of the course. Students can directly deploy the code and start generating SQL Server database performance metrics.
Note: It is recommended to run the code on a test environment before deploying on production.