Skip to content

Commit c3aface

Browse files
authored
fix: fix coder stat mem (#8762)
- For cgroups v1 the wrong cgroup file was being read to determine max memory. This commit updates the file from '/sys/fs/cgroup/memory/memory.max_usage_in_bytes' to '/sys/fs/cgroup/memory/memory.limit_in_bytes'
1 parent 74c4553 commit c3aface

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

cli/clistat/cgroup.go

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ const (
2222
// CFS period for cgroup in MICROseconds
2323
cgroupV1CFSPeriodUs = "/sys/fs/cgroup/cpu,cpuacct/cpu.cfs_period_us"
2424
// Maximum memory usable by cgroup in bytes
25-
cgroupV1MemoryMaxUsageBytes = "/sys/fs/cgroup/memory/memory.max_usage_in_bytes"
25+
cgroupV1MemoryMaxUsageBytes = "/sys/fs/cgroup/memory/memory.limit_in_bytes"
2626
// Current memory usage of cgroup in bytes
2727
cgroupV1MemoryUsageBytes = "/sys/fs/cgroup/memory/memory.usage_in_bytes"
2828
// Other memory stats - we are interested in total_inactive_file

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy