Skip to content

Commit 6c29495

Browse files
Merge pull request #232535 from roygara/fixEncHost
Clarifying pre-req sections
2 parents 139598d + 893efe4 commit 6c29495

File tree

3 files changed

+40
-34
lines changed

3 files changed

+40
-34
lines changed

articles/virtual-machines/disks-enable-host-based-encryption-portal.md

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ description: Use encryption at host to enable end-to-end encryption on your Azur
44
author: roygara
55
ms.service: storage
66
ms.topic: how-to
7-
ms.date: 01/19/2023
7+
ms.date: 03/28/2023
88
ms.author: rogarana
99
ms.subservice: disks
1010
ms.custom: references_regions
@@ -94,7 +94,7 @@ Once the feature is enabled, you need to set up an Azure Key Vault and a disk en
9494

9595
### Deploy a VM
9696

97-
Now that you've setup an Azure Key Vault and disk encryption set, you can deploy a VM and it uses encryption at host.
97+
Now that you have setup an Azure Key Vault and disk encryption set, you can deploy a VM and it uses encryption at host.
9898

9999
1. Sign in to the [Azure portal](https://portal.azure.com).
100100
1. Search for **Virtual Machines** and select **+ Add** to create a VM.

articles/virtual-machines/linux/disks-enable-host-based-encryption-cli.md

Lines changed: 17 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ description: Use encryption at host to enable end-to-end encryption on your Azur
44
author: roygara
55
ms.service: storage
66
ms.topic: how-to
7-
ms.date: 03/20/2023
7+
ms.date: 03/28/2023
88
ms.author: rogarana
99
ms.subservice: disks
1010
ms.custom: references_regions, devx-track-azurecli
@@ -14,7 +14,7 @@ ms.custom: references_regions, devx-track-azurecli
1414

1515
**Applies to:** :heavy_check_mark: Linux VMs :heavy_check_mark: Flexible scale sets
1616

17-
When you enable encryption at host, data stored on the VM host is encrypted at rest and flows encrypted to the Storage service. For conceptual information on encryption at host, as well as other managed disk encryption types, see [Encryption at host - End-to-end encryption for your VM data](../disk-encryption.md#encryption-at-host---end-to-end-encryption-for-your-vm-data).
17+
When you enable encryption at host, data stored on the VM host is encrypted at rest and flows encrypted to the Storage service. For conceptual information on encryption at host, and other managed disk encryption types, see [Encryption at host - End-to-end encryption for your VM data](../disk-encryption.md#encryption-at-host---end-to-end-encryption-for-your-vm-data).
1818

1919
## Restrictions
2020

@@ -23,7 +23,7 @@ When you enable encryption at host, data stored on the VM host is encrypted at r
2323
### Supported VM sizes
2424

2525
The complete list of supported VM sizes can be pulled programmatically. To learn how to retrieve them programmatically, see the [Finding supported VM sizes](#finding-supported-vm-sizes) section.
26-
Upgrading the VM size will result in validation to check if the new VM size supports the EncryptionAtHost feature.
26+
Upgrading the VM size results in validation to check if the new VM size supports the EncryptionAtHost feature.
2727

2828
## Prerequisites
2929

@@ -44,11 +44,14 @@ az feature show --namespace Microsoft.Compute --name EncryptionAtHost
4444

4545
### Create resources
4646

47-
Once the feature is enabled, you'll need to set up a DiskEncryptionSet and either an [Azure Key Vault](../../key-vault/general/overview.md) or an [Azure Key Vault Managed HSM](../../key-vault/managed-hsm/overview.md).
47+
> [!NOTE]
48+
> This section only applies to configurations with customer-managed keys. If you're using platform-managed keys, you can skip to the [Example scripts](#example-scripts) section.
49+
50+
Once the feature is enabled, you need to set up a DiskEncryptionSet and either an [Azure Key Vault](../../key-vault/general/overview.md) or an [Azure Key Vault Managed HSM](../../key-vault/managed-hsm/overview.md).
4851

4952
[!INCLUDE [virtual-machines-disks-encryption-create-key-vault-cli](../../../includes/virtual-machines-disks-encryption-create-key-vault-cli.md)]
5053

51-
## Examples
54+
## Example scripts
5255

5356
### Create a VM with encryption at host enabled with customer-managed keys.
5457

@@ -133,9 +136,9 @@ az vm update -n $vmName \
133136
--set securityProfile.encryptionAtHost=false
134137
```
135138

136-
### Create a virtual machine scale set with encryption at host enabled with customer-managed keys.
139+
### Create a Virtual Machine Scale Set with encryption at host enabled with customer-managed keys.
137140

138-
Create a virtual machine scale set with managed disks using the resource URI of the DiskEncryptionSet created earlier to encrypt cache of OS and data disks with customer-managed keys. The temp disks are encrypted with platform-managed keys.
141+
Create a Virtual Machine Scale Set with managed disks using the resource URI of the DiskEncryptionSet created earlier to encrypt cache of OS and data disks with customer-managed keys. The temp disks are encrypted with platform-managed keys.
139142

140143
```azurecli
141144
rgName=yourRGName
@@ -159,9 +162,9 @@ az vmss create -g $rgName \
159162
--data-disk-encryption-sets $diskEncryptionSetId $diskEncryptionSetId
160163
```
161164

162-
### Create a virtual machine scale set with encryption at host enabled with platform-managed keys.
165+
### Create a Virtual Machine Scale Set with encryption at host enabled with platform-managed keys.
163166

164-
Create a virtual machine scale set with encryption at host enabled to encrypt cache of OS/data disks and temp disks with platform-managed keys.
167+
Create a Virtual Machine Scale Set with encryption at host enabled to encrypt cache of OS/data disks and temp disks with platform-managed keys.
165168

166169
```azurecli
167170
rgName=yourRGName
@@ -180,7 +183,7 @@ az vmss create -g $rgName \
180183
--data-disk-sizes-gb 64 128 \
181184
```
182185

183-
### Update a virtual machine scale set to enable encryption at host.
186+
### Update a Virtual Machine Scale Set to enable encryption at host.
184187

185188
```azurecli
186189
rgName=yourRGName
@@ -191,7 +194,7 @@ az vmss update -n $vmssName \
191194
--set virtualMachineProfile.securityProfile.encryptionAtHost=true
192195
```
193196

194-
### Check the status of encryption at host for a virtual machine scale set
197+
### Check the status of encryption at host for a Virtual Machine Scale Set
195198

196199
```azurecli
197200
rgName=yourRGName
@@ -202,9 +205,9 @@ az vmss show -n $vmssName \
202205
--query [virtualMachineProfile.securityProfile.encryptionAtHost] -o tsv
203206
```
204207

205-
### Update a virtual machine scale set to disable encryption at host.
208+
### Update a Virtual Machine Scale Set to disable encryption at host.
206209

207-
You can disable encryption at host on your virtual machine scale set but, this will only affect VMs created after you disable encryption at host. For existing VMs, you must deallocate the VM, [disable encryption at host on that individual VM](#update-a-vm-to-disable-encryption-at-host), then reallocate the VM.
210+
You can disable encryption at host on your Virtual Machine Scale Set but, this will only affect VMs created after you disable encryption at host. For existing VMs, you must deallocate the VM, [disable encryption at host on that individual VM](#update-a-vm-to-disable-encryption-at-host), then reallocate the VM.
208211

209212
```azurecli
210213
rgName=yourRGName
@@ -217,7 +220,7 @@ az vmss update -n $vmssName \
217220

218221
## Finding supported VM sizes
219222

220-
Legacy VM Sizes are not supported. You can find the list of supported VM sizes by either using resource SKU APIs or the Azure PowerShell module. You can't find the supported sizes using the CLI.
223+
Legacy VM Sizes aren't supported. You can find the list of supported VM sizes by either using resource SKU APIs or the Azure PowerShell module. You can't find the supported sizes using the CLI.
221224

222225
When calling the [Resource Skus API](/rest/api/compute/resourceskus/list), check that the `EncryptionAtHostSupported` capability is set to **True**.
223226

articles/virtual-machines/windows/disks-enable-host-based-encryption-powershell.md

Lines changed: 21 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -4,7 +4,7 @@ description: How to enable end-to-end encryption for your Azure VMs using encryp
44
author: roygara
55
ms.service: storage
66
ms.topic: how-to
7-
ms.date: 11/17/2021
7+
ms.date: 03/28/2023
88
ms.author: rogarana
99
ms.subservice: disks
1010
ms.custom: references_regions, devx-track-azurepowershell, ignite-fall-2021
@@ -14,7 +14,7 @@ ms.custom: references_regions, devx-track-azurepowershell, ignite-fall-2021
1414

1515
**Applies to:** :heavy_check_mark: Windows VMs
1616

17-
When you enable encryption at host, data stored on the VM host is encrypted at rest and flows encrypted to the Storage service. For conceptual information on encryption at host, as well as other managed disk encryption types, see [Encryption at host - End-to-end encryption for your VM data](../disk-encryption.md#encryption-at-host---end-to-end-encryption-for-your-vm-data).
17+
When you enable encryption at host, data stored on the VM host is encrypted at rest and flows encrypted to the Storage service. For conceptual information on encryption at host, and other managed disk encryption types, see [Encryption at host - End-to-end encryption for your VM data](../disk-encryption.md#encryption-at-host---end-to-end-encryption-for-your-vm-data).
1818

1919
## Restrictions
2020

@@ -24,19 +24,19 @@ When you enable encryption at host, data stored on the VM host is encrypted at r
2424
### Supported VM sizes
2525

2626
The complete list of supported VM sizes can be pulled programmatically. To learn how to retrieve them programmatically, refer to the [Finding supported VM sizes](#finding-supported-vm-sizes) section.
27-
Upgrading the VM size will result in validation to check if the new VM size supports the EncryptionAtHost feature.
27+
Upgrading the VM size results in validation to check if the new VM size supports the EncryptionAtHost feature.
2828

2929
## Prerequisites
3030

31-
You must enable the feature for your subscription before you use the EncryptionAtHost property for your VM/VMSS. Please follow the steps below to enable the feature for your subscription:
31+
You must enable the feature for your subscription before you use the EncryptionAtHost property for your VM/VMSS. Use the following steps to enable the feature for your subscription:
3232

3333
1. Execute the following command to register the feature for your subscription
3434

3535
```powershell
3636
Register-AzProviderFeature -FeatureName "EncryptionAtHost" -ProviderNamespace "Microsoft.Compute"
3737
```
3838

39-
2. Please check that the registration state is Registered (takes a few minutes) using the command below before trying out the feature.
39+
2. Check that the registration state is Registered (takes a few minutes) using the following command before trying out the feature.
4040

4141
```powershell
4242
Get-AzProviderFeature -FeatureName "EncryptionAtHost" -ProviderNamespace "Microsoft.Compute"
@@ -45,17 +45,20 @@ You must enable the feature for your subscription before you use the EncryptionA
4545

4646
### Create an Azure Key Vault and DiskEncryptionSet
4747

48-
Once the feature is enabled, you'll need to set up an Azure Key Vault and a DiskEncryptionSet, if you haven't already.
48+
> [!NOTE]
49+
> This section only applies to configurations with customer-managed keys. If you're using platform-managed keys, you can skip to the [Example scripts](#example-scripts) section.
50+
51+
Once the feature is enabled, you need to set up an Azure Key Vault and a DiskEncryptionSet, if you haven't already.
4952

5053
[!INCLUDE [virtual-machines-disks-encryption-create-key-vault-powershell](../../../includes/virtual-machines-disks-encryption-create-key-vault-powershell.md)]
5154

52-
## Enable encryption at host for disks attached to VM and virtual machine scale sets
55+
## Enable encryption at host for disks attached to VM and Virtual Machine Scale Sets
5356

54-
You can enable encryption at host by setting a new property EncryptionAtHost under securityProfile of VMs or virtual machine scale sets using the API version **2020-06-01** and above.
57+
You can enable encryption at host by setting a new property EncryptionAtHost under securityProfile of VMs or Virtual Machine Scale Sets using the API version **2020-06-01** and above.
5558

5659
`"securityProfile": { "encryptionAtHost": "true" }`
5760

58-
## Examples
61+
## Example scripts
5962

6063
### Create a VM with encryption at host enabled with customer-managed keys.
6164

@@ -182,9 +185,9 @@ Stop-AzVM -ResourceGroupName $ResourceGroupName -Name $VMName -Force
182185
Update-AzVM -VM $VM -ResourceGroupName $ResourceGroupName -EncryptionAtHost $false
183186
```
184187

185-
### Create a virtual machine scale set with encryption at host enabled with customer-managed keys.
188+
### Create a Virtual Machine Scale Set with encryption at host enabled with customer-managed keys.
186189

187-
Create a virtual machine scale set with managed disks using the resource URI of the DiskEncryptionSet created earlier to encrypt cache of OS and data disks with customer-managed keys. The temp disks are encrypted with platform-managed keys.
190+
Create a Virtual Machine Scale Set with managed disks using the resource URI of the DiskEncryptionSet created earlier to encrypt cache of OS and data disks with customer-managed keys. The temp disks are encrypted with platform-managed keys.
188191

189192
```powershell
190193
$VMLocalAdminUser = "yourLocalAdminUser"
@@ -226,9 +229,9 @@ $VMSS = Set-AzVmssOsProfile $VMSS -ComputerNamePrefix $ComputerNamePrefix -Admin
226229
$VMSS = Add-AzVmssDataDisk -VirtualMachineScaleSet $VMSS -CreateOption Empty -Lun 1 -DiskSizeGB 128 -StorageAccountType Premium_LRS -DiskEncryptionSetId $diskEncryptionSet.Id
227230
```
228231

229-
### Create a virtual machine scale set with encryption at host enabled with platform-managed keys.
232+
### Create a Virtual Machine Scale Set with encryption at host enabled with platform-managed keys.
230233

231-
Create a virtual machine scale set with encryption at host enabled to encrypt cache of OS/data disks and temp disks with platform-managed keys.
234+
Create a Virtual Machine Scale Set with encryption at host enabled to encrypt cache of OS/data disks and temp disks with platform-managed keys.
232235

233236
```powershell
234237
$VMLocalAdminUser = "yourLocalAdminUser"
@@ -267,7 +270,7 @@ $Credential = New-Object System.Management.Automation.PSCredential ($VMLocalAdmi
267270
New-AzVmss -VirtualMachineScaleSet $VMSS -ResourceGroupName $ResourceGroupName -VMScaleSetName $VMScaleSetName
268271
```
269272

270-
### Update a virtual machine scale set to enable encryption at host.
273+
### Update a Virtual Machine Scale Set to enable encryption at host.
271274

272275
```powershell
273276
$ResourceGroupName = "yourResourceGroupName"
@@ -278,7 +281,7 @@ $VMSS = Get-AzVmss -ResourceGroupName $ResourceGroupName -Name $VMScaleSetName
278281
Update-AzVmss -VirtualMachineScaleSet $VMSS -Name $VMScaleSetName -ResourceGroupName $ResourceGroupName -EncryptionAtHost $true
279282
```
280283

281-
### Check the status of encryption at host for a virtual machine scale set
284+
### Check the status of encryption at host for a Virtual Machine Scale Set
282285

283286
```powershell
284287
$ResourceGroupName = "yourResourceGroupName"
@@ -289,9 +292,9 @@ $VMSS = Get-AzVmss -ResourceGroupName $ResourceGroupName -Name $VMScaleSetName
289292
$VMSS.VirtualMachineProfile.SecurityProfile.EncryptionAtHost
290293
```
291294

292-
### Update a virtual machine scale set to disable encryption at host.
295+
### Update a Virtual Machine Scale Set to disable encryption at host.
293296

294-
You can disable encryption at host on your virtual machine scale set but, this will only affect VMs created after you disable encryption at host. For existing VMs, you must deallocate the VM, [disable encryption at host on that individual VM](#disable-encryption-at-host), then reallocate the VM.
297+
You can disable encryption at host on your Virtual Machine Scale Set but, this will only affect VMs created after you disable encryption at host. For existing VMs, you must deallocate the VM, [disable encryption at host on that individual VM](#disable-encryption-at-host), then reallocate the VM.
295298

296299
```powershell
297300
$ResourceGroupName = "yourResourceGroupName"
@@ -304,7 +307,7 @@ Update-AzVmss -VirtualMachineScaleSet $VMSS -Name $VMScaleSetName -ResourceGroup
304307

305308
## Finding supported VM sizes
306309

307-
Legacy VM Sizes are not supported. You can find the list of supported VM sizes by either:
310+
Legacy VM Sizes aren't supported. You can find the list of supported VM sizes by either:
308311

309312
Calling the [Resource Skus API](/rest/api/compute/resourceskus/list) and checking that the `EncryptionAtHostSupported` capability is set to **True**.
310313

0 commit comments

Comments
 (0)