In my previous articles I illustrated how to encrypt the entire operating system for Ubuntu Server and Desktop including the users home folder. In this article I am going to illustrate how to encrypt a virtual machines virtual disk in VirtualBox from Oracle.
At the time of writing this article I used VirtualBox Version 5.1.8 r111374 with the according Extension Pack. The Oracle VirtualBox Extention Pack is required for the virtual disk encryption. If you have not done so go ahead and download the Extension Pack for your version and install it.
Start your VirtualBox Manager and click on the New Icon.
Give your new VM a name and select the Type and Version of the Operating System you are going to install on it.
Then go and select how much memory you like to use in this VM
Select “Create a virtual hard disk now”
Now pick a virtual hard disk type. I will select VMDK so it is easier to import/export to VMware ESXi Servers
Here you need to select what kind of disk you like to create. If you are shy on storage space than I recommend using the “Dynamically allocated” but it comes with a price. I t will be slower than a “Fixed size” disk. On the other hand the fixed size disk required the entire allocated disk size.
Now specify the size of the disk. 8GB for this illustration is just fine.
After the VM has been created highlight the VM and select the settings button in the menu bar.
Go to General >> Encryption Tab
Check the “Enable Encryption” box and select a Encryption Cipher. I recommend AES-XTS256-Plain64 and enter a passphrase for the cipher. Make sure you make a note of it somewhere.
That is it. You can go ahead now and install you operating system on it. Your virtual disk is now encrypted and if this file finds it’s way out side your network you can sleep better knowing it is encrypted and nobody can get to the data on it.
Namaste by friends 😉