You are not logged in.
I noticed that starting from 6.14 kernel (and on 6.15 too) i get very strange ram usage
No apps are opened at all and it is using 8GB of ram
This happens by just using the device, regular Firefox browsing, coding and etc.
Screenshot of btop:
https://imgbox.com/uQarniw5
Is this memory leak or something somewhere?
It is using 4GB of ram already at system startup
Specs:
Ryzen 5 5625U with Vega 7 GPU, 32GB RAM, KDE Plasma, all latest updates are installed, Steam /dev/shm is cleaned, preload service disabled
Offline
It is using 4GB of ram already at system startup
can you share a screenshot after boot before open anything else
but using 8g out of 32g is no problem - that's what you have your 32g for
I use zfs so about half of my ram is always in use for its cache and with 16g to spare it's still plenty for all what I do - which is sometimes even run a couple of VMs the same time
so using up to half your mem shouldn't concern you - as long as it doesn't fill up over time
Offline
develux wrote:It is using 4GB of ram already at system startup
can you share a screenshot after boot before open anything else
https://imgbox.com/3xIx4z2P
After few restarts
I use zfs
I am using XFS
Offline
Nice screenshots - but utterly useless.
cat /proc/meminfo
- early on and once you think your notice memory leaking away
No apps are opened at all and it is using 8GB of ram
This happens by just using the device, regular Firefox browsing, coding and etc.
So nothing but a chubby browser and an obese DE…
These things can eat 8GB RAM easily, the kde file indexer (aptly named Baloo… ), alone can fill up your file cache.
Also
lspci
- notably amdgpu has shown up being very generous w/ GTT/GART
=> https://bbs.archlinux.org/viewtopic.php … 0#p2226310 (you can actively reclaim it)
Edit: give me my smiley, bbs.
Last edited by seth (2025-05-30 06:19:42)
Online
hm, less then 3g after boot - that seems pretty normal - let the system use its resources
as for the previous shot: I have to agree with seth - I also summed up firefox to about 2gb on its own
as for plasma baloon indexer: unless you benefit from it by using the search often to find your files you can turn it off
otherwise can't see anything off
as for xfs vs zfs vs otthers: my point was to show that it can be normal to have a high resource usahe depending on your setup
Offline
It is 5GB now (only Konsole is opened)
https://imgbox.com/52olsqpy
Baloo disabled
Offline
Please don't link screenshots of text, post the text.
Online
Please don't link screenshots of text, post the text.
Sure, my bad
http://0x0.st/83Uk.txt
Only konsole is opened again
Offline
~1.73GB are actually in userspace use (cache + anon pages) and ~450MB are sitting in kernel slabs.
~1.93GB are unaccounted for, have you tried to reclaim them as shown in the previous links (you'll have to leave the GUI for that, but this is just to check whether this is indeed GTT/GART - if this works, the memory is supposed to be handed back to you as much as the GPU can give up once you're under actual memory pressure)
One thing though, 666MB swap are used, zswap is disabled - are you (also) using a zram device for swap?
https://wiki.archlinux.org/title/Zram#Usage_as_swap
Iff it is indeed not GTT/GART try to add "transparent_hugepage=never" to the kernel parameters, but only after double and triple checking that it's not the GPU.
Online
have you tried to reclaim them as shown in the previous links
Yes, I tried reclaiming it with
stress-ng --vm 1 --vm-bytes 31G
but no success, the memory usage returned to 5GB again.
are you (also) using a zram device for swap?
Yes, using zram as swap
I will check amdgpu_top GTT/VRAM usage report next time
Offline
http://0x0.st/83kD.txt
https://imgbox.com/lSTJx3Je
According to amdgpu_top, it is not GTT/VRAM fault
Also it cant be fixed with re-login in Plasma
EDIT: I didn`t play any games, just regular browsing and watching YouTube, but laptop went to deep sleep 2 times
Last edited by develux (2025-05-31 04:32:39)
Offline
You're lacking ~2GB again - "restarting plasma" actually does sound like GTT/GART - did you drop to the multi-user/rescue.target before trying to reclaim the memory? Does just dropping to the multi-user.target "fix" it?
df -h
Maybe some plasma-related cache in a tmpfs?
Online
did you drop to the multi-user/rescue.target before trying to reclaim the memory? Does just dropping to the multi-user.target "fix" it?
I don`t know much about systemd yet. Does this mean that I need to kill sddm to get to tty and retry to reclaim the memory?
https://0x0.st/83nQ.txt
Only psd is active, asd already disabled
Offline
Does this mean that I need to kill sddm to get to tty and retry to reclaim the memory?
Possibly, see the 2nd link below (but pointless if merely exiting plasma, w/o even restarting X11, "fixes" it)
systemctl isolate multi-user.target # this will immediately kill your GUI session!
Also
sudo journalctl | grep amdgpu
Online
sudo journalctl | grep amdgpu
https://0x0.st/835-.txt
Will try that command when I notice memory consumption
Offline
Check the RAM there before trying to reclaim it (and then check it again)
When it comes to GTT
May 31 13:18:53 archlinux kernel: [drm] amdgpu: 15739M of GTT memory ready.
AMD affords itself half your RAM, you might want to try to limit that to "amdgpu.gttsize=1024", https://wiki.archlinux.org/title/Kernel_parameters and see whether that limits the leaks (nb. that depending on your framebuffer size and because of the GL-heavy plasma, you might run into VRAM troubles this way, resulting in black windows or so. It's just to test whether this has any impact at all)
Online
Perhaps the memory consumption should be like this, I will continue to monitor the memory. I'll let you know if I notice any pattern in it.
Offline
There's certainly unaccounted used RAM - if that's not the GPU, that's a kernel leak and not "should be like this".
If it is the GPU you should™ be able to reclaim it if the GPU doesn't require it (hence multi-user or rescue target to guarantee that this isn't because of some hungry GUI stuff)
Online
According to
systemd-cgtop -m
it is something in user slice
https://imgbox.com/bm55jQE6
Can this be caused by
vm.swappiness = 180
vm.watermark_boost_factor = 0
vm.watermark_scale_factor = 125
vm.page-cluster = 0
vm.vfs_cache_pressure=50
in
/etc/sysctl.d/99-vm-zram-parameters.conf
?
Last edited by develux (2025-06-03 04:44:14)
Offline
I tried
systemctl isolate multi-user.target
and tried reclaiming memory, but no success. I did
cat /proc/meminfo
while not having GUI session (from tty): http://0x0.st/8YWY.txt
Offline
Bruh. https://imgbox.com/skOipGvP
htop and neofetch show one memory usage, while btop and neofetch show other memory usage
htop and neofetch are showing normal memory usage. Maybe there is no problem at all with my system, but btop and fastfetch measure ram usage by other method?
Offline
The authoritative data is /proc/meminfo - #20 has ~840MB unaccounted for.
while not having GUI session (from tty)
To be clear: it's also not running? You dropped to the multi-user/rescue target and did NOT only just ctrl+alt+f3 while plasma was still running on the other tty?
The various aggregators will show different versions of what is "used" and "free", including or not disk caches and inactive pages. They're good for general monitoring (and whateverfetch is good for r/unixporn) but not for any kind of memory analysis.
If it's not the GART/GTT, have you tried to disable zram completely? "transparent_hugepage=never" ?
Online
To be clear: it's also not running? You dropped to the multi-user/rescue target and did NOT only just ctrl+alt+f3 while plasma was still running on the other tty?
Plasma was not running, I was in tty1, I checked.
have you tried to disable zram completely?
Yes, no effect. But I tried disabling it already in userspace right after reboot
sudo swapoff /dev/zram0
"transparent_hugepage=never"
Not yet tried
Offline
According to
systemd-cgtop -m
it is something in user slice
https://imgbox.com/bm55jQE6
Can this be caused byvm.swappiness = 180 vm.watermark_boost_factor = 0 vm.watermark_scale_factor = 125 vm.page-cluster = 0 vm.vfs_cache_pressure=50
in
/etc/sysctl.d/99-vm-zram-parameters.conf
?
Can you revert this temporarily, reboot, and then post meminfo with no graphics running? I also use these settings, and (Total - Available), i.e., the difference between the first two lines is about 2GiB for all my machines (with 16+ GiB RAM). When these are turned off, the difference is much smaller.
Offline
After adding
transparent_hugepage=never
to cmdline: http://0x0.st/8YY4.txt
Issue is still there, plasma is running, other apps are closed
Offline