In my ubuntu 20.04 VM, XFS is used instead of ZFS, and swap is disabled
In below case, used memory is high, but I can not get clue from the result of df -hl -t"tmpfs"
and ls -ahl /dev/shm/
command according to High memory usage that cannot be traced to a service or application.
root@host# free -m
total used free shared buff/cache available
Mem: 80445 55261 7702 4 17481 24358
Swap: 0 0 0
root@host# ps aux | awk '{sum += $5}END{print sum}'
149937296
root@host# ps aux | awk '{sum += $6}END{print sum}'
18648208
root@host# cat /proc/meminfo
MemTotal: 82376120 kB
MemFree: 7999208 kB
MemAvailable: 24992536 kB
Buffers: 2236 kB
Cached: 9692856 kB
SwapCached: 0 kB
Active: 17974176 kB
Inactive: 8943420 kB
Active(anon): 17207388 kB
Inactive(anon): 2704 kB
Active(file): 766788 kB
Inactive(file): 8940716 kB
Unevictable: 96 kB
Mlocked: 96 kB
SwapTotal: 0 kB
SwapFree: 0 kB
Dirty: 1116 kB
Writeback: 0 kB
AnonPages: 17046688 kB
Mapped: 748456 kB
Shmem: 4688 kB
KReclaimable: 8143264 kB
Slab: 10557752 kB
SReclaimable: 8143264 kB
SUnreclaim: 2414488 kB
KernelStack: 51248 kB
PageTables: 70164 kB
NFS_Unstable: 0 kB
Bounce: 0 kB
WritebackTmp: 0 kB
CommitLimit: 41188060 kB
Committed_AS: 31043960 kB
VmallocTotal: 34359738367 kB
VmallocUsed: 103992 kB
VmallocChunk: 0 kB
Percpu: 42528 kB
HardwareCorrupted: 0 kB
AnonHugePages: 176128 kB
ShmemHugePages: 0 kB
ShmemPmdMapped: 0 kB
FileHugePages: 0 kB
FilePmdMapped: 0 kB
CmaTotal: 0 kB
CmaFree: 0 kB
HugePages_Total: 0
HugePages_Free: 0
HugePages_Rsvd: 0
HugePages_Surp: 0
Hugepagesize: 2048 kB
Hugetlb: 0 kB
DirectMap4k: 54648704 kB
DirectMap2M: 28188672 kB
DirectMap1G: 3145728 kB
root@host# slabtop -o -s c | head -12
Active / Total Objects (% used) : 22682445 / 27264744 (83.2%)
Active / Total Slabs (% used) : 564554 / 564554 (100.0%)
Active / Total Caches (% used) : 117 / 166 (70.5%)
Active / Total Size (% used) : 8650551.69K / 10501591.99K (82.4%)
Minimum / Average / Maximum Object : 0.01K / 0.38K / 8.00K
OBJS ACTIVE USE OBJ SIZE SLABS OBJ/SLAB CACHE SIZE NAME
6376600 5136892 80% 1.00K 199302 32 6377664K xfs_inode
2795184 2314723 82% 0.38K 66552 42 1064832K xfs_buf
1828295 1748464 95% 0.57K 65414 28 1046624K radix_tree_node
2909193 2832050 97% 0.19K 69283 42 554264K dentry
1173102 269973 23% 0.19K 27931 42 223448K skbuff_ext_cache
root@host# df -hl -t"tmpfs" | head -5
Filesystem Size Used Avail Use% Mounted on
tmpfs 7.9G 3.5M 7.9G 1% /run
tmpfs 40G 0 40G 0% /dev/shm
tmpfs 5.0M 0 5.0M 0% /run/lock
tmpfs 40G 0 40G 0% /sys/fs/cgroup
root@host# ls -ahl /dev/shm/
total 0
drwxrwxrwt 2 root root 40 Nov 9 11:53 .
drwxr-xr-x 19 root root 4.0K Jul 5 18:11 ..
root@host# iostat
Linux 5.4.0-121-generic (host) 12/07/2022 _x86_64_ (20 CPU)
avg-cpu: %user %nice %system %iowait %steal %idle
2.19 0.00 0.53 0.89 0.00 96.39
Device tps kB_read/s kB_wrtn/s kB_dscd/s kB_read kB_wrtn kB_dscd
dm-0 353.88 1623.01 946.49 2348.13 21680405673 12643367860 31366521608
sda 349.62 1623.02 946.49 2348.19 21680433182 12643367968 31367401516