2

As root I've create a cgroup which limits cpu and memory usage.

cgcreate -g cpu,memory:matlab_sandbox
cgset -r cpu.shares=250 matlab_sandbox
cgset -r memory.limit_in_bytes=8G matlab_sandbox

Now I'm wondering why I can only enforce the limits on my own (root) processes.

This works:

cgclassify -g cpu,memory:matlab_sandbox $(pgrep -U root matlab)

This doesn't work:

cgclassify -g cpu,memory:matlab_sandbox $(pgrep -U bob matlab)
Lugaxx
  • 675

0 Answers0