Kernel reports 5G of RAM while machine has 8G of RAM

I moved over to openSuSE slowroll on my laptop a few months ago and everything is going great.
Until I opened htop one day and saw that apparently, my system only had 5.67G.
I tried the following things to try figure out where the problem is.

  1. I looked at my bios and it said I had 8192MiB of RAM as expected
  2. sudo dmidecode -t 17says 8GB openSUSE Paste
  3. MemTotal in /proc/meminfo says 5948580 kB
  4. There are no memory limits set by grub (in /etc/default/grub or /boot/grub2/grub.cfg). I searched for “mem” in these files and the only lines where “mem” was mentioned were commented out.
  5. I then tried doing sudo sysctl -a | grep 'vm. to look for virtual memory parameters, but didn’t come up with anything useful. openSUSE Paste

I do not have zram enabled.
I used to use arch on the same laptop where zram was enabled. Could this have caused a problem during the install or something because I stopped using zram?

You forgot to show the full file.
Also show full output of dmesg after boot.

Possible situation: 2 GiB goes to video RAM, 330 MiB goes to system usage.
Post

inxi -aFmz

Full /proc/meminfo output: meminfo - Pastebin.com
Full dmesg output: Dmesg output - Pastebin.com, near the beginning it says [ 0.060196] Memory: 2710824K/6174988K available (16384K kernel code, 2949K rwdata, 12520K rodata, 4204K init, 4592K bss, 371364K reserved, 0K cma-reserved)

Strangely, when ran without sudo, inxi says 6GiB
Memory: System RAM: total: 6 GiB available: 5.67 GiB used: 1.84 GiB (32.4%) RAM Report: permissions: Unable to run dmidecode. Root privileges required.
but when ran with sudo, it says 8GiB
Memory: System RAM: total: 8 GiB available: 5.67 GiB used: 1.83 GiB (32.3%) Array-1: capacity: 128 GiB note: check slots: 2 modules: 1 EC: None max-module-size: 64 GiB note: est. Device-1: DIMM 0 type: DDR4 detail: synchronous unbuffered (unregistered) size: 8 GiB speed: spec: 3200 MT/s actual: 2400 MT/s volts: curr: 1.2 min: 1.2 max: 1.2 width (bits): data: 64 total: 64 manufacturer: Micron Technology part-no: 4ATF1G64HZ-3G2B2 serial: <filter> Device-2: DIMM 0 type: no module installed
weird

Also, output of glxinfo | grep -E -i 'device|memory': openSUSE Paste
It says Dedicated video memory: 2048 MB then it says Total available memory: 4952 MB
But that’s GTT which isn’t holding my ram. I changed my kernel parameters to decrease GTT to 500MiB but MemTotal is still 5948572 kB.

[    0.000000] BIOS-e820: [mem 0x00000001cf000000-0x000000024effffff] reserved

This is exactly 2GiB. Your BIOS does not make this memory range available, there is nothing Linux can do. Later your video card reports 2GiB of video memory, so one of following is possible

  • your video card is using part of you RAM.
  • your video card memory shadows some physical memory. In this case your BIOS may offer possibility to remap it above 8GiB.

If it is not related to the video, then you better ask on your hardware support forums what this 2GiB range is. Linux is just using what BIOS allows.

Thanks, now at least I know what the problem is. I remember back a few years ago on windows I did have all 8 GB of my RAM, I’ll check more in my bios.