Adding paths with spaces to minidlna.conf

Help
Anonymous
2011-12-29
2014-03-30
  • Anonymous - 2011-12-29

    Hi,

    I have just installed minidlna on Ubuntu 11.10. I use an external hard drive which mounts automatically at "/media/Expansion Drive".

    I have tried to add certain paths on the external hard drive to minidlna.conf but it tells me that the directories are "not accessible". I think that this may mean that it is having trouble with the space in the path "Expansion Drive". I have tried escaping the space, using quotes, and wildcards, but nothing has worked.

    If I set minidlna to scan the whole of /media, it seems to work (although my music collection hasn't yet shown up, but that may be another story), but I would like the ability to drill down a bit more than this.

    Any way around this?

     
  • Justin Maggard

    Justin Maggard - 2011-12-31

    Spaces in the path work fine for me.  What are the exact messages that you're seeing?

     
  • Cecil Coupe

    Cecil Coupe - 2012-01-09

    It is very possible that when your system boots that minidlna starts scanning disks for media  files before Ubuntu has mounted your external drive.  I can't think of a cure for that except to start minidlna after *all* disks in the minidlna.conf are mounted. Does minidlna run at boot or when you log in. Is the disk plugged in before that?

     
  • Anonymous - 2012-01-09

    Sorry for the slow reply, I forgot to subscribe to the thread.

    I have tried to add the spaces in the path and recreate the error. These are the errors that I am seeing:

    matt@shuttle:~$ sudo /etc/init.d/minidlna start
    Media directory not accessible!
    Media directory not accessible!
    Media directory not accessible!
    Media directory not accessible!

    The directories appear to have indexed correctly:

    scanner.c:719: warn: Scanning /media/Expansion Drive/music
    scanner.c:790: warn: Scanning /media/Expansion Drive/music finished (1407 files)!
    scanner.c:719: warn: Scanning /media/Expansion Drive/films
    scanner.c:790: warn: Scanning /media/Expansion Drive/films finished (1409 files)!
    scanner.c:719: warn: Scanning /media/Expansion Drive/series
    scanner.c:790: warn: Scanning /media/Expansion Drive/series finished (1534 files)!
    scanner.c:719: warn: Scanning /media/Expansion Drive/video
    scanner.c:790: warn: Scanning /media/Expansion Drive/video finished (1534 files)!
    scanner.c:719: warn: Scanning /home/matt/Pictures
    scanner.c:790: warn: Scanning /home/matt/Pictures finished (3060 files)!

    I have however discovered, having now waited for the scan to complete, that it is working anyway! So the message about not being accessible seems to just be some kind of warning.

     
  • Justin Maggard

    Justin Maggard - 2012-01-10

    That shouldn't be possible.  Are you sure that is from the same minidlna run?  Whenever you see that "Media directory not accessible" message, that directory should get kicked out.  I just checked in a more informative error message for not accessible errors.  It'll be included in the next release.

     
  • apoptygma berzerk

    I can confirm this behaviour on my setup. I have the config looking like this

    /etc/miniupnpd/minidlna.conf

    #media_dir=/home/0empty
    #media_dir=P,/home/0common/FamilyPhotos
    #media_dir=A,/home/0common/FamilyMusic
    #media_dir=/home/0common/FamilyDocuments
    media_dir=V,/home/0common/FamilyVideos
    media_dir=V,/home/0common/TV Series
    media_dir=A,/home/0common/Music

    # port for HTTP (descriptions and SOAP) traffic
    port=8200

    My "TV series" folder doesn't get scanned by miniDLNA but the FamilyVideos one works fine. I've tried changing the config to read

    media_dir=V,/home/0common/TV\ Series

    this will then give me an error when starting (with the first config I get no errors)

    minidlna.c:472: error: Media directory "/home/0common/TV\ Series" not accessible!

     
  • Cripton

    Cripton - 2014-03-30

    Hello, i just found the problem and my solution was to create a symbolic link.
    it's not pretty but do the job:

    ln -s target\ with\ spaces targetWithoutSpaces

    Bye!

     

Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:





No, thanks