Comments (6)
Wait, you said you're loading and calling stat on the cgroup2 manager, but the path it's trying to open is a cgroup1 path which is odd. The cgroup 2 codepath doesn't error out on the only instance of trying to read the equivalent file in the cgroup:
Line 606 in fb1932a
from cgroups.
oh. i see. this is probably my mistake then. It seems the underlying nodes support unified cgroups but within the container is only supporting legacy? that must have confused me.
I am probably then just doing cgroup1 path wrong? I will debug and close the issue in a bit if im just being stupid. really appreciate the help!!
from cgroups.
No worries, not stupid at all. I'm curious to know the outcome!
from cgroups.
No worries, not stupid at all. I'm curious to know the outcome!
-
so you're right, it's loading the cgroup1 path, not cgroup2. confirming that the error is
open /sys/fs/cgroup/rdma/rdma.current: no such file or directory
and that it's coming from the cgroup1 path -
the kernel supports cgroup2 filesystem but cgroup2 paths are not enabled in the containers and they are using legacy. I'm just confirming this through seeing which filepaths exists in the container.
so now i exec into the container which shows that file of course not existing.
/sys/fs/cgroup # ls /sys/fs/cgroup/rdma
cgroup.clone_children cgroup.sane_behavior notify_on_release tasks
cgroup.procs kubepods release_agent
I see a large amount of info under rdma/kubepods/... but these seem to be for other pods? this is the output for tree /sys/fs/cgroup
https://gist.github.com/elee1766/eb9719cfc521b5c4f9bd34de2da090f9
for reference, i am doing the following to try to load the cgroup:
path := cgroup1.NestedPath("")
if pid := os.Getpid(); pid == 1 {
path = cgroup1.RootPath
}
cgroup, err := cgroup1.Load(path)
so i guess im still confused. it looks like all the rdma information are under this "rdma/kubepods" path, which i believe is specific to kubernetes. am i using the wrong path here? i dont actually need the RDMA statistics to do what i need to do i think, so maybe i should just try extracting the memory info with another method?
from cgroups.
Can this issue be closed? Doesn't like like an issue with the package.
from cgroups.
yuh
from cgroups.
Related Issues (20)
- Question: What is the equivalent of writing input into `devices.allow`? HOT 1
- MemorySwapMax is never set on systemd? HOT 1
- Support OomGroupKill in cgroup2 memory events stats
- NewSystemd must not ignore UnitExists HOT 3
- Reduce allocations for Stat in cg2 HOT 2
- Not compatible with linux6 HOT 4
- Stat in cpu and cpuacct in cgroupv1 may access nil pointer HOT 1
- Add a mechanism to disable the default cpuset controller in v2 HOT 1
- Calling cgroup V1 New function fails for kernels that don't have swap enabled
- Restriction does not work HOT 1
- Unable to use v3.0.1 release HOT 1
- Running cgroups stats functionality within k8s HOT 1
- Containerd fails with error: strconv.ParseUint: parsing "(unknown)": invalid syntax
- net_cls cgroup mounting HOT 1
- oom killer cannot be re-enabled HOT 2
- ToResources method has a bug in the conversion of swap memory limits. HOT 3
- The container cgroup path of pod is not loaded properly HOT 1
- Release 3.0.3 HOT 1
- We have a misspelling WithHiearchy option in cgroup1, spreading typos to downstream
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from cgroups.