I'm using minidlna and it works fine, so thanks and kudos for a very well crafted piece of software.
I do have an issue though. My minidlna.conf has several media_dir entries pointing to unrelated stuff, but everything is videos. When browsing he shares from a client via the "Browse Folders" or "Browse Vdeos > Folders", all files and subfolders are mixed together. Since I have 100s or 1,000s of files in each, this is a pain to navigate.
Is there any way to have a first level that would keep files segregated by source dir, ie
- add a "name" parameter to the media_dir line:
media-dir=mnt/3TBEXT4/FilmsUS, "Films US"
media-dir=mnt/3TBEXT4/FilmsFR, "Films FR"
- and then, when choosing the "browse folders" option, to see as a first tree level "Series", "Films US", and "Films FR",… , instead of a general jumble of all the files and subdirs they contain ?
I don't even care if the "name" is the actual name of the source dir, and not a new parameter (not full path pleaaaase, though it would be better then the current situation, too)
Thanks for any help,
I think following satisfies your wishes.
Thanks.. but no thanks. There's gazillion of other, non-media, stuff on that drive (which, as the name implies, is 3TB and mostly full). Pointing minidlna at the whole shebang makes it very slow to start up, heavy to use, and a bit flaky. Probably mainly my very lowly server's fault, rather than minidlna's. I was doing that at the beginning, and had to scale down to more specific shares.
Basically minidlna creates database file at first time execution. Once the database is created, it does not create it again. So, though it take long time only the first time if a bunch of files are in the directories, it starts quickly after that. If it takes long in every time, you need to check where the database file named "files.db" is created.
Sorry, if I misunderstand the issue again.
Arf, typed a very detailed explanation and lost everything. Here goes again…
First, thanks for your help.
Second, it still don't work:
- I've got oodles of stuff on that drive, the minidlna-shared part is only a small portion. Even at the root level, about 80% of the directories are non-minidlna, so even just seeing that is a bit of a bother.
- changing my HD's directory structure to segregate minidlna content in a single dir is allso a non-starter, because some of the dirs I'm sharing are not root dirs, but subdirs… so taking them to a /minidlna dir would wreak the whole organization. For example, I've got a Family folder with with their photos, their films, various stuff (important mails, stuff i help my dad with) and a "films for the kids" folder. I only want/need that one in minidlna.
Writing this description makes me wonder: could I create a dir with virtual links to the folders I do want to share in minidlna ? That would work for me, it's only a handful, and I think Linux does pointers to files/dirs ? If that's the case, you've solved the problem ^^
OK, got it:
1- setup a /dlnashares directory somewhere
2- fill it with symlinks to the actual directories you want to share (ln -s \mnt\3TBEXT4\FilmsUS FilmsUS in my case)
3- profit !
At first I went for /dlnashares/FilmsUS/(symlink to FilmsUS), but, strangely, that gave me a root/FilmsUS/FilmsUS/(files) structure, so I got rid of the intermediate directory and put the symlinks right in the root.
Thnaks hieroun, without this discussion with you I would never have thought of that :-)
2a- exit minidlna
2b- delete your files.db
2c- change minidlna.conf to have a single media_dir, pointing to your /dlnashares dir.