Atoptool / atop

System and process monitor for Linux
GNU General Public License v2.0
792 stars 109 forks source link

Broken atop with a VM on virtuozzo #310

Closed gitranjithkk closed 1 month ago

gitranjithkk commented 1 month ago

Node OS:Virtuozzo Linux release 7.9 Node Kernel: 3.10.0-1160.105.1.vz7.220.3 VM OS:CloudLinux release 8.9 (Anatoly Levchenko) VM kernel:4.18.0 We are running imunify 360 as well in these VM. Atop installed: atop-2.9.0-1.x86_64 Atop output: `[root@server:/]$ atop

threads (6) < #procs (134)

`


execve("/bin/atop", ["atop"], 0x7fff79d72620 /* 37 vars */) = 0
brk(NULL)                               = 0x231d000
arch_prctl(0x3001 /* ARCH_??? */, 0x7ffec8726aa0) = -1 EINVAL (Invalid argument)
access("/etc/ld.so.preload", R_OK)      = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/etc/ld.so.cache", O_RDONLY|O_CLOEXEC) = 3
fstat(3, {st_mode=S_IFREG|0644, st_size=43287, ...}) = 0
mmap(NULL, 43287, PROT_READ, MAP_PRIVATE, 3, 0) = 0x7fce1a1a8000
close(3)                                = 0
openat(AT_FDCWD, "/lib64/libncursesw.so.6", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\0\304\0\0\0\0\0\0"..., 832) = 832
lseek(3, 242288, SEEK_SET)              = 242288
read(3, "\4\0\0\0\20\0\0\0\5\0\0\0GNU\0\2\0\0\300\4\0\0\0\3\0\0\0\0\0\0\0", 32) = 32
fstat(3, {st_mode=S_IFREG|0755, st_size=259192, ...}) = 0
mmap(NULL, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7fce1a1a6000
lseek(3, 242288, SEEK_SET)              = 242288
read(3, "\4\0\0\0\20\0\0\0\5\0\0\0GNU\0\2\0\0\300\4\0\0\0\3\0\0\0\0\0\0\0", 32) = 32
mmap(NULL, 2347448, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7fce19d47000
mprotect(0x7fce19d83000, 2097152, PROT_NONE) = 0
mmap(0x7fce19f83000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x3c000) = 0x7fce19f83000
close(3)                                = 0
openat(AT_FDCWD, "/lib64/libtinfo.so.6", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0000\351\0\0\0\0\0\0"..., 832) = 832
lseek(3, 165144, SEEK_SET)              = 165144
read(3, "\4\0\0\0\20\0\0\0\5\0\0\0GNU\0\2\0\0\300\4\0\0\0\3\0\0\0\0\0\0\0", 32) = 32
fstat(3, {st_mode=S_IFREG|0755, st_size=187552, ...}) = 0
lseek(3, 165144, SEEK_SET)              = 165144
read(3, "\4\0\0\0\20\0\0\0\5\0\0\0GNU\0\2\0\0\300\4\0\0\0\3\0\0\0\0\0\0\0", 32) = 32
mmap(NULL, 2279808, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7fce19b1a000
mprotect(0x7fce19b43000, 2093056, PROT_NONE) = 0
mmap(0x7fce19d42000, 20480, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x28000) = 0x7fce19d42000
close(3)                                = 0
openat(AT_FDCWD, "/lib64/libz.so.1", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0@'\0\0\0\0\0\0"..., 832) = 832
lseek(3, 88944, SEEK_SET)               = 88944
read(3, "\4\0\0\0\20\0\0\0\5\0\0\0GNU\0\2\0\0\300\4\0\0\0\3\0\0\0\0\0\0\0", 32) = 32
fstat(3, {st_mode=S_IFREG|0755, st_size=99640, ...}) = 0
lseek(3, 88944, SEEK_SET)               = 88944
read(3, "\4\0\0\0\20\0\0\0\5\0\0\0GNU\0\2\0\0\300\4\0\0\0\3\0\0\0\0\0\0\0", 32) = 32
mmap(NULL, 2191368, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7fce19902000
mprotect(0x7fce19918000, 2097152, PROT_NONE) = 0
mmap(0x7fce19b18000, 4096, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x16000) = 0x7fce19b18000
mmap(0x7fce19b19000, 8, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x7fce19b19000
close(3)                                = 0
openat(AT_FDCWD, "/lib64/libm.so.6", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\2\1\1\3\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0 \305\0\0\0\0\0\0"..., 832) = 832
fstat(3, {st_mode=S_IFREG|0755, st_size=1598848, ...}) = 0
mmap(NULL, 3674432, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7fce19580000
mprotect(0x7fce19700000, 2097152, PROT_NONE) = 0
mmap(0x7fce19900000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x180000) = 0x7fce19900000
close(3)                                = 0
openat(AT_FDCWD, "/lib64/librt.so.1", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0000$\0\0\0\0\0\0"..., 832) = 832
fstat(3, {st_mode=S_IFREG|0755, st_size=42744, ...}) = 0
mmap(NULL, 2128832, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7fce19378000
mprotect(0x7fce1937f000, 2093056, PROT_NONE) = 0
mmap(0x7fce1957e000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x6000) = 0x7fce1957e000
close(3)                                = 0
openat(AT_FDCWD, "/lib64/libc.so.6", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\2\1\1\3\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0`\256\3\0\0\0\0\0"..., 832) = 832
fstat(3, {st_mode=S_IFREG|0755, st_size=2089936, ...}) = 0
lseek(3, 808, SEEK_SET)                 = 808
read(3, "\4\0\0\0\20\0\0\0\5\0\0\0GNU\0\2\0\0\300\4\0\0\0\3\0\0\0\0\0\0\0", 32) = 32
mmap(NULL, 3950816, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7fce18fb3000
mprotect(0x7fce1916f000, 2093056, PROT_NONE) = 0
mmap(0x7fce1936e000, 24576, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x1bb000) = 0x7fce1936e000
mmap(0x7fce19374000, 14560, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x7fce19374000
close(3)                                = 0
openat(AT_FDCWD, "/lib64/libdl.so.2", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0p\16\0\0\0\0\0\0"..., 832) = 832
fstat(3, {st_mode=S_IFREG|0755, st_size=19128, ...}) = 0
mmap(NULL, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7fce1a1a4000
mmap(NULL, 2109600, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7fce18daf000
mprotect(0x7fce18db2000, 2093056, PROT_NONE) = 0
mmap(0x7fce18fb1000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x2000) = 0x7fce18fb1000
close(3)                                = 0
openat(AT_FDCWD, "/lib64/libpthread.so.0", O_RDONLY|O_CLOEXEC) = 3
read(3, "\177ELF\2\1\1\0\0\0\0\0\0\0\0\0\3\0>\0\1\0\0\0\360n\0\0\0\0\0\0"..., 832) = 832
fstat(3, {st_mode=S_IFREG|0755, st_size=149976, ...}) = 0
mmap(NULL, 2225344, PROT_READ|PROT_EXEC, MAP_PRIVATE|MAP_DENYWRITE, 3, 0) = 0x7fce18b8f000
mprotect(0x7fce18baa000, 2093056, PROT_NONE) = 0
mmap(0x7fce18da9000, 8192, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_DENYWRITE, 3, 0x1a000) = 0x7fce18da9000
mmap(0x7fce18dab000, 13504, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_FIXED|MAP_ANONYMOUS, -1, 0) = 0x7fce18dab000
close(3)                                = 0
mmap(NULL, 12288, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7fce1a1a1000
arch_prctl(ARCH_SET_FS, 0x7fce1a1a1740) = 0
mprotect(0x7fce1936e000, 16384, PROT_READ) = 0
mprotect(0x7fce18da9000, 4096, PROT_READ) = 0
mprotect(0x7fce18fb1000, 4096, PROT_READ) = 0
mprotect(0x7fce1957e000, 4096, PROT_READ) = 0
mprotect(0x7fce19900000, 4096, PROT_READ) = 0
mprotect(0x7fce19b18000, 4096, PROT_READ) = 0
mprotect(0x7fce19d42000, 16384, PROT_READ) = 0
mprotect(0x7fce19f83000, 4096, PROT_READ) = 0
mprotect(0x646000, 4096, PROT_READ)     = 0
mprotect(0x7fce1a1b3000, 4096, PROT_READ) = 0
munmap(0x7fce1a1a8000, 43287)           = 0
set_tid_address(0x7fce1a1a1a10)         = 3448042
set_robust_list(0x7fce1a1a1a20, 24)     = 0
rt_sigaction(SIGRTMIN, {sa_handler=0x7fce18b95970, sa_mask=[], sa_flags=SA_RESTORER|SA_SIGINFO, sa_restorer=0x7fce18ba1cf0}, NULL, 8) = 0
rt_sigaction(SIGRT_1, {sa_handler=0x7fce18b95a00, sa_mask=[], sa_flags=SA_RESTORER|SA_RESTART|SA_SIGINFO, sa_restorer=0x7fce18ba1cf0}, NULL, 8) = 0
rt_sigprocmask(SIG_UNBLOCK, [RTMIN RT_1], NULL, 8) = 0
prlimit64(0, RLIMIT_STACK, NULL, {rlim_cur=8192*1024, rlim_max=RLIM64_INFINITY}) = 0
getuid()                                = 0
setresuid(-1, 0, -1)                    = 0
access("/etc/atoprc", R_OK)             = -1 ENOENT (No such file or directory)
access("/root/.atoprc", R_OK)           = 0
getrandom("\xb1\xde\x41\xff\xa4\x5f\x38\x7a", 8, GRND_NONBLOCK) = 8
brk(NULL)                               = 0x231d000
brk(0x233e000)                          = 0x233e000
brk(NULL)                               = 0x233e000
openat(AT_FDCWD, "/root/.atoprc", O_RDONLY) = 3
fstat(3, {st_mode=S_IFREG|0600, st_size=131, ...}) = 0
read(3, "flags         Al\ninterval      5"..., 4096) = 131
read(3, "", 4096)                       = 0
close(3)                                = 0
uname({sysname="Linux", nodename="server.heiexpo.com", ...}) = 0
openat(AT_FDCWD, "/proc/sys/kernel/pid_max", O_RDONLY) = 3
fstat(3, {st_mode=S_IFREG|0644, st_size=0, ...}) = 0
read(3, "4194304\n", 1024)              = 8
close(3)                                = 0
clone(child_stack=NULL, flags=CLONE_CHILD_CLEARTID|CLONE_CHILD_SETTID|SIGCHLD, child_tidptr=0x7fce1a1a1a10) = 3448043
openat(AT_FDCWD, "/proc/3448043/stat", O_RDONLY) = 3
fstat(3, {st_mode=S_IFREG|0444, st_size=0, ...}) = 0
read(3, "3448043 (atop) R 3448042 3448039"..., 1024) = 444
close(3)                                = 0
kill(3448043, SIGKILL)                  = 0
wait4(-1, NULL, 0, NULL)                = 3448043
--- SIGCHLD {si_signo=SIGCHLD, si_code=CLD_KILLED, si_pid=3448043, si_uid=0, si_status=SIGKILL, si_utime=0, si_stime=0} ---
rt_sigaction(SIGHUP, {sa_handler=0x405d20, sa_mask=[HUP], sa_flags=SA_RESTORER|SA_RESTART, sa_restorer=0x7fce19001b50}, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=0}, 8) = 0
rt_sigaction(SIGTERM, {sa_handler=0x405d20, sa_mask=[TERM], sa_flags=SA_RESTORER|SA_RESTART, sa_restorer=0x7fce19001b50}, {sa_handler=SIG_DFL, sa_mask=[], sa_flags=0}, 8) = 0
setresuid(-1, 0, -1)                    = 0
prlimit64(0, RLIMIT_MEMLOCK, {rlim_cur=RLIM64_INFINITY, rlim_max=RLIM64_INFINITY}, NULL) = 0
mlockall(MCL_CURRENT|MCL_FUTURE)        = 0
getpriority(PRIO_PROCESS, 0)            = 20
setpriority(PRIO_PROCESS, 0, -20)       = -1 EACCES (Permission denied)
openat(AT_FDCWD, "/proc/self/oom_score_adj", O_RDWR) = 3
write(3, "-1000", 5)                    = 5
close(3)                                = 0
openat(AT_FDCWD, "/proc/net/dev", O_RDONLY) = 3
fstat(3, {st_mode=S_IFREG|0444, st_size=0, ...}) = 0
read(3, "Inter-|   Receive               "..., 1024) = 459
read(3, "", 1024)                       = 0
close(3)                                = 0
openat(AT_FDCWD, "/sys/devices/virtual/net", O_RDONLY|O_NONBLOCK|O_CLOEXEC|O_DIRECTORY) = 3
fstat(3, {st_mode=S_IFDIR|0755, st_size=0, ...}) = 0
getdents64(3, 0x231d950 /* 4 entries */, 32768) = 104
getdents64(3, 0x231d950 /* 0 entries */, 32768) = 0
close(3)                                = 0
socket(AF_INET, SOCK_RAW, IPPROTO_RAW)  = 3
getuid()                                = 0
setresuid(-1, 0, -1)                    = 0
mmap(NULL, 1024000, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7fce1a0a7000
mmap(NULL, 1024000, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7fce18a95000
mmap(NULL, 1024000, PROT_READ|PROT_WRITE, MAP_PRIVATE|MAP_ANONYMOUS, -1, 0) = 0x7fce1899b000
rt_sigaction(SIGUSR1, {sa_handler=0x404550, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7fce19001b50}, NULL, 8) = 0
rt_sigaction(SIGUSR2, {sa_handler=0x404560, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7fce19001b50}, NULL, 8) = 0
rt_sigaction(SIGALRM, {sa_handler=0x4045c0, sa_mask=[], sa_flags=SA_RESTORER, sa_restorer=0x7fce19001b50}, NULL, 8) = 0
alarm(5)                                = 0
socket(AF_INET, SOCK_STREAM, IPPROTO_IP) = 4
connect(4, {sa_family=AF_INET, sin_port=htons(59123), sin_addr=inet_addr("127.0.0.1")}, 16) = -1 ECONNREFUSED (Connection refused)
close(4)                                = 0
getcwd("/", 1024)                       = 2
chdir("/proc")                          = 0
openat(AT_FDCWD, "stat", O_RDONLY)      = 4
fstat(4, {st_mode=S_IFREG|0444, st_size=0, ...}) = 0
read(4, "cpu  8611067 152459 4173287 1419"..., 1024) = 231
read(4, "", 1024)                       = 0
close(4)                                = 0
openat(AT_FDCWD, "loadavg", O_RDONLY)   = 4
fstat(4, {st_mode=S_IFREG|0444, st_size=0, ...}) = 0
read(4, "0.05 0.15 0.28 2/7 3448043\n", 1024) = 27
close(4)                                = 0
openat(AT_FDCWD, "/sys/devices/system/cpu/cpu0/cpufreq/stats/time_in_state", O_RDONLY) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/sys/devices/system/cpu/cpu0/cpufreq/cpuinfo_max_freq", O_RDONLY) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/sys/devices/system/cpu/cpu0/cpufreq/scaling_cur_freq", O_RDONLY) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/sys/devices/system/cpu/cpu1/cpufreq/stats/time_in_state", O_RDONLY) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/sys/devices/system/cpu/cpu1/cpufreq/cpuinfo_max_freq", O_RDONLY) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/sys/devices/system/cpu/cpu1/cpufreq/scaling_cur_freq", O_RDONLY) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "cpuinfo", O_RDONLY)   = 4
fstat(4, {st_mode=S_IFREG|0444, st_size=0, ...}) = 0
read(4, "processor\t: 0\nvendor_id\t: Genuin"..., 1024) = 1024
read(4, "m_llc cqm_occup_llc cqm_mbm_tota"..., 1024) = 1024
read(4, "m abm 3dnowprefetch epb cat_l3 c"..., 1024) = 480
read(4, "", 1024)                       = 0
close(4)                                = 0
openat(AT_FDCWD, "vmstat", O_RDONLY)    = 4
fstat(4, {st_mode=S_IFREG|0444, st_size=0, ...}) = 0
read(4, "nr_free_pages 47265\nnr_alloc_bat"..., 1024) = 1024
read(4, "apd_dma 0\npgsteal_kswapd_dma32 0"..., 1024) = 1024
read(4, "0\nunevictable_pgs_cleared 0\nunev"..., 1024) = 284
read(4, "", 1024)                       = 0
close(4)                                = 0
openat(AT_FDCWD, "meminfo", O_RDONLY)   = 4
fstat(4, {st_mode=S_IFREG|0444, st_size=0, ...}) = 0
read(4, "MemTotal:        4194304 kB\nMemF"..., 1024) = 616
read(4, "", 1024)                       = 0
close(4)                                = 0
openat(AT_FDCWD, "/sys/kernel/debug/vmmemctl", O_RDONLY) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/proc/vmmemctl", O_RDONLY) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "spl/kstat/zfs/arcstats", O_RDONLY) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/sys/devices/system/node", O_RDONLY|O_NONBLOCK|O_CLOEXEC|O_DIRECTORY) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "net/dev", O_RDONLY)   = 4
fstat(4, {st_mode=S_IFREG|0444, st_size=0, ...}) = 0
read(4, "Inter-|   Receive               "..., 1024) = 459
read(4, "", 1024)                       = 0
close(4)                                = 0
openat(AT_FDCWD, "net/snmp", O_RDONLY)  = 4
fstat(4, {st_mode=S_IFREG|0444, st_size=0, ...}) = 0
read(4, "Ip: Forwarding DefaultTTL InRece"..., 1024) = 1024
read(4, "6 12008217 18201362 854436 380 4"..., 1024) = 272
read(4, "", 1024)                       = 0
close(4)                                = 0
openat(AT_FDCWD, "net/snmp6", O_RDONLY) = 4
fstat(4, {st_mode=S_IFREG|0444, st_size=0, ...}) = 0
read(4, "Ip6InReceives                   "..., 1024) = 1024
read(4, "nECT1Pkts                   \t0\nI"..., 1024) = 1024
read(4, "MembQueries        \t0\nIcmp6OutGr"..., 1024) = 792
read(4, "", 1024)                       = 0
close(4)                                = 0
openat(AT_FDCWD, "net/sockstat", O_RDONLY) = 4
fstat(4, {st_mode=S_IFREG|0444, st_size=0, ...}) = 0
read(4, "sockets: used 29266\nTCP: inuse 6"..., 1024) = 143
read(4, "", 1024)                       = 0
close(4)                                = 0
openat(AT_FDCWD, "partitions", O_RDONLY) = 4
fstat(4, {st_mode=S_IFREG|0444, st_size=0, ...}) = 0
read(4, "major minor  #blocks  name\n\n 182"..., 1024) = 102
read(4, "", 1024)                       = 0
close(4)                                = 0
openat(AT_FDCWD, "diskstats", O_RDONLY) = 4
fstat(4, {st_mode=S_IFREG|0444, st_size=0, ...}) = 0
read(4, " 182  790144 ploop49384 25997768"..., 1024) = 160
read(4, "", 1024)                       = 0
close(4)                                = 0
shmctl(0, SHM_INFO, {used_ids=0, shm_tot=0, shm_rss=0, shm_swp=0, swap_attempts=0, swap_successes=0}) = 0
openat(AT_FDCWD, "net/rpc/nfsd", O_RDONLY) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "net/rpc/nfs", O_RDONLY) = -1 ENOENT (No such file or directory)
setresuid(-1, 0, -1)                    = 0
openat(AT_FDCWD, "self/mountstats", O_RDONLY) = 4
fstat(4, {st_mode=S_IFREG|0400, st_size=0, ...}) = 0
read(4, "device /dev/ploop49384p1 mounted"..., 1024) = 1024
read(4, "hm with fstype tmpfs\ndevice devp"..., 1024) = 1024
read(4, " ext4\ndevice /dev/ploop49384p1 m"..., 1024) = 1024
read(4, "ser-scripts with fstype ext4\ndev"..., 1024) = 1024
read(4, "unted on /usr/share/cagefs-skele"..., 1024) = 1024
read(4, "p49384p1 mounted on /usr/share/c"..., 1024) = 1024
read(4, "-skeleton/usr/share/terminfo wit"..., 1024) = 1024
read(4, "ed on /usr/share/cagefs-skeleton"..., 1024) = 1024
read(4, "ed on /usr/share/cagefs-skeleton"..., 1024) = 681
read(4, "", 1024)                       = 0
close(4)                                = 0
getuid()                                = 0
setresuid(-1, 0, -1)                    = 0
chdir("pressure")                       = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "user_beancounters", O_RDONLY) = 4
fstat(4, {st_mode=S_IFREG|0400, st_size=0, ...}) = 0
read(4, "Version: 2.5\n       uid  resourc"..., 1024) = 1024
read(4, "     1048576              104857"..., 1024) = 1024
read(4, "      0  9223372036854775807  92"..., 1024) = 1024
read(4, " 0                    0  9223372"..., 1024) = 217
read(4, "", 1024)                       = 0
close(4)                                = 0
openat(AT_FDCWD, "vz/vestat", O_RDONLY) = 4
fstat(4, {st_mode=S_IFREG|0400, st_size=0, ...}) = 0
read(4, "Version: 2.2                    "..., 1024) = 772
read(4, "", 1024)                       = 0
close(4)                                = 0
openat(AT_FDCWD, "/sys/fs/resctrl/mon_data", O_RDONLY|O_NONBLOCK|O_CLOEXEC|O_DIRECTORY) = -1 ENOENT (No such file or directory)
chdir("/sys/class/infiniband")          = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/sys/kernel/mm/ksm/run", O_RDONLY) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/sys/kernel/mm/ksm/pages_sharing", O_RDONLY) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/sys/kernel/mm/ksm/pages_shared", O_RDONLY) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/sys/module/zswap/parameters/enabled", O_RDONLY) = -1 ENOENT (No such file or directory)
setresuid(-1, 0, -1)                    = 0
openat(AT_FDCWD, "/sys/kernel/debug/zswap/pool_total_size", O_RDONLY) = -1 ENOENT (No such file or directory)
openat(AT_FDCWD, "/sys/kernel/debug/zswap/stored_pages", O_RDONLY) = -1 ENOENT (No such file or directory)
getuid()                                = 0
setresuid(-1, 0, -1)                    = 0
chdir("/")                              = 0
setresuid(-1, 0, -1)                    = 0
perf_event_open({type=PERF_TYPE_HARDWARE, size=PERF_ATTR_SIZE_VER6, config=PERF_COUNT_HW_INSTRUCTIONS, sample_period=0, sample_type=0, read_format=0, inherit=1, pinned=1, precise_ip=0 /* arbitrary skid */, ...}, -1, 0, -1, PERF_FLAG_FD_CLOEXEC) = -1 EACCES (Permission denied)
perf_event_open({type=PERF_TYPE_HARDWARE, size=PERF_ATTR_SIZE_VER6, config=PERF_COUNT_HW_CPU_CYCLES, sample_period=0, sample_type=0, read_format=0, inherit=1, pinned=1, precise_ip=0 /* arbitrary skid */, ...}, -1, 0, -1, PERF_FLAG_FD_CLOEXEC) = -1 EACCES (Permission denied)
perf_event_open({type=PERF_TYPE_HARDWARE, size=PERF_ATTR_SIZE_VER6, config=PERF_COUNT_HW_INSTRUCTIONS, sample_period=0, sample_type=0, read_format=0, inherit=1, pinned=1, precise_ip=0 /* arbitrary skid */, ...}, -1, 1, -1, PERF_FLAG_FD_CLOEXEC) = -1 EACCES (Permission denied)
perf_event_open({type=PERF_TYPE_HARDWARE, size=PERF_ATTR_SIZE_VER6, config=PERF_COUNT_HW_CPU_CYCLES, sample_period=0, sample_type=0, read_format=0, inherit=1, pinned=1, precise_ip=0 /* arbitrary skid */, ...}, -1, 1, -1, PERF_FLAG_FD_CLOEXEC) = -1 EACCES (Permission denied)
getuid()                                = 0
setresuid(-1, 0, -1)                    = 0
openat(AT_FDCWD, "/proc/loadavg", O_RDONLY) = 4
fstat(4, {st_mode=S_IFREG|0444, st_size=0, ...}) = 0
read(4, "0.05 0.15 0.28 1/7 3448043\n", 1024) = 27
close(4)                                = 0
getcwd("/", 1024)                       = 2
chdir("/proc")                          = 0
openat(AT_FDCWD, ".", O_RDONLY|O_NONBLOCK|O_CLOEXEC|O_DIRECTORY) = 4
fstat(4, {st_mode=S_IFDIR|0555, st_size=0, ...}) = 0
getdents64(4, 0x23325b0 /* 136 entries */, 32768) = 3992
getdents64(4, 0x23325b0 /* 0 entries */, 32768) = 0
close(4)                                = 0
chdir("/")                              = 0
write(2, "#threads (7) < #procs (105)\n", 28#threads (7) < #procs (105)
) = 28
exit_group(53)                          = ?
+++ exited with 53 +++
Atoptool commented 1 month ago

When gathering the process/thread specific counters, there is a consistency check which ensures that the number of threads should never be smaller than the number of processes (even a zombie process still contains a thread). The number of threads is determined from the file /proc/loadavg and the number of processes from the number of numerical subdirectories below the /proc directory. The contents of the /proc/loadavg in the strace output is 0.05 0.15 0.28 1/7 3448043 which means that only 7 threads would be present in this system. This looks like a wrong value delivered by this version of the kernel. Issue #232 shows a similar situation. The kernel source code file fs/proc/loadavg.c shows that the contents of the kernel variable nr_threads is inserted behind the slash.