Re: [systemd-devel] Automatically moving forked processes in a different cgroup based on children's UID

2022-01-09 Thread Mantas Mikulėnas
On Fri, Jan 7, 2022 at 4:11 PM Michal Koutný wrote: > More viable way seems to me to modify the apache2-mpm-itk to put > children into respective cgroups. > I'm assuming that the resource usage primarily comes from something like webapps running via mod_php, rather than Apache itself, in which c

Re: [systemd-devel] Automatically moving forked processes in a different cgroup based on children's UID

2022-01-07 Thread Michal Koutný
Hello Wadih. On Sat, Jan 01, 2022 at 04:41:12PM -0500, Wadih wrote: > Is there a way to automatically classify child processes of a process > in a different cgroup than the spawning process with systemd based on > the children's new UID? I know apache2-mpm-itk calls setuid() on its > children, so

Re: [systemd-devel] Automatically moving forked processes in a different cgroup based on children's UID

2022-01-03 Thread Benjamin Berg
Hi, systemd will not help you with managing the cgroup sub-hierarchy underneath the daemon. I suppose the most generic solution would be something like cgrulesengd for cgroup v2. No idea if something like that exists. I assume you have had a look at https://systemd.io/CGROUP_DELEGATION/#three-s

[systemd-devel] Automatically moving forked processes in a different cgroup based on children's UID

2022-01-01 Thread Wadih
Hi, I've been using apache2-mpm-itk with cgrulesengd in cgroupv1 to automatically classify the child processes that apache2-mpm-itk spawns when servicing web requests for different vhosts for about 3 years, and it's been working great, when a vhost starts using up too much CPU/RAM, oom killer take