High RAM usage indicated even after shutting everything down

I’m sure this is entirely my own fault after tinkering with virtualization related settings, but I noticed (and verified) Conky reporting high RAM usage unexpectedly even after shutting everything major down. At first I figured maybe a test VM didn’t shut down all the way, but a restart didn’t help. Still about 18GB out of 32 “used”.

Best guess is that maybe it’s something related to hugepages tinkering. What can I check on to determine the cause?

└─$ free
              total        used        free      shared  buff/cache   available
Mem:       32865120    18673632    12345168       98080     1846320    13678960
Swap:      10485752           0    10485752

Is buff/cache (above) kinda high?

Below -
MemFree + MemAvailable = Seems like what probably should be free, so I suppose it’s not really “used” but just reserved for use, maybe by the kernel or something.
Also below - Hugetlb high?

└─$ cat /proc/meminfo 
MemTotal:       32865120 kB
MemFree:        12496472 kB
MemAvailable:   13823716 kB
Buffers:          159396 kB
Cached:          1536364 kB
SwapCached:            0 kB
Active:          2372876 kB
Inactive:         725544 kB
Active(anon):    1397396 kB
Inactive(anon):    58236 kB
Active(file):     975480 kB
Inactive(file):   667308 kB
Unevictable:         128 kB
Mlocked:             128 kB
SwapTotal:      10485752 kB
SwapFree:       10485752 kB
Dirty:               560 kB
Writeback:             0 kB
AnonPages:       1402824 kB
Mapped:           634052 kB
Shmem:             62364 kB
KReclaimable:     107748 kB
Slab:             293836 kB
SReclaimable:     107748 kB
SUnreclaim:       186088 kB
KernelStack:       11088 kB
PageTables:        26220 kB
NFS_Unstable:          0 kB
Bounce:                0 kB
WritebackTmp:          0 kB
CommitLimit:    18529704 kB
Committed_AS:    7105872 kB
VmallocTotal:   34359738367 kB
VmallocUsed:       77296 kB
VmallocChunk:          0 kB
Percpu:             8096 kB
HardwareCorrupted:     0 kB
AnonHugePages:         0 kB
ShmemHugePages:        0 kB
ShmemPmdMapped:        0 kB
FileHugePages:         0 kB
FilePmdMapped:         0 kB
CmaTotal:              0 kB
CmaFree:               0 kB
HugePages_Total:    8192
HugePages_Free:     8192
HugePages_Rsvd:        0
HugePages_Surp:        0
Hugepagesize:       2048 kB
Hugetlb:        16777216 kB
DirectMap4k:      727760 kB
DirectMap2M:    14917632 kB
DirectMap1G:    17825792 kB

Below htop is sorted by memory use, and nothing uses more than 1%, so whatever it is, it’s invisible to htop.

(Uptime shows the shameful amount of time I’ve spent screwing with this! UGh!)

Hugepages changes done in grub config.
GRUB_CMDLINE_LINUX_DEFAULT="intel_iommu=on iommu=pt hugepages=8192"

Any ideas?

:sweat_smile:
Removing hugepages from grub config reduced it - okay I guess I need to do some RTFM about hugepages because I didn’t really expect that! lol

2 Likes