Third-party tools like Avi-Point , Gs Richcopy 360 , MultiCloud, or Commvault can be used to automate the replication process directly from Azure to other clouds like AWS and GCP .
Is is possible to replicate Azure SQL Backups to a external cloud
I have configured backups for my Azure SQL database and I'm interested in replicating the LTR backups to an external cloud like AWS or GCP. For example, if I can configure Azure to place the LTR backups into a storage account, then I could build the replication logic. But as it stands, I can't seem to find any way to access my own backups - other than restoring them into a new Azure DB.
3 answers
Sort by: Most helpful
-
-
Can Kucukgultekin 0 Reputation points
2024-05-14T21:23:40.23+00:00 Accessing LTR (Long-Term Retention) backups for Azure SQL Database directly isn't supported, as Azure manages these backups internally. However, there are a few strategies you can consider for replicating your Azure SQL Database backups to AWS or GCP:
Custom Backup Solution: Implement a custom backup solution using tools like SQL Server Management Studio (SSMS) or Azure Automation to perform regular exports of your database to a .bacpac file. Store these files in an Azure Storage Account, from where they can be copied to AWS S3 or GCP Storage.
Azure Data Factory: Use Azure Data Factory to create a pipeline that exports data from Azure SQL Database to Azure Blob Storage. From there, you can set up a process to transfer the data to AWS or GCP.
- Database Export via PowerShell: Use Azure PowerShell to automate the export of your database to a .bacpac file, which can then be transferred to other cloud storage solutions.
Here’s a sample PowerShell script to export an Azure SQL Database to a .bacpac file:
# Define parameters $subscriptionId = "<your_subscription_id>" $resourceGroupName = "<your_resource_group_name>" $serverName = "<your_sql_server_name>" $databaseName = "<your_database_name>" $storageAccountName = "<your_storage_account_name>" $storageContainerName = "<your_storage_container_name>" $bacpacFileName = "<your_bacpac_file_name>.bacpac" # Login to Azure Connect-AzAccount Set-AzContext -SubscriptionId $subscriptionId # Export database to bacpac file New-AzSqlDatabaseExport -ResourceGroupName $resourceGroupName -ServerName $serverName -DatabaseName $databaseName -StorageKeyType "StorageAccessKey" -StorageKey "<your_storage_account_key>" -StorageUri "https://$storageAccountName.blob.core.windows.net/$storageContainerName/$bacpacFileName" -AdministratorLogin "<your_admin_login>" -AdministratorLoginPassword (ConvertTo-SecureString "<your_password>" -AsPlainText -Force)
After exporting the .bacpac file to Azure Blob Storage, you can configure cross-cloud replication using tools like AWS DataSync or GCP Transfer Service.
-
Oury Ba-MSFT 19,886 Reputation points Microsoft Employee
2024-05-20T21:49:03.5433333+00:00 @Kevin Schmidt Thank you for reaching out.
As mentioned below by Can Kucukgultekin Azure doesn’t directly replicate LTR backups to AWS or GCP however you can build your own replication logic.
You can consider a hybrid approach where you maintain a local copy of LTR backups in Azure Blob storage and replicate only essential data to the external cloud.
Regards,
Oury