On Wed, 3 Jan 2018 09:44:27 +0100 Grozdan <[email protected]> wrote:
> On Wed, Jan 3, 2018 at 9:31 AM, Bob Williams <[email protected]> > wrote: > > On Tue, 2 Jan 2018 22:16:12 +0100 > > Grozdan <[email protected]> wrote: > > > >> On Tue, Jan 2, 2018 at 10:11 PM, Grozdan <[email protected]> > >> wrote: > >> > On Tue, Jan 2, 2018 at 10:00 PM, Bob Williams > >> > <[email protected]> wrote: > >> >> On Tue, 2 Jan 2018 21:05:49 +0100 > >> >> Grozdan <[email protected]> wrote: > >> >> > >> >>> On Tue, Jan 2, 2018 at 8:51 PM, Bob Williams > >> >>> <[email protected]> wrote: > >> >>> > My system is openSUSE Leap 42.3, and I am using the version > >> >>> > of minidlna from the packman repository. > >> >>> > > >> >>> > For some time I have been successfully running a minidlna > >> >>> > server which streams music to a Bose Soundtouch device over > >> >>> > WiFi. However, it stopped working a few weeks ago, and the > >> >>> > SoundTouch device could only find an empty folder. > >> >>> > > >> >>> > After several re-writes of /etc/minidlna.conf without > >> >>> > success, and searching for other versions of minidlna.conf > >> >>> > in non-default locations, I finally tracked the culprit down > >> >>> > to /usr/lib/systemd/system/minidlna.service which contained > >> >>> > the following: > >> >>> > > >> >>> > [Unit] > >> >>> > Description=MiniDLNA UPnP-A/V and DLNA media server > >> >>> > After=var-run.mount nss-lookup.target network.target > >> >>> > remote-fs.target > >> >>> > > >> >>> > [Service] > >> >>> > Type=forking > >> >>> > PIDFile=/var/run/minidlnad.pid > >> >>> > ExecStartPre=/usr/sbin/minidlnaconfig > >> >>> > EnvironmentFile=-/var/lib/minidlna/rescan.conf > >> >>> > ExecStart=/usr/sbin/minidlnad $RESCAN > >> >>> > -P /var/run/minidlnad.pid -f /var/lib/minidlna/minidlna.conf > >> >>> > [0] > >> >>> > > >> >>> > [Install] > >> >>> > WantedBy=multi-user.target > >> >>> > > >> >>> > So the unit file was forcing minidlna to use the > >> >>> > configuration file in /var/lib/minidlna/minidlna.conf rather > >> >>> > than the > >> >>> > default /etc/minidlna.conf! /var/lib/minidlna/minidlna.conf > >> >>> > pointed to media_dir=/mnt and was recreated at start-up, so > >> >>> > even editing the media_dir= line didn't work. Changing the > >> >>> > last line in the [Service] stanza to include > >> >>> > "-f /etc/minidlna.conf" got things working again - and just > >> >>> > in time for Christmas. ;-) > >> >>> > > >> >>> > I have no idea how this got changed, but I wonder if anyone > >> >>> > else has come across anything similar? > >> >>> > >> >>> Works here without issues on 2 computers. > >> >>> /var/lib/minidlna/minidlna.conf is used since we read > >> >>> /etc/minidlna.conf on startup and create our own version in > >> >>> /var/lib/minidlna. Tha's what the minidlnaconfig script does > >> >>> > >> >> Thank you for that explanation. I wasn't aware of that. > >> >> > >> >>> Nothing has changed in this configuration for the past few > >> >>> updates. The last update was just adding a SuSEfirewall2 file. > >> >>> Nothing else was touched > >> >>> > >> >> I don't use SuSEfirewall2 so it couldn't have been that. Must > >> >> have been something here, though I've no idea what. > >> > > >> > if your original email, you pasted the contents of the service > >> > file. I notice a [0] at the very end of the ExecStart line. Is > >> > this [0] actually present in the service file or did you made a > >> > mistake during copy/paste? > >> > if that [0] is actually part of the service file, something has > >> > changed the file. If not, everything looks fine to me and you may > >> > try to stop minidlna, clean the /var/lib/minidlna directory > >> > completely and lastly, configure /etc/minidlna.conf to your needs > >> > then start minidlna > >> > > The [0] is a copy and paste error. It is not part of the service > > file. > >> Sorry, you should configure /etc/sysconfig/minidlna as that's the > >> actual config file on openSUSE. I don't know why you have > >> /etc/minidlna.conf. It is not part of the package > >> > > Now I'm confused. The man page for minidlna says: > > > > "The following are user configurable options > > in /etc/minidlna.conf." > > > > No mention of /etc/sysconfig/minidlna, which I never knew existed, > > until now. This file also seems to require a different syntax > > to /etc/minidlna.conf. media_dir statements have to be entered on a > > single line separated by pipes, which systemd then rewrites onto > > separate lines when it recreates its own version of minidlna.conf > > > > These changes should be documented somewhere, preferably in man > > minidlna. > > > > I renamed /etc/minidlna.conf to /etc/minidlna.conf.orig and > > edited /etc/sysconfig/minidlna to point to my media_dir and then > > restarted minidlna. The process failed due to a > > missing /etc/minidlna.conf! > > > > sudo systemctl -l status minidlna.service > > ● minidlna.service - MiniDLNA UPnP-A/V and DLNA media server > > Loaded: loaded (/usr/lib/systemd/system/minidlna.service; > > enabled; vendor preset: disabled) Active: failed (Result: > > exit-code) since Wed 2018-01-03 08:20:30 GMT; 2min 17s ago Process: > > 5299 ExecStart=/usr/sbin/minidlnad $RESCAN > > -P /var/run/minidlnad.pid -f /etc/minidlna.conf (code=exited, > > status=255) Process: 5288 ExecStartPre=/usr/sbin/minidlnaconfig > > (code=exited, status=0/SUCCESS) Main PID: 3325 (code=exited, > > status=0/SUCCESS) > > > > Jan 03 08:20:30 blackbox systemd[1]: Starting MiniDLNA UPnP-A/V and > > DLNA media server... Jan 03 08:20:30 blackbox minidlnad[5299]: > > [2018/01/03 08:20:30] minidlna.c:548: fatal: Error reading > > configuration file /etc/minidlna.conf Jan 03 08:20:30 blackbox > > systemd[1]: minidlna.service: Control process exited, code=exited > > status=255 Jan 03 08:20:30 blackbox systemd[1]: Failed to start > > MiniDLNA UPnP-A/V and DLNA media server. Jan 03 08:20:30 blackbox > > systemd[1]: minidlna.service: Unit entered failed state. Jan 03 > > 08:20:30 blackbox systemd[1]: minidlna.service: Failed with result > > 'exit-code'. Jan 03 08:22:42 blackbox systemd[1]: Stopped MiniDLNA > > UPnP-A/V and DLNA media server > > Hi, > > I did not originally create the minidlna package (I'm not sure who > did, but it might have been Olaf) for openSUSE so I cannot tell you > why he did it this way. I only maintain currently the package and am > not inclined in changing it a lot. Olaf must have had good reasons for > doing what he did, and he usually knows what he does. That is, if he > made the package. > I'm grateful for your help. I would be interested to hear from Olaf as to why he set it up this way. > That said, on openSUSE systems, the config of minidlna is in > /etc/sysconfig/minidlna. You should edit that file. On openSUSE, there > is no /etc/minidlna.conf > As I said above, this should be documented somewhere. I can't remember, but I suppose I must have written my own /etc/minidlna.conf as that is what man minidlna says. > your service file failed because it should be using -f > /var/lib/minidlna/minidlna.conf instead of -f /etc/minidlna.conf in > StartExec. The service file of the package does not point to > /etc/minidlna.conf. You probably changed the service file > Correct. I had forgotten that. I have now re-edited the service file and everything is now working the 'openSUSE' way. Many thanks for your help. -- Bob Williams System: Linux 4.4.103-36-default Distro: openSUSE 42.3 (x86_64) Desktop: KDE Frameworks: 5.32.0, Qt: 5.6.2 and Plasma: 5.8.7 _______________________________________________ Packman mailing list [email protected] http://lists.links2linux.de/cgi-bin/mailman/listinfo/packman
