שתף באמצעות


Monitor and troubleshoot data migration (Stretch Database)

Applies to: SQL Server 2016 (13.x) and later - Windows only

Important

Stretch Database is deprecated in SQL Server 2022 (16.x) and Azure SQL Database. This feature will be removed in a future version of the Database Engine. Avoid using this feature in new development work, and plan to modify applications that currently use this feature.

Check the status of data migration in a dynamic management view

Open the dynamic management view sys.dm_db_rda_migration_status to see how many batches and rows of data have been migrated. For more info, see sys.dm_db_rda_migration_status (Transact-SQL).

Troubleshoot data migration

Rows from my Stretch-enabled table are not being migrated to Azure. What's the problem?

There are several problems that can affect migration. Check the following things.

  • Check network connectivity for the SQL Server computer.

  • Check that the Azure firewall isn't blocking your SQL Server from connecting to the remote endpoint.

  • Check the dynamic management view sys.dm_db_rda_migration_status for the status of the latest batch. If an error has occurred, check the error_number, error_state, and error_severity values for the batch.

The Azure firewall is blocking connections from my local server

You may have to add a rule in the Azure firewall settings of the Azure server to let SQL Server communicate with the remote Azure server.

See also