Docker in LXC hangs after LXC Startup


Jul 6, 2021
Hey everyone,

First and foremost, I want to acknowledge that running Docker inside an LXC container is not recommended and not officially supported. I'm aware of this fact, but I'm hoping someone might have some insights or suggestions to offer.

The Docker setup within an LXC container does work for me, but there's a peculiar issue I'm experiencing. After starting the LXC container, all Docker commands freeze for approximately 3 to 4 minutes. Once this initial delay is over, everything works perfectly without any further problems or hang-ups.

arch: amd64

cores: 2

features: fuse=1,keyctl=1,nesting=1

hostname: unifi

memory: 5048


net0: name=eth0,bridge=vmbr0,gw=,hwaddr=FE:F1:82:E9:CD:B2,ip=,type=veth

net1: name=eth35,bridge=vmbr35,gw=,hwaddr=5A:88:39:74:EA:8E,ip=,type=veth

onboot: 0

ostype: debian

rootfs: local-zfs:subvol-118-disk-0,size=40G

swap: 512


unprivileged: 1

Your container is unprivileged.
It may be a cause for Docker freezing for a while trying to execute startup tasks that would require more privileges than the container has, before timeouting / realising it doesn't need such privileges.

You probably won't see that kind of problem if installing in a KVM host.

Best regards,

G. Delanoy


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!