Windows · July 21, 2025

Troubleshooting Guide for Azure Disk Encryption Issues on Linux VMs

Introduction
This guide is intended for IT professionals, information security analysts, and cloud administrators in organizations using Azure Disk Encryption. Its purpose is to assist in troubleshooting disk encryption-related issues.

Prerequisites
Before proceeding with any steps, ensure the VM targeted for encryption meets the following prerequisites:

CategoryRequirement
VM ConfigurationConfirm the VM size and OS are supported (refer to Azure Disk Encryption Overview).
NetworkingEnsure the VM can connect to Azure Key Vault and other required services.
Key StorageConfigure Azure Key Vault to store encryption keys.

Troubleshooting Guide
Below is a troubleshooting guide for common Azure Disk Encryption issues, presented in a table format for quick reference and clarity.

1. Troubleshooting OS Disk Encryption Failures on Linux

IssueCausesSolution
“Failed to unmount” error during OS disk encryption– VM environment modified from a supported gallery image, preventing OS drive unmount.
– Custom image mismatches supported filesystem/partition schemes.
– Resource-intensive apps running (e.g., SAP, MongoDB, Apache Cassandra, Docker).
– Custom scripts running concurrently.
– SELinux not disabled.
– OS disk uses LVM.
– Insufficient RAM (recommended ≥7 GB).
– Data drives mounted incorrectly (e.g., recursively under /mnt/).
Ensure the VM meets all prerequisites; inspect and resolve listed causes.

2. Updating Ubuntu 14.04 LTS Kernel

IssueCauseSolution
Out of Memory Killer terminates dd command during encryption on Ubuntu 14.04 LTSKnown issue in default kernel 4.4.Update to Azure-optimized kernel 4.15+:
1. Run sudo apt-get update
2. Run sudo apt-get install linux-azure
3. Run sudo reboot
4. After reboot, verify kernel version with uname -a.

3. Updating Azure VM Agent and Extension Versions

IssueCauseSolution
Encryption fails due to unsupported Azure VM Agent versionAgent version below 2.2.38.Update the agent version:
Refer to: Update Azure Linux Agent on a VM and Minimum version support for VM agents in Azure.

4. Failure to Encrypt Linux Disks

IssueCauseSolution
Encryption appears stuck at “OS disk encryption started,” SSH disabledProcess may take 3–16 hours or days (for large data disks).Check progress using Azure PowerShell’s Get-AzVMDiskEncryptionStatus:
PS > Get-AzVMDiskEncryptionStatus -ResourceGroupName "MyResourceGroup" -VMName "myVM"
Review the ProgressMessage field.

5. Troubleshooting Azure Disk Encryption Behind Firewalls

IssueCauseSolution
Issues encrypting VMs in isolated networksIncorrect networking.Refer to: Disk encryption on isolated networks.

6. Troubleshooting Encryption Status

IssueCauseSolution
Portal shows disk as encrypted even after decryptionDisk decrypted via low-level commands without updating platform-level settings.Use high-level decryption commands:
– PowerShell: Disable-AzVMDiskEncryption and Remove-AzVMDiskEncryptionExtension
– CLI: az vm encryption disable.

Related Resources
For users operating in China, consider using Hong Kong servers to ensure compliance and performance: