Moode Forum
[SOLVED] m3u with absolute paths - Printable Version

+- Moode Forum (http://moodeaudio.org/forum)
+-- Forum: moOde audio player (http://moodeaudio.org/forum/forumdisplay.php?fid=3)
+--- Forum: Support (http://moodeaudio.org/forum/forumdisplay.php?fid=7)
+--- Thread: [SOLVED] m3u with absolute paths (/showthread.php?tid=2851)



m3u with absolute paths - adixor - 08-01-2020

Hi all

I am trying to build some m3u playlists but while those with relative pathnames work, I can't make the ones with absolute paths work.

Example of file structure:

share name: "NAS" (samba)
Folder structure in samba:
Code:
+ Music
   + x1
      file.mp3
   + x2
      playlist.m3u

x1 and x2 are subfolders of "Music" and both are on the same level. One has the mp3 file one has the playlist.


I am trying to reference the mp3 file in the playlist using absolute paths. I tried these versions for the contents of playlist.m3u:

1.
NAS/Music/x1/file.mp3

2.
/NAS/Music/x1/file.mp3

3.
/mnt/NAS/Music/x1/file.mp3


I can't get it to work. I see the playlist in the UI but when I try to play it nothing happens (empty queue).

Could anybody please let me know if this is possible and what format should I use? (the playlists will be generated by a script based on some criteria I will come up with and I prefer to have them in a different branch than the music so I cannot use relative paths because I have to go "up" in the folder structure at least once).




Thanks!
Adrian



S Y S T E M   P A R A M E T E R S

moOde release = 6.5.2 2020-05-03
Raspbian OS = 10.3
Linux kernel = 4.19.115-v7l+ #1305
Platform = Pi-4B 4GB v1.1
Architecture = armv7l (32-bit)


RE: m3u with absolute paths - adixor - 08-01-2020

(08-01-2020, 08:24 PM)Additional info Wrote: When I try to use /NAS/Music/x1/file.mp3 in the playlist, Verbose logging for mpd says this:

[...]
Aug 01 22:29 : client: [113] process command "add "/mnt/NAS/Music/x1/file.mp3""
Aug 01 22:29 : exception: Access denied
Aug 01 22:29 : client: [113] command returned 2
Aug 01 22:29 : client: [113] process command "play 0"
Aug 01 22:29 : exception: Bad song index
[...]

Same when I try the playlist entry without the /mnt in front (/NAS/Music/x1/file.mp3).



adixor



RE: m3u with absolute paths - adixor - 08-01-2020

I found something else in here:

https://www.musicpd.org/doc/html/protocol.html

this

Quote:Stored playlists

Playlists are stored inside the configured playlist directory. They are addressed with their file name (without the directory and without the .m3u suffix).
Some of the commands described in this section can be used to run playlist plugins instead of the hard-coded simple m3u parser. They can access playlists in the music directory (relative path including the suffix), playlists in arbitrary location (absolute path including the suffix; allowed only for clients that are connected via local socket), or remote playlists (absolute URI with a supported scheme).

Not sure if this is related as it seems to be about playlist location not the location of the files in the playlist, also not sure how mpd is accessed (via local socket or otherwise).


RE: m3u with absolute paths [SOLVED] - adixor - 08-01-2020

Hmm.. Apparently I fixed it Smile had to add the full mpd path not the normal path. 

So now with this in the x2/playlist.m3u file:

/var/lib/mpd/music/NAS/Music/x1/file.mp3

it works!

(I have no problem with the fact that these playlists will only work with Moode, I won't used them any other way).