Nested virtualization does not work with pve-5.4 kernel and AMD ryzen

TLTR: When you have an AMD Ryzen CPU and want to use any nested virtualization (nonfancy, just packer builds with Virtualbox) it will freeze about 5-10 seconds after starting the VM. To fix this issue, you need to upgrade your PVE kernel to 5.11.

My setup:
- Proxmox 6 latest patch version pve-manager/6.4-4/337d6701
- CPU AMD Ryzen 9 5950X 16-Core Processor
- NVMe drives / raid (if that can make any difference to this setup)

What i do:
Runing a Debian-buster VM with host type CPU, enabled nested virtualization (https://pve.proxmox.com/wiki/Nested_Virtualization).
Inside that VM I run packer based builds, more specifically
  • virtualbox 6.1 (latest)
  • packer 1.7.2 (latest)
Is used to build Debian-buster VMs. So during the build, a Debian buster VM should be provisioning via Virtualbox.

Issue:
The nested VM started by VirtualBox will randomly freeze in about 10 seconds after booting the VM prior to any installation.

Solution:
Upgrade your PVE kernel to 5.11 using

Code:
apt-get install pve-kernel-5.11

Hint: be aware, if you virtualize FreeBSD boxes, there is an issue when using cpu: host
 
Last edited:

About

The Proxmox community has been around for many years and offers help and support for Proxmox VE, Proxmox Backup Server, and Proxmox Mail Gateway.
We think our community is one of the best thanks to people like you!

Get your subscription!

The Proxmox team works very hard to make sure you are running the best software and getting stable updates and security enhancements, as well as quick enterprise support. Tens of thousands of happy customers have a Proxmox subscription. Get yours easily in our online shop.

Buy now!