[RPi5] unix_err:'18' error : 'Too many open files'

  • Please provide a full debug log.

    How to post a log (wiki)

    1. Enable debugging in Settings>System Settings>Logging
    2. Restart Kodi
    3. Replicate the problem
    4. Generate a log URL (do not post/upload logs to the forum)

    use "Settings > LibreELEC > System > Paste system logs" or run "pastekodi" over SSH, then post the URL link

  • The following command (run from ssh):

    Code
    lsof | head -1 | awk '{ print "COUNT " $2 " " $1; }' && lsof +c 0 | awk '{ print $2 " " $1; }' | sort -rn | uniq -c | sort -rn | head -20

    will show which processes have files open. If there is a leak, then one process (possibly kodi.bin) is likely to be increasing regularly.

    Do you see the numbers going up after a few minutes of kodi sitting idle?

    Do you see the numbers going up after kodi playing a file and stopping?

  • It stays the same when it is idle or play a file.

    1024 /usr/sbin/connmand 546
    103 /usr/lib/systemd/systemd 1
    98 /usr/lib/kodi/kodi.bin 924
    63 /usr/bin/dbus-daemon 392
    33 /usr/sbin/smbd 863
    31 /usr/lib/systemd/systemd-journald 261
    24 /usr/lib/bluetooth/bluetoothd 668
    22 /usr/sbin/smbd 868
    22 /usr/sbin/smbd 867
    22 /usr/sbin/nmbd 860
    22 /usr/bin/pulseaudio 408
    20 /usr/lib/systemd/systemd-logind 413
    14 /usr/sbin/avahi-daemon 581
    14 /usr/bin/udevadm 378
    13 /usr/lib/openssh/sshd-session 3288
    13 /usr/lib/iwd 399
    11 /usr/sbin/rpcbind 321
    9 /usr/sbin/sshd 622
    9 /usr/sbin/connman-vpnd 386
    8 /usr/sbin/wsdd2 415

    But it happens when i scan all the files. Now it doesn't happen when it is done.


  • But it happens when i scan all the files. Now it doesn't happen when it is done.

    Please be specific.

    What happens when you scan all the files (crash? number of open files goes up?)

    What doesn't happen? When what is done?

    By scan all the files, do you mean using "Update library"?

    If number of open files goes up while doing it, what is the highest number you see (and is it assigned to kodi.bin).

    Does the number go down again?

  • Sorry for late response, to much work :(


    I will test more on the week and start over to get it to crash.

    I have the a Library Auto Update installed, and i have a mysql.

    I gone to disable the addon and remove the library and do the built in update.