Memory Hotplug Breaking threads-max in VM

mike p

New Member
Dec 13, 2020
8
1
3
27
Hi All.

We Have a Debian 10 installation with 8GiB of RAM. Memory Hot-plugging is enabled as explained in wiki (Both udev rules and kernel parameter are set). The Server is Used as an Ingress in Kubernetes cluster and uses nginx. Under High Load, we discovered nginx is failing to fork new threads for new connections due to reaching max allowed threads (Our Post regarding the threads-max). Digging deeper, we found that while booting the kernel is discovering only 1GiB of Memory and therefor setting a very Low amount of max allowed threads (7055):

Bash:
root@deb:~>>> dmesg | grep Memory:

[    0.282335] Memory: 903820K/1048032K available (10252K kernel code, 1242K rwdata, 3328K rodata, 1600K init, 2260K bss, 144212K reserved, 0K cma-reserved)
root@deb:~>>> cat /proc/sys/kernel/threads-max
7055

However the Memory is recognized completely by VM when booted and Hot-Plugging is working seamlessly.

Disabling the Memory Hotplug Solves the problem all together:

Bash:
root@deb:~>>> dmesg | grep Memory:
[    1.156223] Memory: 8129300K/8388064K available (10252K kernel code, 1242K rwdata, 3328K rodata, 1600K init, 2260K bss, 258764K reserved, 0K cma-reserved)

root@deb:~>>> cat /proc/sys/kernel/threads-max
63510

Any Help is super Welcomed;)
 
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 your own in 60 seconds.

Buy now!