Thor Logo dbatools

Migration

Copy-DbaDatabase

Chrissy LeMaire (@cl), netnerds.net

Copy-DbaDatabase View Source Chrissy LeMaire (@cl), netnerds.net Windows, Linux, macOS Synopsis Migrates SQL Server databases between instances using backup/restore or detach/attach methods. Description Moves user databases from one SQL Server instance to another, supporting both on-premises and Azure SQL Managed Instance destinations. Ideal for server migrations, environment refreshes, disaster recovery testing, and cloud migrations where you need to relocate entire databases with their data and structure intact. Offers two migration methods: backup/restore (safer, supports cross-version migrations) and detach/attach (faster, requires same SQL Server version).

Read more

Copy-DbaDataCollector

Chrissy LeMaire (@cl), netnerds.net

Copy-DbaDataCollector View Source Chrissy LeMaire (@cl), netnerds.net Windows, Linux, macOS Synopsis Copies SQL Data Collector collection sets from one instance to another Description Copies SQL Data Collector collection sets between SQL Server instances, allowing you to replicate performance monitoring configurations across your environment. This command scripts out the collection set definitions from the source instance and recreates them on the destination, preserving all collection items, schedules, and upload settings.

Read more

Copy-DbaDbAssembly

Chrissy LeMaire (@cl), netnerds.net

Copy-DbaDbAssembly View Source Chrissy LeMaire (@cl), netnerds.net Windows, Linux, macOS Synopsis Copies CLR assemblies from source databases to destination SQL Server instances Description Migrates custom CLR assemblies from databases on a source SQL Server to corresponding databases on destination instances. This function scans all accessible databases for user-created assemblies and recreates them on the target servers, automatically handling security requirements like setting the TRUSTWORTHY property for external assemblies. Designed for database migration scenarios where applications rely on custom .

Read more

Copy-DbaDbCertificate

Chrissy LeMaire (@cl), netnerds.net

Copy-DbaDbCertificate View Source Chrissy LeMaire (@cl), netnerds.net Windows, Linux, macOS Synopsis Copies database-level certificates from source SQL Server to destination servers, including private keys and master key dependencies. Description Transfers database certificates between SQL Server instances by backing them up from source databases and restoring them to matching databases on destination servers. This function handles the complex certificate migration process that’s essential when moving databases with Transparent Data Encryption (TDE) or other certificate-based security features.

Read more

Copy-DbaDbMail

Chrissy LeMaire (@cl), netnerds.net

Copy-DbaDbMail View Source Chrissy LeMaire (@cl), netnerds.net Windows, Linux, macOS Synopsis Copies Database Mail configuration including profiles, accounts, mail servers and settings between SQL Server instances. Description Migrates the complete Database Mail setup from a source SQL Server to one or more destination servers. This includes mail profiles (which group accounts for specific purposes), mail accounts (SMTP configurations), mail servers (SMTP server details and credentials), and global configuration values like account retry attempts and maximum file size.

Read more

Copy-DbaEndpoint

Chrissy LeMaire (@cl), netnerds.net

Copy-DbaEndpoint View Source Chrissy LeMaire (@cl), netnerds.net Windows, Linux, macOS Synopsis Copies SQL Server endpoints from source instance to destination instances for migration scenarios. Description Migrates user-defined endpoints (excluding system endpoints) from a source SQL Server to one or more destination servers. This includes Service Broker, Database Mirroring, and Availability Group endpoints that are essential for high availability configurations. Existing endpoints on the destination are skipped by default to prevent conflicts, but can be overwritten using the -Force parameter.

Read more

Copy-DbaInstanceAudit

Chrissy LeMaire (@cl), netnerds.net

Copy-DbaInstanceAudit View Source Chrissy LeMaire (@cl), netnerds.net Windows, Linux, macOS Synopsis Copies SQL Server audit objects from source to destination instances Description Migrates SQL Server audit objects and their configurations from one instance to another, preserving audit settings and file paths. This function handles the complex task of recreating audit definitions on destination servers, making it essential for server migrations, disaster recovery scenarios, or standardizing auditing policies across multiple SQL Server instances.

Read more

Copy-DbaInstanceAuditSpecification

Chrissy LeMaire (@cl), netnerds.net

Copy-DbaInstanceAuditSpecification View Source Chrissy LeMaire (@cl), netnerds.net Windows, Linux, macOS Synopsis Copies server audit specifications from one SQL Server instance to another for compliance standardization. Description Migrates server audit specifications between SQL Server instances, allowing DBAs to standardize audit configurations across environments or restore audit settings during disaster recovery. The function scripts existing audit specifications from the source server and recreates them on the destination, but only if the corresponding server audits already exist on the target instance.

Read more

Copy-DbaInstanceTrigger

Chrissy LeMaire (@cl), netnerds.net

Copy-DbaInstanceTrigger View Source Chrissy LeMaire (@cl), netnerds.net Windows, Linux, macOS Synopsis Copies server-level triggers between SQL Server instances for migration or standardization Description Migrates server-level triggers from a source SQL Server instance to one or more destination instances. This is essential during server migrations, disaster recovery setup, or when standardizing security and audit triggers across your environment. Server triggers fire in response to server-level events like logons, DDL changes, or server startup.

Read more

Copy-DbaLinkedServer

Chrissy LeMaire (@cl), netnerds.net

Copy-DbaLinkedServer View Source Chrissy LeMaire (@cl), netnerds.net Windows, Linux, macOS Synopsis Migrates linked servers and their authentication credentials from one SQL Server instance to another Description Migrates SQL Server linked servers including all authentication credentials and connection settings from a source instance to one or more destination instances. The function preserves usernames and passwords by using password decryption techniques, eliminating the need to manually recreate linked server configurations and re-enter sensitive credentials.

Read more
Page 2 of 5