Forum
[SOLVED] Memory leak when idle? - Printable Version

+- Forum (http://forum.xbian.org)
+-- Forum: Software (/forum-6.html)
+--- Forum: Kodi (/forum-18.html)
+---- Forum: Kodi Settings (/forum-36.html)
+---- Thread: [SOLVED] Memory leak when idle? (/thread-4172.html)



Memory leak when idle? - grandcanyon - 30th Jun, 2023 11:16 AM

I am running Xbian on a Rpi 3+ and Kodi will freeze and I see in dmesg that I get an out of memory error. I don't get a kernel panic. Kodi restarts but the previous screen stays on the TV so I can see it happens at random times.

PRETTY_NAME="XBian 11.0 - Bullseye"
NAME=XBian
VERSION_ID=11.0
VERSION="XBian 11.0 - Bullseye"
ID=raspbian
ID_LIKE=debian
ANSI_COLOR="1;31"
uname = 6.1.28+
getconf LONG_BIT = 32

I don't see any memory leak warnings in the kodi.log file. I do run iptvsimple so I don't know if this is a source of my problem or something else.

I thought it could be this but it was already disabled sudo echo 0 > /sys/kernel/mm/lru_gen/enabled

Any pointers?


Memory leak when idle? - f1vefour - 1st Jul, 2023 05:34 AM

Are you running a heavy skin?


RE: Memory leak when idle? - grandcanyon - 1st Jul, 2023 09:21 AM

(1st Jul, 2023 05:34 AM)f1vefour Wrote:  Are you running a heavy skin?

No just the default Kodi skin Estuary is all I use. I don't have any other skins installed besides the two default ones.


RE: Memory leak when idle? - grandcanyon - 8th Jul, 2023 06:23 AM

I created a swapfile at /var/swapfile so now Kodi doesn't freeze or cause OOM_killer to kill Kodi. Looks like upstart zram-swap should create the swapfile but it doesn't. I believe it is due to the file system being btrfs. The upstart log doesn't give any info for zram-swap except /proc/self/fd/9: 43: echo: echo: I/O error


RE: Memory leak when idle? - Exnor - 13th Jul, 2023 06:00 AM

I have the same problem. As workaround i just increased the swap partition to 1.5GiB (default was 256MiB (?) or something like that).
Now Kodi does not crash or restarts.

I do notice that Swap usage can reach up to 700MB sometimes, and only a Kodi stop/start clears the swap back to zero.


RE: Memory leak when idle? - Nehemiah - 13th Jul, 2023 04:35 PM

If you don't see any memory leak warnings in the kodi.log file. But it does run iptvsimple, so I think it is because of other reasons. It should be that there is something wrong with the system when you restart. I suggest shutting down again and then turning it on again later.chatgpt login


RE: Memory leak when idle? - grandcanyon - 14th Jul, 2023 10:39 AM

(13th Jul, 2023 06:00 AM)Exnor Wrote:  I have the same problem. As workaround i just increased the swap partition to 1.5GiB (default was 256MiB (?) or something like that).
Now Kodi does not crash or restarts.

I do notice that Swap usage can reach up to 700MB sometimes, and only a Kodi stop/start clears the swap back to zero.

My system wasn't creating any swap (0 GB) which was causing my problems. I created a swap but I was still getting some crashes and dmesg gave me an error about can't swap pagenets or something on a non-sub volume. I had to create a swap on a subvolume. Since then no crashes.