Re: [pve-devel] [PATCH container 09/20] cgroup: add get_memory_stat

2020-04-04 Thread Thomas Lamprecht
On 4/3/20 4:37 PM, w.bumil...@proxmox.com wrote: > ... > +# Parse some memory data from `memory.stat` > +sub get_memory_stat { > +my ($self) = @_; > + > +my $res = { > + mem => 0, > + swap => 0, > +}; > + > +if (cgroup_mode() == 2) { > + if (defined(my $path =

[pve-devel] applied-series: [PATCH container+pvestatd 00/20] updates for lxc4 and cgroupv2

2020-04-04 Thread Thomas Lamprecht
On 4/3/20 4:37 PM, w.bumil...@proxmox.com wrote: > From: Wolfgang Bumiller > > This is a larger patch set with the following goals: > * initial work for cgroupv2 support > * fewer hardcoded cgroup paths (required for cgroupv2 support) > * fewer patches on top of lxc > - This includes dropping

Re: [pve-devel] [PATCH container 13/20] cgroup: add change_cpu_quota, change_cpu_shares

2020-04-04 Thread Thomas Lamprecht
On 4/3/20 4:37 PM, w.bumil...@proxmox.com wrote: > ... > +# Change the cpu "shares" for a container. > +# > +# In cgroupv1 we used a value in `[0..50]` with a default of 1024. > +# > +# In cgroupv2 we do not have "shares", we have "weights" in the range > +# of `[1..1]` with a default of