Minidlna in FreeNAS 8.2: automatic updating of media database

Status
Not open for further replies.

Zendaug

Cadet
Joined
May 16, 2012
Messages
4
Hi folks, apologies if this question has been asked already.

Is there any way to set up Minidlna to automatically update the media database when a new file is added, without having to rebuild the entire database from scratch? Based on some instructions that I found for minidlna (http://manpages.ubuntu.com/manpages/oneiric/man5/minidlna.conf.5.html), I tried adding "inotify = yes", but it doesn't seem to make a difference.

Minidlna is otherwise working very well, and is streaming movies to my Xbox 360.

I am using the x64 version of FreeNAS 8.2 (beta3).

- Zen
 

Zendaug

Cadet
Joined
May 16, 2012
Messages
4
Thanks Proto,

In Post #15, joeschmuck mentioned that the non-updating was related to a limitation with FreeBSD, and that it likely wouldn't be fixed in the near future. He suggested setting up a cron job to restart minidlna periodically, and having it rebuild the database from scratch each time. Not exactly an ideal solution, as I have a rather large database, but it might have to do for now.

Does anyone else know of any other workarounds to get the database automatically updated?

- Zen
 

cubix

Moderator
Joined
May 30, 2011
Messages
81
Hi Zendaug,

To my knowledge this was not fixed and I'm unaware of any incremental update capabilities currently.

When I was running miniDLNA rebuilds took approximately 10 minutes as I also have a somewhat large database. I found that scheduling restarts of miniDLNA in the middle of the night was sufficient unless I had just copied over files to my media directory which I wanted to watch then.

If you do come across any other solutions, please be sure to report back!

- cubix
 

paleoN

Wizard
Joined
Apr 22, 2012
Messages
1,403
It seems to be an issue with the port to FreeBSD. From what I understand inotify is linux only anyway. See this post on the minidlna forum.
 

joeschmuck

Old Man
Moderator
Joined
May 28, 2011
Messages
10,994
MiniDLNA plugin (minidlna-1.0.22_3-amd64.pbi) still does not support automatically updating the database. The good thing about the plugin is you know when you update your movies, music, and photos; so you can stop the service and then start it again from the GUI. It's not ideal, that is for sure but it's what we have right now.
 

explores

Cadet
Joined
Aug 29, 2012
Messages
2
Two months later and this is still a problem. I am very new to all of this and I have no problems using the UI to complete tasks but I am completely new to the shell commands. I would like to setup the cron job to restart the MiniDLNA server but I have no idea what the command is. I tried searching but everything I read just went over my head. Can someone help me out here?
 

joeschmuck

Old Man
Moderator
Joined
May 28, 2011
Messages
10,994
Two months later and this is still a problem. I am very new to all of this and I have no problems using the UI to complete tasks but I am completely new to the shell commands. I would like to setup the cron job to restart the MiniDLNA server but I have no idea what the command is. I tried searching but everything I read just went over my head. Can someone help me out here?
In your Cron job just run "minidlna -R" which will rescan your media.

-Mark
 

zdv

Dabbler
Joined
May 31, 2012
Messages
16
joeschmuck
In your Cron job just run "minidlna -R" which will rescan your media.
It does not work for me. I have an error: "bash: minidlna: command not found".
What is the folder where minidlna command is located?
 

joeschmuck

Old Man
Moderator
Joined
May 28, 2011
Messages
10,994
joeschmuck

It does not work for me. I have an error: "bash: minidlna: command not found".
What is the folder where minidlna command is located?
Sorry, MiniDLNA can be a pain. You can try a cron that 'service minidlna restart' which will stop and start the minidlna, I have not tried to create a cron for that myself so I don't know if it will actually work from the cron line. I have created a simple bash script which did work and ran that from cron. The downside with minidlna is if you are streaming video (haven't tested with music yet) while you restart the service, the service fails to restart properly so you must either reboot or stop and start the plugin again.
 
Status
Not open for further replies.
Top