-
Notifications
You must be signed in to change notification settings - Fork 250
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Can't get the correct information from /proc/stat #628
Comments
Thank you for your report! I have tried to reproduce this on my environment with LXC and found no issues. Please, provide the following information. (from the host)
(from the container/k8s pod)
|
Hi @mihalicyn follow is the information: (from the host)ls -la /proc/self/nslrwxrwxrwx 1 root root 0 Mar 27 17:32 cgroup -> cgroup:[4026531835] cat /sys/fs/cgroup/cgroup.controllersmy cgroup version is v1 ,so i provides information about v1 versioncat /proc/cgroups mount | grep cgrouptmpfs on /sys/fs/cgroup type tmpfs (ro,nosuid,nodev,noexec,mode=755) uname -aLinux cgpcc01n010237206001.sncloud.com 4.18.0-80.11.1.el7.centos.sn11.x86_64 #1 SMP Mon Feb 24 20:34:03 CST 2020 x86_64 x86_64 x86_64 GNU/Linux (from the container/k8s pod)ls -la /proc/self/nslrwxrwxrwx 1 root root 0 Mar 27 17:37 cgroup -> cgroup:[4026531835] cat /sys/fs/cgroup/cgroup.controllersmy cgroup version is v1 ,so i provides information about v1 versioncat /proc/cgroups |
I'am also dealing with the same problem/bug. Container shows correct /proc/cpuinfo, but wrong /proc/stat. The container uses 5 CPUs. Below is the discussed info: From the container:
From the host:
|
I can get correct information from /proc/cpuinfo and /sys/devices/system/cpu/online, but can't get the correct information from /proc/stat, The information from /proc/stat is all cpus on hosts. Is there any missing configuration?
/proc/cpuinfo
/sys/devices/system/cpu/online
/proc/stat
lxcfs --version
"5.0.4"
systemctl status lxcfs
● lxcfs.service - FUSE filesystem for LXC
Loaded: loaded (/usr/lib/systemd/system/lxcfs.service; enabled; vendor preset: disabled)
Active: active (running) since Thu 2024-03-14 19:38:44 CST; 1h 18min ago
Docs: man:lxcfs(1)
Main PID: 1296 (lxcfs)
Tasks: 6
Memory: 31.6M
CGroup: /system.slice/lxcfs.service
└─1296 /usr/bin/lxcfs -l --enable-cfs --enable-pidfd /var/lib/lxc/lxcfs/
mount info
The text was updated successfully, but these errors were encountered: