Azure磁盘加密未启用

huangapple go评论89阅读模式
英文:

Azure Disk Encryption is not enabled

问题

我有一个Azure虚拟机。它有一个操作系统磁盘和一个数据磁盘。如果我在Azure门户中查看它的磁盘,我可以看到启用了加密,使用了平台托管的密钥。

但是当我运行以下az命令

az vm encryption show --name vm1 --resource-group rg1

Azure磁盘加密未启用

所以我的问题是这两种加密是不是不同的?如何在Azure门户上使用平台托管的密钥启用Azure磁盘加密?我的目标是在主机上启用加密。

提前感谢。

英文:

I have an Azure VM. It has one OS disk and one data disk. If I go to its disks in Azure portal, I see encryption enabled with a platform-managed key

Azure磁盘加密未启用

But when I run the below az command

az vm encryption show --name vm1 --resource-group rg1

Azure Disk Encryption is not enabled

so my question is are these two different encryptions? How do I enable Azure disk encryption using the platform managed key on the Azure portal? My goal is to enable encryption at the host.

Thanks in advance.

答案1

得分: 0

Azure Disk Encryption(ADE)未启用,我的目标是在主机上启用加密。

  1. 平台管理的磁盘加密: 此加密在平台级别启用,并应用于虚拟机的OS磁盘。当在Azure门户中看到磁盘上显示**“已启用加密”**时,意味着对这些磁盘启用了平台管理的磁盘加密。此加密由Azure管理,并使用平台管理的密钥

  2. Azure磁盘加密: 这是Azure中的一个特定功能,允许您在虚拟机的OS级别启用加密。它使用Azure Key Vault来存储加密密钥。当运行az vm encryption show命令时,它会检查虚拟机的OS磁盘是否已启用Azure磁盘加密

在平台级别启用平台管理的磁盘加密(如在Azure门户中显示的)不会自动为VM的OS磁盘启用Azure磁盘加密。这些是不同的功能。

当我在启用VM OS磁盘ADE之前检查磁盘加密状态时,我也得到了与您相同的结果。

结果

Azure磁盘加密未启用

要为VM的OS磁盘启用Azure磁盘加密,请按照以下步骤操作。

  1. 创建具有所需权限的Azure Key Vault,并确保包括--key-permissions wrapKey 权限以启用磁盘加密

  2. 一旦创建了密钥保管库,请使用以下命令启用密钥保管库以进行磁盘加密

az keyvault update --name "demovaulttest-test" --resource-group 'Imran' --enabled-for-disk-encryption "true"
  1. 使用以下命令使用密钥保管库对VM进行加密来加密VM。
az vm encryption enable --resource-group <rg-Name> --name <VM-Name> --disk-encryption-keyvault demovaulttest-test --volume-type ALL

输出:

Azure磁盘加密未启用

英文:

> Azure Disk Encryption is not enabled,My goal is to enable encryption at the host.

  1. Platform-managed disk encryption: This encryption is enabled at the platform level and is applied to the OS disk of the Virtual Machine. When you see "Encryption Enabled" on the disks in the Azure portal, it means that platform-managed disk encryption is turned on for those disks. This encryption is managed by Azure and uses a platform-managed key.

  2. Azure Disk Encryption: This is a specific feature in Azure that allows you to enable encryption at the OS level for virtual machines. It uses Azure Key Vault to store the encryption keys. When you run the az vm encryption show command, it checks whether Azure Disk Encryption is enabled for the virtual machine's OS disk.

Enabling platform-managed disk encryption at the platform level (as shown in the Azure portal) does not automatically enable Azure Disk Encryption for the VM's OS disk. These are separate features.

When I check the Disk encryption status before enabling ADE for the VM OS Disk, I also got the same result as you.

Result

Azure磁盘加密未启用

To enable Azure Disk Encryption for the VM&#39;s OS disk. follow the below steps.

  1. Create an Azure Key Vault with the required permissions, and make sure to include the --key-permissions wrapKey permission to enable disk encryption.

  2. Once the Key Vault is created, enable Key Vault for disk encryption using the below command.

 az keyvault update --name &quot;demovaulttest-test&quot; --resource-group &#39;Imran&#39; --enabled-for-disk-encryption &quot;true&quot;
  1. Encrypt a VM using a key vault using the below command.
az vm encryption enable --resource-group &lt;rg-Name&gt; --name &lt;VM-Name&gt; --disk-encryption-keyvault demovaulttest-test --volume-type ALL

Output:

Azure磁盘加密未启用

huangapple
  • 本文由 发表于 2023年7月28日 04:22:07
  • 转载请务必保留本文链接:https://go.coder-hub.com/76783164.html
匿名

发表评论

匿名网友

:?: :razz: :sad: :evil: :!: :smile: :oops: :grin: :eek: :shock: :???: :cool: :lol: :mad: :twisted: :roll: :wink: :idea: :arrow: :neutral: :cry: :mrgreen:

确定