Migrate to Innovate Summit:
Learn how migrating and modernizing to Azure can boost your business's performance, resilience, and security, enabling you to fully embrace AI.Register now
This browser is no longer supported.
Upgrade to Microsoft Edge to take advantage of the latest features, security updates, and technical support.
Enable transparent data encryption on SQL Managed Instance enabled by Azure Arc (preview)
Article
This article describes how to enable and disable transparent data encryption (TDE) at-rest on a SQL Managed Instance enabled by Azure Arc. In this article, the term managed instance refers to a deployment of SQL Managed Instance enabled by Azure Arc and enabling/disabling TDE will apply to all databases running on a managed instance.
The following limitations apply when you enable automatic TDE:
Only General Purpose Tier is supported.
Failover groups aren't supported.
Create a managed instance with TDE enabled (Azure CLI)
The following example creates a SQL Managed Instance enabled by Azure Arc with one replica, TDE enabled:
Azure CLI
az sql mi-arc create --name sqlmi-tde--k8s-namespace arc --tde-mode ServiceManaged --use-k8s
Turn on TDE on the managed instance
When TDE is enabled on Arc-enabled SQL Managed Instance, the data service automatically does the following tasks:
Adds the service-managed database master key in the master database.
Adds the service-managed certificate protector.
Adds the associated Database Encryption Keys (DEK) on all databases on the managed instance.
Enables encryption on all databases on the managed instance.
You can set SQL Managed Instance enabled by Azure Arc TDE in one of two modes:
Service-managed
Customer-managed
In service-managed mode, TDE requires the managed instance to use a service-managed database master key as well as the service-managed server certificate. These credentials are automatically created when service-managed TDE is enabled.
In customer-managed mode, TDE uses a service-managed database master key and uses keys you provide for the server certificate. To configure customer-managed mode:
Create a certificate.
Store the certificate as a secret in the same Kubernetes namespace as the instance.
When you back up credentials from the managed instance, the credentials are stored within the container. To store credentials on a persistent volume, specify the mount path in the container. For example, var/opt/mssql/data. The following example backs up a certificate from the managed instance:
Note
If the kubectl cp command is run from Windows, the command may fail when using absolute Windows paths. Use relative paths or the commands specified below.
Back up the certificate from the container to /var/opt/mssql/data.
Similar to above, to restore the credentials, copy them into the container and run the corresponding T-SQL afterwards.
Note
If the kubectl cp command is run from Windows, the command may fail when using absolute Windows paths. Use relative paths or the commands specified below.
To restore database backups that have been taken before enabling TDE, you would need to disable TDE on the SQL Managed Instance, restore the database backup and enable TDE again.
Copy the certificate from your file system to the container.
Administer an SQL Server database infrastructure for cloud, on-premises and hybrid relational databases using the Microsoft PaaS relational database offerings.
Learn how to respond to a potentially compromised TDE protector for Azure SQL Database or Azure Synapse Analytics using TDE with Bring Your Own Key (BYOK) support.
An overview of transparent data encryption for Azure SQL Database, Azure SQL Managed Instance, and Azure Synapse Analytics. The document covers its benefits and the options for configuration, which includes service-managed transparent data encryption and Bring Your Own Key.
Bring Your Own Key (BYOK) support for transparent data encryption (TDE) with Azure Key Vault for SQL Database and Azure Synapse Analytics. TDE with BYOK overview, benefits, how it works, considerations, and recommendations.
Overview of customer managed keys (CMK) support for transparent data encryption (TDE) with Azure Key Vault for Azure SQL Database at a database level granularity.
Learn how to rotate the Transparent data encryption (TDE) protector for a server in Azure used by Azure SQL Database, Azure SQL Managed Instance, and Azure Synapse Analytics using PowerShell and the Azure CLI.