Saturday, January 31, 2009

Mediatomb and Playlists

I found a few issues adding playlists (m3u files) to Mediatomb. It works, but there are problems I have not been able to completely pin down. The main thing is that I have to add the individual playlist files to Mediatomb rather than depending on a timed rescan or a directory. When I time-rescan a directory containing a new playlist (only), the load operation appears in the Mediatomb console, but the playlist never appears in the database. If I add the single file however, and the list file has not been previously scanned, it works.

Also, once a directory is processed by a timed rescan, I have trouble adding new playlist files, individually, from that location. A couple of weeks ago, inexplicitly, a playlist I had previously used without trouble disappeared from Mediatomb, and I could not add it back (no errors, it just didn't show up). I removed my other playlists and found I could not add those back either. So I made a brand new file, and that would not add. To fix this I had to be sure that the directory and all playlists were removed from Mediatomb, and there were no timed rescans on that folder. I added back each m3u file individually, and they worked fine.

I think it's best to stay away from timed rescan, on my installation away, for playlists (I've had no trouble with rescans of music, video and photo files). I should note that this feature is supposed to work. And I should note that I have seen Mediatomb pick up m3u files on timed rescans from my music folders in the past. But from my playlist directory, I've had odd behaviors (no, this is not related to file/diectory permissions in my case, that is a common problem though. Check that if it is not working for you).

For creating playlists I have been using fapg. This worked well for me because I had already some long lists of files to work with and fapg can take these simple lists on stdin. Many people that use Mediatomb and similar servers use other media handler just to create playlists. I have been experimenting with juk. Juk seems to be particularly suited to larger collections (a problem I have with many of these tools is that they simply have not been designed for large and well organized media collections, with correct tags and such). There are other choices. I've seen Rhythmbox mentioned quite a bit. Such tools tend to support media playing or streaming on their own, but they also have nice playlist editors and search features that are useful alone.

One of the reasons I have been working to replace the system I had built myself, is that more standard bits and pieces (like m3u files) will allow me to use a variety of off the shelf packages (there are any number of programs available to edit playlists and now I can use any one, or more than one). There are also other servers and clients that support the same protocols. One does not have to be limited to one combination, if one server is better than another for, say, one type of content or another.

8 comments:

Anonymous said...

Hi Jeff,

Thanks for the follow-up but I'm still struggling. I now have a playlist visible in MT. Double clicking it (via UI browser on PC) opens WMP and plays the tracks. Great but not the point.

On the PS3, the playlist appears as "unsupported data". I know the PS3 has adheres very strictly to the DLNA standards and UPnP protocols and am wondering whether the .m3u playlist must be of the fully extended type? ie. include track length, etc, etc? Any ideas?

If you could post a snippet from one of your playlists so I could see the format and also maybe a snapshot of how exactly the playlist is defined in MT (in particular, object/mime type), that would be a great help.

elgintime said...

Sure, here's the first part of a playlist I have used:

#EXTM3U
#EXTINF:350,Art Blakey - Never Never Land
/mp3/jazz/ArtBlakey/Kyoto/audio_02.mp3
#EXTINF:512,Art Blakey - Nihon Bash
/mp3/jazz/ArtBlakey/Kyoto/audio_04.mp3
#EXTINF:393,Dexter Gordon - Cheese Cake
/mp3/jazz/DexterGordon/Go/audio_01.mp3
#EXTINF:321,Dexter Gordon - Where Are You
/mp3/jazz/DexterGordon/Go/audio_05.mp3
#EXTINF:507,Tito Puente - Medley
/mp3/latin/TitoPuente/ElRey/medley.mp3
#EXTINF:479,Art Pepper - Rita-San
/mp3/jazz/ArtPepper/NoLimit/audio_01.mp3
#EXTINF:525,Art Pepper - Ballad Of The Sad Young Men
/mp3/jazz/ArtPepper/NoLimit/audio_02.mp3
#EXTINF:569,Art Pepper - My Laurie
/mp3/jazz/ArtPepper/NoLimit/audio_03.mp3
#EXTINF:761,Art Pepper - Mambo Da La Pinta
/mp3/jazz/ArtPepper/NoLimit/audio_04.mp3
#EXTINF:758,Art Pepper - No Limit

One thing about the PS3 is that you have to be in the music part of it's menu to play music. Mediatomb will show up under video and photos also, with the same objects, but music will only play under music, videos under video, etc.

Also check that your playlist shows up in Mediatomb's database. It should create a new Playlist heading for these objects. This heading shows up on the PS3 also.

Anonymous said...

You said "Also check that your playlist shows up in Mediatomb's database. It should create a new Playlist heading for these objects. This heading shows up on the PS3 also."

How exactly are you manually importing the playlist if MT should automatically create a new container for them?? I created a new container then added a new item.

elgintime said...

On the left hand side of the Mediatomb web application is a browser that can be selected as either database or file system (up at the top is the selector). What I do, to add the first m3u file, is use this Mediatomb web app on the file system side (as opposed to the database side), browse the m3u file, select it and click the plus sign. Then, switching to the database side, I see a new "Playlist" section added, and the new playlist file listed there. Subsequently added m3u files appear under that heading also. And that heading then also appears on the PS3. The Playlist heading is not there until the first playlist file is added.

