Posts by hagaygo

    Thanks for checking things up.

    It seems you found the reason why RPI3 is handling the file with no problem, it uses the the GPU (and its memory) while RPI4 current code uses software and the RAM , thats why it needs much more.

    As for sample images , you are right the the pictures that wont work are shot with professional camera and are about 60mpx.

    I cant upload them (too personal, so i created "dummy" jpg and uploaded them to the previous shared link (

    They are called 35mpx.jpg , which is the smallest that worked with for me with gpu_mem=128.

    The other one is 60mpx.jpg which is similar to the "real" one i have , and of course it doesn't work (might not work on 2gb also :))

    The RPI3 indeed works hard and it takes about 5-6 seconds to load the 60mpx.jpg file , but it does show it.

    My worries is that the software decode is buggy (since it not used on other RPI's) , since i got occasional crash/freeze on library scans , which don't normally use big images.

    Please let me know if you need anything else.

    The picture viewer is just one of the problems and was "easy" to reproduce.

    Library scan picks up images from time to time , and some thumbnails creation causes freeze/crashes also.

    This scenario is much harder to reproduce since library scan are different each time (only runs on new episodes/shows/movies).

    There is a problem in image decoding in RPI4 at the moment , and i got some images that causes freeze/crash even on gpu_mem=128.

    The problem is still there on 4gb model , just "under the hood".

    320mb is the default in libreelec , at least for 9.1.502.

    256mb worked with all my tested h.264/h.265/4k videos , the comment on config.txt states that 288mb is needed for some videos.

    128mb worked for me only for h.264 and few h.265 (no 4k no 10bit).

    Still , it seems there is an issue with some JPG decoding which causes a lot of memory usage comparing to rpi3.

    Little update : found few JPG which causes freeze/crash even with gpu_mem=256

    What do you know , setting gpu_mem=256 (and of course 128) made the freeze/crash go away (so far).

    Still , i believe it just "hides" the problem rather than really solve it.

    I uploaded 3 videos of my libreelec behavior in each setup , they are available on

    rpi3b.mp4 = browsing the pictures on RPI3B running 9.1.502 , you can see the memory usage change is minimal.

    rpi41gb 320gpumem crash.mp4 = browsing the same pictures on RPI4 1G with gpu_mem=320 (default) - you can see the far more rapid change of memory usage and then finally kodi crashes.

    Rpi41gb Gpumem256.mp4 = browsing the pictures on RPI4 1G with gpu_mem=256 , you can still see the rapid memory usage changes , but no crash.

    I guess you have RPI4 with 2/4gb memory that's why there is no crash on your end , but i am pretty sure the memory usage does exists you just have plenty of it.8)

    The memory usage behavior happens only on certain jpg.

    I found that when i take picture with gcam app on my one plus 5 it generate a "problematic" jpg , but when i use oos cam it generate non problematic jpg.

    Thanks for the help so far and let me know if anything else is needed.

    Some more findings :

    1.Tested my setup with 9.1.502 on a RPI 3B (with rpi2 dist) , no problem with picture viewing and no freezes so far.

    I guess its indeed only problem with RPI4 dist.

    2.When enabling debug logging the memory usage on the OSD drop much more when viewing to attached jpg on the RPI4.

    On RPI4 it drops like 50-60mb and then goes back up (if its not get freezed).

    On RPI3B same pictures drops like 5-15 mb and goes back up. (and no UI freeze so far)

    Its indeed problem with certain jpg types which also cause problem with some thumb nails.

    Let me know if anything else is needed.

    I have RPI4 1GB. (i see the posted links not working currently here is last log i have

    External Content
    Content embedded from external sources will not be displayed without your consent.
    Through the activation of external content, you agree that personal data may be transferred to third party platforms. We have provided more information on this in our privacy policy.

    Using default config.txt which means GPU_MEM=320 which leaves about 680mb ram for libreelec.

    As i mentioned the test jpg i made are big , i uploaded them to google drive (all of them are 144mb).

    You can download the images from :

    Even on clean install put them on local storage and just use the picture viewer to watch them one by one (with luck it will freeze on the first/second picture).

    Thanks for your help so far.

    Thanks for your feedback.

    I posted full logs.(the log clearly show the time gap while freeze)

    While in debug the memory status is on the OSD and while the freeze happens there is more than 450/500 mb free.

    Also the problem is clearly happens on pictures viewer, i think the freezes not while viewing pictures related to thumbnails creation.

    Did you try both hdmi outputs?

    Here only the one near the usb power slot outputs a video.

    As described on LibreELEC (Leia) 9.2 Beta 2 i did more tests to reproduce.

    Installed on clean sd card , enabled ssh and copied via samba share several test jpg files.

    When entering pictures viewer kodi just freeze for 2-4 minutes , some times on start sometimes after few picture viewing and using left/right to switch and then usually kodi resumes or crash and restarted.

    Also when new file arrived and libreelec picks it up for library scan , there is a freeze from time to time , My guess its the same problem as in the picture viewer

    crash log link :

    log link :

    I think there is a problem with certain jpg types , because with my old jpg files i never managed to reproduce the freeze.

    each problematic jpg files i about 5-7 mb , i cant upload them here , if the logs are not enough i will upload them somewhere.

    Thanks in advance for any help.

    Tried it for about 2 hours of usage (RPI4 1GB).

    Everything i am using seems to work just fine.

    2 issues still persist from earlier builds.

    1.Occasional tearing on KODI GUI (seems less frequent then previous builds)

    2.Pictures viewer causes total system freeze (only power unplug releases it) from time to time.

    viewing same pictures from file manager works just fine.

    Also after restoring my backup from previous libreelec (RPI 3B+) i had same occasional system freezes until all thumbnail data was kinda refreshed.

    So my guess there is some issue with picture loading/analyzing , tried to find something on debug logs , found nothing.

    I assume i am not the only one with this problem since i can easily reproduce it with almost every jpg i try.

    Keep up the good work.:thumbup:

    My RPI's (3b+ and 2) works for days/weeks/months without the need for reboot.

    if this keeps happening you can try to kill kodi.bin process (it will restart automaticlly) via SSH.

    If after this all works normally my guess would be its some problem with KODI itself (rouge addon would be a good guess) - i made a remote shortcut for this for various needs. (you can check the log file , with/without enabling debug log)

    As for you question for scheduled reboot , you can define a cron job for either restarting or killing kodi.bin - but i would not recommend going this way as its not really needed and you should find the cause in KODI itself instead.