Announcement

Collapse
No announcement yet.

minidlna during boot

Collapse
This topic is closed.
X
X
 
  • Filter
  • Time
  • Show
Clear All
new posts

    minidlna during boot

    Hi all.
    I'm trying to make minidlna to start during boot. To that purpose, I edited /etc/group to add my user to the minidlna group and then edited /etc/init.d/minidlna to set my user as the one running the minidlna daemon (i.e. minidlnad). Or at least that is what I think I was doing; since it's not working, there must be something I am missing or doing wrong (as very often happens).
    Any help will be much appreciated. Thanks in advance!

    #2
    Are you installing/configuring along these lines: https://itigic.com/install-and-confi...rver-on-linux/
    Windows no longer obstructs my view.
    Using Kubuntu Linux since March 23, 2007.
    "It is a capital mistake to theorize before one has data." - Sherlock Holmes

    Comment


      #3
      Hi, Snowhog, thanks for replying.
      Yes, I have installed and configured minidlna like indicated, but:
      If I try
      Code:
      sudo service minidlna start
      and then
      Code:
      sudo service minidlna status
      i get:
      × minidlna.service - MiniDLNA lightweight DLNA/UPnP-AV server
      Loaded: loaded (/lib/systemd/system/minidlna.service; enabled; vendor preset: enabled)
      Active: failed (Result: exit-code) since Wed 2022-01-05 09:24:30 CET; 26min ago
      Docs: man:minidlnad(1)
      man:minidlna.conf(5)
      Process: 5457 ExecStart=/usr/sbin/minidlnad -f $CONFIGFILE -P /run/minidlna/minidlna.pid -S $DAEMON_OPTS (code=exited, status=255/EXCEPTION)
      Main PID: 5457 (code=exited, status=255/EXCEPTION)
      CPU: 75ms
      And then it lists a bunch of stuff stored in /var/cache/minidlna that says can't be deleted because permission denied...
      So minidlna doesn't start, and I have to do
      Code:
      sudo minidlnad
      to get it up and running. And then all is good. But I have to do it manually whenever I want to use it. Not a huge inconvenience but still...
      So I guess not being able to start minidlna "properly" has to do with it not being starting on boot? How do I fix it? Do I just delete the stuff in /var/cache/minidlna?
      By the way, even if I start it manually, the status is still the same: failed (?).
      Again, thanks!
      Last edited by Snowhog; Jan 05, 2022, 08:43 AM.

      Comment


        #4
        I didn't see anywhere in that link where it said to change permissions on anything or add yourself to any groups and for certain not this
        and then edited /etc/init.d/minidlna to set my user as the one running the minidlna daemon (i.e. minidlnad)
        and now you're having permissions problems.

        Seems highly likely to me that you are launching minidlna as your user when it should be running as root like every other service, and now it won't work because it can't create or delete the files it needs.

        My suggestion is to purge minidlna from your system, undo all the edits/changes you made, and install it again without the extra edits.

        If you want to test my theory, make a VM in install minidlna in it following the correct steps and see if it works.

        Please Read Me

        Comment


          #5
          I stand corrected; I decided to test this and no matter what I did, I could not get minidlna to read my folders that were in my home folder.

          Finally got it to work by making the /home folder, my user folder, AND the file folders world-writable (drwxrwxrwx) and then it worked.

          Clearly, something is amiss and something is missing from the instructions.

          There is a way to launch minidlna as a user, but I couldn't seem to make it work. There is a minidlna file in /etc/default with this in it:

          Code:
          # User and group the daemon should run as
          # only for sysV init, for systemd please override minidlna.service
          #USER="root"
          #GROUP="minidlna"
          but this does nothing because it's for sysV init not systemd.

          Please Read Me

          Comment


            #6
            Following this seemed to work:

            https://forum.manjaro.org/t/minidlna...operly/49677/2

            Scroll to the post by "Twifty"

            Please Read Me

            Comment


              #7
              After following the steps from Twifty, I was able to return my /home and folder ownership to normal and it appears to be working - no permission errors on launch

              Please Read Me

              Comment

              Working...
              X