MiniDLNA - files.db cache is reset after system restart

  • OMV 4.1.35-1 on Debian 9.5, MiniDLNA 3.3.11


    The problem is that the cache file /var/cache/minidlna/files.db is reset after system restart (plus art_ache directory disappears as well). Also, MiniDLNA is even not doing scan automatically after the system restart.


    Can I stop this from happening somehow? I restart the system daily, so this is an issue :(


    Regards,

  • Hi,


    Did meet similar issue of empty minidlna db on system restart.

    In my case it was because minidlna.service start too earlier. Before my filesystem owning media files was actually mounted:


    Code
    Dec 22 07:53:08 nas.local systemd[1]: Starting MiniDLNA lightweight DLNA/UPnP-AV server...
    Dec 22 07:53:12 nas.local minidlnad[588]: [2020/12/22 07:53:12] minidlna.c:631: error: Media directory "A,/srv/dev-disk-by-label-MEDIA/music/" not accessible [No such file or directory]
    Dec 22 07:53:12 nas.local minidlnad[588]: [2020/12/22 07:53:12] minidlna.c:631: error: Media directory "V,/srv/dev-disk-by-label-MEDIA/video/" not accessible [No such file or directory]
    Dec 22 07:53:12 nas.local systemd[1]: Started MiniDLNA lightweight DLNA/UPnP-AV server.
    ...
    Dec 22 07:53:12 nas.local systemd[1]: Mounting /srv/dev-disk-by-label-MEDIA...
    Dec 22 07:53:12 nas.local systemd[1]: Mounted /srv/dev-disk-by-label-MEDIA.


    To fix it, just ask systemd to wait for the mount before starting minidlna service (using"RequiresMountsFor" option)... :)



    Please note, this would need to be manually updated on config changes. Alternatively, it is possible to use a more generic delay such as sleeping for 30 sec...


    Code
    [Service]
    ExecStartPre=/bin/sleep 30

Jetzt mitmachen!

Sie haben noch kein Benutzerkonto auf unserer Seite? Registrieren Sie sich kostenlos und nehmen Sie an unserer Community teil!