-
Notifications
You must be signed in to change notification settings - Fork 254
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Encryption failing on Ubuntu 16.04 #334
Comments
Similar issue here running encryption of OS + Data via Powershell on Ubuntu 16.04: 2017/03/09 18:46:02 [Microsoft.Azure.Security.AzureDiskEncryptionForLinux-1.0]: 1447: [Info] Command /bin/mount /dev/sdc1 /mnt/azure_bek_disk -t vfat failed with return code 32 |
Is this getting worked on? |
Finally I was able to make it running. Issue was with amount of memory my
machine had. I had to increase it to to at least 4GB, ideally to 7GB. It is
actually mentioned in some documentation about Azure Linux Encryption.
…On Mon, Apr 3, 2017 at 3:20 PM, 24X7 ***@***.***> wrote:
Is this getting worked on?
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#334 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AKavsWyKbACU0Idy5OVAmr576lGUoug3ks5rsPIjgaJpZM4L16Z3>
.
|
I tried increasing the memory, and that did not help. I'm getting the same similar error when I run it from Powershell or Azure CLI. Could it be related? Command
Error VM has reported a failure when processing extension 'AzureDiskEncryptionForLinux'. Error message: "Failed to enable the extension with error: 'NoneType' object has no attribute 'getheader', stack trace: Traceback (most recent call last):
File "/var/lib/waagent/Microsoft.Azure.Security.AzureDiskEncryptionForLinux-0.1.0.999297/main/handle.py", line 671, in enable_encryption
DiskEncryptionKeyFileName=extension_parameter.DiskEncryptionKeyFileName)
File "/var/lib/waagent/Microsoft.Azure.Security.AzureDiskEncryptionForLinux-0.1.0.999297/main/KeyVaultUtil.py", line 63, in create_kek_secret
bearerHeader = result.getheader("www-authenticate")
AttributeError: 'NoneType' object has no attribute 'getheader' Updated to add: This may have been an issue with my Key Vault settings and/or SPN. I've opened a new issue for my error. |
I'm using PowerShell, the same issue Set-AzureRmVMDiskEncryptionExtension : Long running operation failed with status 'Failed'. |
It's an exception in HTTPUtil.Call method for KeyVaultURL. Tried it manually from inside VM, it works fine |
Same issue here on a VM with 14Gb of RAM, tried several time without success [AzureDiskEncryption] 2943: [Info] Attempt #11 to unmount /oldroot I'm mounting the data disk in /opt instead of /mnt via cloud-init |
I did encrypt two different vms, and for both I am unable to get them up again. Checking the log, it appears to end in the error Any ideas? |
I installed DM-Crypt, 2 hours and problem is solved
…On Fri, Jun 30, 2017 at 11:15 AM, Philipp Singer ***@***.***> wrote:
I did encrypt two different vms, and for both I am unable to get them up
again.
Checking the log, it appears to end in the error '''umount: /oldroot/mnt:
not mounted'''.
Any ideas?
—
You are receiving this because you commented.
Reply to this email directly, view it on GitHub
<#334 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AFtSwugB7Z4T0089xnGiIMlKRekR834Wks5sJK6agaJpZM4L16Z3>
.
|
@vsukhin Can you please elaborate? |
Hi, |
Basic metric is already off :/ |
I simple decided to do it using Linux tool without Azure encryption
…On Fri, Jun 30, 2017 at 11:37 AM, Philipp Singer ***@***.***> wrote:
@vsukhin <https://github.com/vsukhin> Can you please elaborate?
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#334 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AFtSwsVBpluCDS4mEzbJ3sLYhNBH-S3Aks5sJLO7gaJpZM4L16Z3>
.
|
That's not really a solution to me because I can't even remove the encryption. |
Sorry, then. I did it because, I could not wait for response in next few
months (
…On Fri, Jun 30, 2017 at 4:05 PM, Philipp Singer ***@***.***> wrote:
That's not really a solution to me because I can't even remove the
encryption.
—
You are receiving this because you were mentioned.
Reply to this email directly, view it on GitHub
<#334 (comment)>,
or mute the thread
<https://github.com/notifications/unsubscribe-auth/AFtSwqx9-KQlif9surpMrV94OCh0g3Oiks5sJPKUgaJpZM4L16Z3>
.
|
It seems to work quite well with vanilla Ubuntu. |
It doesn't seem like KEK is implemented, based on the feedback I've gotten from Azure support, and the permissions on the keyfile are open to everyone. I really recommend not using this extension. |
This initial issue appears to have been due to incorrect key vault settings, or perhaps an incorrect format being passed through the ARM template. If this occurred then it would certainly surface in the form the extension error logs provided. With respect to the other issues brought up here, they seem to be similar end result (unfriendly and unhelpful error messages from the extension) but different root causes, so I will start chipping away on separate threads for those. In the hopes that it will help shed more light on how to avoid this type of error in the future, here are some links on setting up key vault, the recommended workflow, and common troubleshooting tips: Powershell script demonstrating how to set up the necessary key vault prerequisites: Recommended Workflow: Troubleshooting Guide: |
This problem appears to have been caused by low memory. I had the minimum amount of RAM required (7gb) on the VM but still got the /oldroot errors. Try stopping the Elasticsearch service on the ES Data Node before running encryption on the OS and data disks. It worked for me. Example-- |
Thanks for closing the loop on this.. I suspect that even with total RAM of 7GB if disk layout is different than the gallery image or if available memory is low even though total memory is high due to other active memory use this problem can still be triggered during OS encryption stage as well. |
I'm building Azure Disk Encryption into an ARM template and have configured encryption of both OS disk and attached data disks within the template, to happen after VM provisioning and software installation using the newer Script VM Extension for Linux 2.0 used in Quickstart templates (Azure/azure-quickstart-templates#2340).
The template deployment succeeds and reports successful, but the encryption operation is failing to encrypt the osDisk and the data disks are not encrypted (I guess the process fails on the osDisk and doesn't get to the data disks).
Here's a snippet of the extension log at
/var/log/azure/Microsoft.Azure.Security.AzureDiskEncryptionForLinux/0.1.0.999283/extension.log
(I can provide the full one if needed)Checking the encryption status through the Azure PowerShell SDK correlates with the problem in the log:
My understanding is that it is possible to encrypt the disks on a running VM based on the examples in the quickstart templates. The data disks are RAID0ed as part of the script that installs the software.
Should the encryption happen before the VM Script extension runs and software is deployed, or if it can happen after this, is this a bug in the encryption process?
The text was updated successfully, but these errors were encountered: