Nested virtualisation support on EC2 compute optimized instances


About a couple years ago, just out of curiosity, I managed to load the KVM module and use qemu-kvm on compute optimized instances. I'm writing up about nested virtualisation on cloud VM's and I can't seem to find any documentation that says nested virtualisation is officially supported on EC2 instances.

Most EC2 instances are VMs that don’t support nested virtualization. To get access to the bare hardware, you need a metal instance type.

That's not entirely true. I've run a small VM on a c5a or similar(if my memory serves). If it doesn't say anywhere, it's probably good idea not to use it. But I'm reaching out to see if I've missed something. Compute optimized instances do have the svm flag exposed to them but no one's talking about it like other CSP's(GCP and Azure).

David T
已提問 2 個月前檢視次數 184 次
1 個回答

You're correct that AWS does not officially support nested virtualization on EC2 instances that are not of the "metal" type. However, as you've observed, it is sometimes possible to enable and use nested virtualization on certain EC2 instance types, even though it's not officially supported or documented by AWS.

The ability to use nested virtualization on non-metal instances like the c5a can vary based on the specific hardware and hypervisor configurations used by AWS, which can change over time. This is likely why there is limited discussion or documentation about it, as it's not a guaranteed or stable feature for these instance types.

If you're writing about nested virtualization on cloud VMs, it would be prudent to mention that while it is possible to enable nested virtualization on some non-metal EC2 instances, it is not officially supported by AWS and may not be reliable or available on all instance types or in all regions. Users should proceed with caution and preferably use metal instances if they require nested virtualization in a production environment.

Alternatively, you could explore options available on AWS Marketplace that provide Hyper-V Servers.

Key resources:

profile picture
已回答 2 個月前

您尚未登入。 登入 去張貼答案。