Enabling "IO Thread" equivalent on LXC

btyeung

New Member
Oct 15, 2020
11
0
1
44
Hi,

Tried searching for the above but no hits so figure I'd ask. Please point me to an article I may have missed if its been answered before. The issue I'm trying to solve is high IO delay when moving large volumes (GB range) of data on a LXC ubuntu container. I previously had this issue on VM's but appears to have been solved by activating IO Thread. Assuming that this would be a fix for this performance degradation I'm seeing on LXC, is there an equivalent option or is there a better solution to this issue.

Please let me know if I'm missing important details.

BY
 
Hi.

There's no such concept of IO-Threads for Linux Containers (LXC), all its processes run directly as process/thread at the host level already. QEMU added IO-Threads as else most IO would happen in the main thread, and thus may hang other things running also in the main thread (i.e., the whole VM). With LXC the thread doing IO is by design already, well its own thread on the system...

If you want to reduce IO delay for other processes and users on the system then IO scheduler could be used.

The better solution would be IO limits in the Control-group (cgroup) controller for each Container. But we can only really add support for that with the next major Proxmox VE release (7.0) at the earliest, as then we have recent enough base support in kernel, systemd, ... to actually use cgroupv2 where the IO controller actually can limit IO in a meaningful way.
See: https://andrestc.com/post/cgroups-io/ for some more technical details.

Proxmox VE has basic cgroupv2 support already now (since PVE 6.2, IIRC), but it can get a bit of an involved operation to switch, and especially older Container distro version may not work wit v2.
 

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!