Anonymous said...

I got it working!!

I finally figured out why when clicking the +, nothing whatsoever happened - the contents of my .m3u file couldn't be found. This is what every playlist creator I tried output:

#EXTINF:250, - -
\\DAB-SLUG\disk-1\MB-Media/MB-Music\MISC\James Morrison ft. Nelly Furtado - Broken Strings.mp3

My MediaTomb installation is actually running on the DAB-SLUG device (an Unslung Linksys NSLU2). disk-1 is the HD storing all the media. I needed to replace all references to //DAB-SLUG/disk-1 with /public and swap the slashes around. BINGO!

For completeness, a sample playlist entry for MT running on a SLUG should be of the form:
#EXTINF:250, - -
/public/MB-Media/MB-Music/MISC/James Morrison ft. Nelly Furtado - Broken Strings.mp3

Many thanks for your assistance. I hope this page serves to help others as (previously) frustrated as I.

elgintime said...

Mediatomb is pretty quiet when it comes to error messages. I'm not surprised by this.

You might investigate one of the other supported playlist formats (I didn't), as well as other tools to create playlists. You can hopefully find a combination of tools that gets you good functionality.

Dieter said...

I got it working as well!

I am running the file server ib-nas4220-b from Raidsonic and installed MediaTomb on that box.
m3u's are located in '\\Ib-nas4220-b\guest-share\Playlists'.

I created the m3u's with 'Playlist Creator 3.5' configured as follows:
- playlist items with relativ path
i.e '../MP3_Pop/Ekseption/Ekseption_-_Ekseption_plays_Bach/194_01_Ekseption_-_Italian Concerto.mp3'
- use slashes instead of backslashes as 'Anonymous' found out
- add folders in recursiv mode

Only if created this way MediaTomb will generate the playlists folder and adds it to the database.

I am using the Sangean WFT-1 Internet Radio which gets access to the MediaTomb server in the home network
and after creating the playlists as mentioned I got as well access to the playlist songs.

Anonymous said...

Thing with MT is, it needs a *nix resolvable path, be it either a relative or an absolute path. So, if your music is stored under /home/user/mp3/, your playlist should either state this:

/home/user/mp3/first song.mp3

or this:

./first song.mp3

The latter is correct if the playlist is stored in the same directory "first song.mp3". Or, better said: files are searched for beginning from the playlists directory.

Rob

Jeff Sexton

007 1:144 Scale 1:350 Enterprise 10 Barrel Brewing 14 1856 2001 A Space Odyssey 3D modeling 40and20 4th of July 78 RPM Abyss Adam West Advertising Agora Models Air Canada Airline Airways Brewing Alan Bennett Alaska Alberta Alberta Street Pub Alfa Romeo Spider Touring Gran Sport Amati Amazon Amnesia Brewing AMT Analog signal Android Anomalies and Alternative Science Antiques Apache Apollo Apple Apple Stores Art Artisanal Beer Works Assembly Brewing Aston Martin Astoria Asus Atlas Audrey Augmented reality Aurora Famous Fighters auto-awesome Automobile Autos Aviary Aviation Backups Baelic Brewing Bale Breaker Brewing Bandai Barack Obama Barley Brown's Beer Bars Base Camp Brewing Batman Battery Beards Beer Beer Bar Bell System Bellwether Berkshire Hathaway Betty White Beyond the Fringe Bigfoot Bikes Bill Clinton Bird Food Bird Toys Birds Birthdays Bleriot Bleriot XI Block 15 Brewing Blogger Bojack Horseman Bolton Landing Brewing Boltons Boneyard Brewing Books Boxer Ramen Boxer Ramon Breakside Brewing Brian Eno Build Management Buoy Brewing Burger King Business and Economy Business Process Execution Language Bye & Bye Byte-order mark Canadian Carrot Cats Chex Mix Chihuly Chipmonk Christmas Civil Defense Clinton Clocks Closet Doors CNN Cockatiels Cocktails Collections Columbia Grafonola Columbia River George Columbia River Gorge Corners Corvallis County Cork Crooked Stave Brewing Crows Crux Brewing Cuisinart Culmination Brewing David Byne DB5 Dear Jane Debian Deschutes Brewing DFW C.V Diabetes Dick Curtis Digital Living Network Alliance Digital television Dinosaurs Disney Doll House Don the Beachcomber Double Mountain Brewing Dow Jones Industrial Average Dragons Dudley Moore Duesenburg SJ Roadster Durham University DVD E-mail address E9 Eagle Eagle Creek Fire Eaglemoss Easter ebauche Ecliptic Economics Ed Ed and Olive Eels EJB Elgin Elysian Brewing Energy development Enterprise Enterprise JavaBean ESP Evergreen Air Museum Everybody's Brewing Ex Novo Brewing F-84G Thunderjet Facebook Family Photos Fathers Day Fearless Brewing Fedora Ferment Brewing Ferns Festival of The Dark Arts Filesharing Finance Finger Firesign Theater Fireworks Flowers Flying Sub Food Ford Fort George Brewing Fossil fuel Free House Garfield James Abram Garfield Minus Garfield Gateway Brewing Gene Sexton Gene Wilder George Carlin Gigantic Brewing Gilgamesh Brewing Glass Glassfish Global warming Golden Arches Goldfinger Goofy Google Google Assistant Google Buzz Google Docs Google Home Google Lively Google Photos Google Reader Google Wave Google+ Goose Graffiti Grammar Gravy Great Divide Brewing Great Notion Brewing Greek Festival Greenhouse gas Gruen GT40 H. G. Wells Half-Life 2 Halloween Harlan Hawaii Helbros High-definition television Hilo Hilo Brewing History Ho 229 Hollywood Theater Hopworks Urban Brewery Horizon Models HP Hybrid electric vehicle IBM Impala Inner city Instagram Insulin Investing IPMS Iris Irony J.C. Penny James Bond Jane Austen Java Java Architecture for XML Binding JC Penny JDBC Jeannine Stahltaube Jeff's! Jim Davis joe the plumber John McCain Jonathan Miller Jubelale Kapaau Karma Kauai Kay Thompson Kermit the Frog Keys Keys Lounge Kids and Teens Kona LA Auto Show Labrewtory Larry King Laser Laserdisc Leavenworth Wenatchee River Level Brewing Lilly Tomlin linux Little Beast Brewing Lloyd Center Logging Lowry Sexton LPs Lucky Lab Magnets Mark Cuban Market trends Martin Mull Maytag McDonald Mediatomb Meier and Frank Mel Brooks Mercury Microsoft Microsoft Windows Migration Brewing Mobius Models modern Times Brewing Money Monkey monsters Moon MOUNT HOOD Mount Tabor Movie Reviews Multnomah Falls Music Music industry Muxtape MySQL NetBeans Netflix Nikon Nikon Z50 Ninkasi Brewing Nintendo Nissan Cube Norm Coleman North Bar Nuclear fallout Nuclear warfare Nuggest Nuts OBF Office Depot Offshoot Beer Co Oktoberfest Ola Brewing Old Town Brewing Olive Open ESB Oracle Corporation Orca Oregon Orion Space Clipper Otto Owls Pacific Ocean Packard Boattail Pam American Parrots Patio Sale PDX Pearl District Pearl District Portland Oregon Peppers Performance Review Peter Cook Peter Iredale Pets Pfriem Brewing Philip K Dick Phone Book photography Pizza Plank Town Brewing Play Station PlayStation 3 pluspora Pocher Podcast Poke Pokémon HeartGold and SoulSilver Polar Lights Politics Pono Brewing Portal Portland Portland Development Commission Presidents Pride and Prejudice Programming Projects PS3 PS4 Pumpkins Quotation Marks Rad Power Radio Radio Room Ramen Ramon Recipes Recording Industry Association of America Renewable energy Reservoir Reuben's Brewing Reubens Brewing RIAA Richmond Pub Robot Chicken Rock-paper-scissors Rogue Brewing Round 2 Sales San Francisco Santa Sarcasm Sasquatch Brewing SATA Science fiction film Sea Quake Brewing Seattle Selfie Serbia Service-oriented architecture Seward Shelby Cobra Shipwreck Shopping Signs Silver Moon Brewing Slide Rule Snow Soap Soap Cutter Social Security Social Studies Society6 Sony Sopwith F.1 Camel BR.1 Soviet Space 1999 Space Race Spad XIII Speaker Repair Spirit of St. Louis Spitfire SQL Squirrel's St Patricks Day Stanford Hospital Star Trek Star Wars Starbucks Stock market Storm Breaker Strip search Stripes Studebaker Studellac Sun Microsystems Supernatural T-Mobile Tablet Tamiya Tamiya Spitfire Taube TechCrunch Technical Television Terminal Gravity Thanksgiving The Producers ThinkGeek Three Creeks Brewing Thunder Island Brewing Tiki Time Bandits Toaster Tom Peterson Tools Top Ferment Total Recall Transportation Security Administration Trumpeter Tubboat Tyco UFOs Unicode United States United States Department of Homeland Security Universal Plug and Play Unknown Primates USB USS Yorktown Valcom Van Gilder Hotel Vegetable garden VHS Victoria Video Video game Vintage Images Vintage Vintage! Virtual world Volcano Hawaii Volvo C70 Voyage to the Bottom of the Sea Wall Street War of the Worlds Warren Buffett Warrenton watches Watercolor Wayfinder Brewing We Can Remember It for You Wholesale Web service Web Services Description Language Whiskey Wii Windows 7 Windows Phone 7 Windows Vista Windows XP Windy Wingnut Wings Wood Worthy Brewing WWI WWII X-Files X-ray vision XML XML Schema Y2K Yeti YouTube Yugo Zero Mostel Zima Zoom H2n