openwrt / openwrt/packages

lxc-auto: Mount /sys/fs/cgroup/systemd cause lxc cgroup2 limit not apply

Open
#27,755 1 comment 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

bug
Dominant language
Makefile
Stars
4.6k
Forks
4k
Avg merge
3d 12h
Merged PRs (30d)
134

Description

Package Name

lxc-auto

Maintainer

Marko Ratkaj markoratkaj@gmail.com

OpenWrt Version

ALL

OpenWrt Target/Subtarget

ALL

Steps to Reproduce

Add lxc.cgroup2.memory.max: 1G to config and restart container.
Limits will not be apply.

Remove boot section mount systemd, limit will be apply.

Actual Behaviour

/sys/fs/cgroup/lxc.payload.<name>/memory.max is max not 1G (in bytes).

Confirmation Checklist

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by locating the lxc-auto package's boot section that mounts /sys/fs/cgroup/systemd and reproduce the issue with lxc.cgroup2.memory.max: 1G. Compare the cgroup2 memory.max value before and after that mount is removed. Done means the configured 1G limit is applied after restarting the container while the boot mount remains.

Written by the indexing model from the issue text.

Assessment

Tech stack
linux
Domain
operating-systems
Issue type
Bug
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.