Thor Logo dbatools

Performance

A New CSV Library: Built for SQL Server

Chrissy LeMaire

This post is about a huge update to the CSV import (and now export!) capabilities in dbatools. If you’ve used Import-DbaCsv, you’ve been using the LumenWorks CSV library under the hood for years. It’s been rock solid and I’ve sung its praises many times. But LumenWorks was last updated 7-8 years ago, and .NET has come a long way since then. I’ve been using Claude Code for various projects and had a Max 20x account when Anthropic announced they’d be pretty much giving away Opus 4.

Read more

Export-DbaExecutionPlan

Chrissy LeMaire (@cl), netnerds.net

Export-DbaExecutionPlan View Source Chrissy LeMaire (@cl), netnerds.net Windows, Linux, macOS On this page: Synopsis · Description · Syntax · Examples · Parameters · Outputs Synopsis Extracts execution plans from plan cache and saves them as .sqlplan files for analysis Description Queries the SQL Server plan cache using dynamic management views and exports execution plans as XML files with .sqlplan extensions. These files can be opened directly in SQL Server Management Studio for detailed analysis and troubleshooting.

Read more

Export-DbaPfDataCollectorSetTemplate

Chrissy LeMaire (@cl), netnerds.net

Export-DbaPfDataCollectorSetTemplate View Source Chrissy LeMaire (@cl), netnerds.net Windows, Linux, macOS On this page: Synopsis · Description · Syntax · Examples · Parameters · Outputs Synopsis Exports Windows Performance Monitor Data Collector Set configurations as reusable XML templates. Description Exports Data Collector Set configurations from Windows Performance Monitor as XML template files that can be imported on other SQL Server hosts. This allows you to standardize performance monitoring across your SQL Server environment by saving custom counter collections, sampling intervals, and output settings as portable templates.

Read more

Get-DbaCpuUsage

Chrissy LeMaire (@cl), netnerds.net

Get-DbaCpuUsage View Source Chrissy LeMaire (@cl), netnerds.net Windows, Linux, macOS On this page: Synopsis · Description · Syntax · Examples · Parameters · Outputs Synopsis Correlates SQL Server processes with Windows threads to identify which queries are consuming CPU resources Description When CPU usage is high on your SQL Server, it can be difficult to pinpoint which specific SQL queries or processes are responsible using standard SQL Server tools alone.

Read more

Get-DbaExecutionPlan

Chrissy LeMaire (@cl), netnerds.net

Get-DbaExecutionPlan View Source Chrissy LeMaire (@cl), netnerds.net Windows, Linux, macOS On this page: Synopsis · Description · Syntax · Examples · Parameters · Outputs Synopsis Retrieves cached execution plans and metadata from SQL Server’s plan cache Description Retrieves execution plans from SQL Server’s plan cache using Dynamic Management Views (sys.dm_exec_query_stats, sys.dm_exec_query_plan, and sys.dm_exec_text_query_plan). This is essential for performance analysis because it shows you what queries are actually running and how SQL Server is executing them, without having to capture plans in real-time.

Read more

Get-DbaPfAvailableCounter

Chrissy LeMaire (@cl), netnerds.net

Get-DbaPfAvailableCounter View Source Chrissy LeMaire (@cl), netnerds.net Windows, Linux, macOS On this page: Synopsis · Description · Syntax · Examples · Parameters · Outputs Synopsis Retrieves all Windows performance counters available on local or remote machines for monitoring setup. Description Retrieves all Windows performance counters available on specified machines by reading directly from the registry for fast enumeration. This is essential when setting up SQL Server monitoring because you need to know which specific counters are available before configuring data collectors or performance monitoring solutions.

Read more

Get-DbaPfDataCollector

Chrissy LeMaire (@cl), netnerds.net

Get-DbaPfDataCollector View Source Chrissy LeMaire (@cl), netnerds.net Windows, Linux, macOS On this page: Synopsis · Description · Syntax · Examples · Parameters · Outputs Synopsis Retrieves Windows Performance Monitor data collectors and their configuration details from local or remote computers. Description Retrieves detailed information about Windows Performance Monitor data collectors within collector sets, commonly used by DBAs to monitor SQL Server performance counters. This function parses the XML configuration of existing data collectors to show their settings, file locations, sample intervals, and the specific performance counters they collect.

Read more

Get-DbaPfDataCollectorCounter

Chrissy LeMaire (@cl), netnerds.net

Get-DbaPfDataCollectorCounter View Source Chrissy LeMaire (@cl), netnerds.net Windows, Linux, macOS On this page: Synopsis · Description · Syntax · Examples · Parameters · Outputs Synopsis Retrieves performance counter configurations from Windows Performance Monitor Data Collector Sets. Description Retrieves the list of performance counters that are configured within Windows Performance Monitor Data Collector Sets. This is useful for auditing performance monitoring configurations, verifying which SQL Server and system counters are being collected, and understanding your performance data collection setup.

Read more

Get-DbaPfDataCollectorCounterSample

Chrissy LeMaire (@cl), netnerds.net

Get-DbaPfDataCollectorCounterSample View Source Chrissy LeMaire (@cl), netnerds.net Windows, Linux, macOS On this page: Synopsis · Description · Syntax · Examples · Parameters · Outputs Synopsis Retrieves real-time performance counter samples from SQL Server systems for monitoring and troubleshooting. Description Collects performance counter data from Windows Performance Monitor collector sets and individual counters on SQL Server systems. This function wraps PowerShell’s Get-Counter cmdlet to provide structured performance data that DBAs use for monitoring CPU, memory, disk I/O, and SQL Server-specific metrics.

Read more

Get-DbaPfDataCollectorSet

Chrissy LeMaire (@cl), netnerds.net

Get-DbaPfDataCollectorSet View Source Chrissy LeMaire (@cl), netnerds.net Windows, Linux, macOS On this page: Synopsis · Description · Syntax · Examples · Parameters · Outputs Synopsis Retrieves Windows Performance Monitor Data Collector Sets and their configuration details. Description Retrieves detailed information about Windows Performance Monitor Data Collector Sets, which are used to collect performance counters for SQL Server monitoring and troubleshooting. Data Collector Sets define what performance counters to collect, when to collect them, and where to store the collected data.

Read more
← Previous
1 2
Next →
Page 1 of 2