Technical Anshu
Tutorials Blog
📦 Nested Containers

LXC Containers Inside Nested Proxmox Why They Run Better Than VMs

Here is the nested lab's best-kept secret: the guests that run fastest inside a Proxmox that is itself a VM are not VMs at all. Containers bypass the whole virtualization problem — this page explains why, and what they cannot do.

✍️ Technical Anshu🖥️ ESXi + Proxmox⏱️ 7 minute read
🎥 Watch the video for the nested Proxmox build — then fill it with containers

Nested VMs pay a double tax because every instruction crosses two hypervisors. LXC containers never make that journey. A container is not a small VM — it is a group of ordinary processes on the Proxmox host's own Linux kernel, fenced off by namespaces and resource limits. In a nested setup, that architectural difference turns into the single biggest performance advantage available, and it even works when nested KVM is broken. This page explains the why, the best uses, and the limits you should know before betting your lab on containers.

Two kinds of guest inside nested Proxmox — the path each one takes (summary panel)
LXC container
Needs KVM or VT-x at allNO
Hypervisor layers crossedZERO EXTRA
KVM virtual machine
Needs KVM or VT-x at allYES
Hypervisor layers crossedTWO
A container's processes run on the Proxmox kernel directly. Proxmox being nested costs them almost nothing — the kernel itself is what is virtualized once, for everything inside it.
👆 One layer for the platform, zero extra layers for its containers. That asymmetry is why containers feel normal in a nested lab.
1

Containers Do Not Need the Virtualization Hardware at All

KVM exists to run a second kernel. A container runs no second kernel — it shares the Proxmox host's kernel and is separated from other containers by namespaces (its own view of processes, network and files) and cgroups (its own CPU and memory limits). The practical consequence in a nest is delightful: containers start and run even if the ESXi expose setting is missing and /dev/kvm does not exist. If you built the nested lab and your VMs refuse to start, containers are how you still get a working lab while you fix the settings.

2

Near-Normal Speed, and Why

Follow a request: a containerised DNS server answering a query executes on the Proxmox kernel, which is itself a process under ESXi — one virtualization layer total, the same one every ESXi VM lives with. A nested KVM guest answering the same query crosses Proxmox's KVM and then ESXi's. That is the whole explanation for the observed difference: containers in a nest perform like ordinary VMs on ESXi, while nested KVM guests perform like what they are — VMs inside a VM. RAM overhead tells the same story; a container needs no memory reserved for a guest kernel and firmware.

3

The Perfect Jobs for Nested Containers

Light infrastructure services are the sweet spot: DNS and ad-blocking, a monitoring stack, a wiki, a reverse proxy, a test web or file server, a VPN endpoint, a home automation broker. These are exactly the services a lab exists to host, they are all Linux-native, and they are bursty rather than heavy — the workload profile nesting taxes least. A nested Proxmox filled with a dozen containers is a genuinely useful lab; the same host filled with a dozen Windows VMs is a slideshow.

4

The Honest Limits of the Container Bargain

  1. Linux only. A container shares a Linux kernel, so there is no Windows, no BSD, no other operating system — ever
  2. Thinner isolation. Containers are separated by kernel features, not by a hypervisor boundary; a VM is the stronger wall when you genuinely distrust the workload
  3. Kernel sharing cuts both ways. You cannot run a different kernel version, load arbitrary kernel modules, or reboot the "guest" independently
  4. Some features need privilege. Certain low-level tricks require a privileged container, which loosens the isolation further — know what you are accepting when you tick it
5

When You Still Need the VM

Reach for a nested VM when the job is the operating system itself: testing a Windows install, rehearsing a Proxmox-to-Proxmox migration of real VMs, practising anything kernel-level, or isolating something untrusted behind a hypervisor boundary. Accept the tax for those, deliberately and temporarily. The mature nested lab is a mix: containers for the services that run all day, VMs spun up only for the lessons that need them. That mix is how one modest ESXi host ends up teaching an entire virtualization curriculum.

🎥 Watch the Full Video

Watch the nested setup video, bring Proxmox up inside ESXi, and try a container first — it is the fastest win in the whole lab.

▶️ Watch Full Video
❓ Frequently Asked Questions

Will containers work even if I never fix the KVM settings?

Yes. LXC containers do not use KVM and do not need the virtualization extensions, so they run in a nested Proxmox even when /dev/kvm is missing and VMs refuse to start. That makes containers a good way to keep a lab useful while you troubleshoot the ESXi expose setting — though fixing it is still worth the ten minutes it takes.

Can I run Docker inside an LXC container in nested Proxmox?

It can be done — Proxmox offers a nesting feature flag for containers that Docker needs — but you are stacking a third runtime layer and accepting extra quirks and weaker isolation. For a learning lab it is a fair experiment. For anything you rely on, running Docker in a small VM, or directly as its own guest, is the cleaner answer. Honest labs know which corners they cut.

Are containers safe enough for services exposed to my network?

For ordinary home and office lab services, unprivileged containers are a reasonable, widely used choice. The isolation is kernel-based rather than hypervisor-based, so for a workload you actively distrust — random downloads, untrusted code — a VM is the stronger container to put it in. Match the wall to the threat: services you run yourself, containers; things you do not trust, a VM.

This guide is based on the Technical Anshu Proxmox nested VM setup video • Stuck on a step? Ask in the video comments — you will get a reply 🙏