In the past, I have talked about my transition to Synology and I recently made the next step: migration from iTunes to DS Audio. In this post I would like to talk about the process and a few obstacles I had to overcome. Read on to learn more!
Background
Note: This information is based on DSM 5.x — I have not upgraded to 6.x yet.
The most important and challenging part was migrating the existing iTunes playlists over to DS Audio. Given the size and quantity of playlists it was not feasible to attempt to manually recreate them. Given how custom the playlists were it was also not possible to leverage the smart playlist feature of DS Audio. This meant I needed to figure out a migration plan. While I did not find a lot of information on the Synology site, a few quick Google search turned up the information I needed. The process seemed pretty straightforward.
The Process
Export the playlists from iTunes in M3U format
Edit the export to adjust the paths
The paths will likely start with something like:
/Users/Username/Music/iTunes/iTunes Media/Music/
You will need to change this to the path of DS Audio, which by default would be
../
Upload the modified export to DS Audio
By default, DS Audio will pick up new changes automatically within a few seconds (or longer if you uploaded/changed a lot of data), but you can edit the settings by going to Control Panel > System > Media Indexing
The Problem
When I did this and returned to my playlist I noticed something was wrong (notice the red X next to each song):
The Solution
A little more digging online and I learned Mac iTunes exports playlists with CR line breaks, and they’re not recognized by audio station or ds audio. There are many ways to fix this. I did this on the command line:
cat file.m3u | tr '\r' '\n' > file.m3u
After this I could see my songs!
Other Problems
Once I solved the major issue, I did run into a couple other annoyances:
- Some song paths were not correct so the find and replace trick did not work — I suspect this was due to problems on the iTunes library and not DS Audio. The resolution is to find all the songs that show an error in DS Audio and then go manually adjust the playlist M3U file.
- UTF encoding in DS Audio matters! If it is not correct for any song then the song will not work in the playlist. My wife has some Spanish music and all of them were not working. The solution is to further adjust M3U exported from iTunes by running:
iconv -f UTF8-MAC -t UTF8 "file.m3u" > "file.m3u"
Summary
Migration to DS Audio was pretty easy and it seems to work well. The last question is will my wife like it enough to get off iTunes? Only time will tell!
© 2016, Steve Flanders. All rights reserved.
Hi, thanks so much for this, I’d been trying to figure out for ages why my iTunes playlists weren’t showing up even after I’d changed the file directory!
Thanks for the comment and I am glad this post helped!
I’ve just discovered that ds audio will not be seen through bmw system. Full integration seem to be only with itunes.
Interesting, thanks for sharing!
Hi Steve, interesting topic. Do you now if it is possible to create a Random Album playlist. The community and Synology won’t respond to my requests.
Hey Pollins — good question. Honestly, I have since moved away from DS Audio. We use a mix of Pandora and Spotify now. If I find out, I will let you know!
Hi Steve.
Thanks for your article. It’s been very helpful. I have a Synology NAS and a speaker that can read the music via DLNA. Exporting playlists from iTunes to DSAdio was the only way for the speaker to read the music on the NAS.
IMHO, I have found a simpler way for this task. You just need the free text editor app TextWrangler.
1. Export playlist in M3U (not M3U8) from iTunes
2. Open in TextWrangler
3. Replace paths as you said
4. “Save As…” changing Line Breaks to “UNIX (LF)”
Your M3U file is now usable by DSAudio
Beltran
Awesome — thanks for sharing!
Beltran,
Can you explain the process in a bit more detail? I’m currently trying to move playlists to DS and I’m getting the red x next to each song.
Specifically, can you explain steps 3 and 4?
Hi Steve,
I’m having the same issue with the X marks next to playlist songs. I’m pretty much a novice the command line (rsync, etc., is about all I can do).
Do I literally just copy/paste the command:
cat file.m3u | tr ‘\r’ ‘\n’ > file.m3u
Into the Terminal and it will fix all of my .m3u files? Or is there a hidden step that I’m missing?
Another question: When you write:
You will need to change this to the path of DS Audio, which by default would be
../
Do you literally mean the path is ../ or does that stand in for something?
I had already managed it myself, but this works well and faster indeed. Yet there is still 1 problem. Titles and names with strange characters are converted incorrectly when exported in iTunes. For example names with ï or é. This still does not work.
Steve,
Thanks for this resource. It enabled me to migrate successfully to Audio Station.
The one thing I would add is: Capitalization matters! Those of us who don’t mostly live in linux-verse forget this, to our peril.
In the meantime, I have a question I was hoping you can help me with, related to file path encoding. (This is an issue I’ve run into while attempting to migrate to Plex). I thought you might have some insight based on what you have written here.
The issue is words with special characters not being encoded correctly in URL-formatted filepaths.
For example: Queensrÿche is currently encoded in the filepath as “Queensry%CC%88che”
It should be “Queensr%C3%BFche”
Both of these appear to be acceptable URL encodings for the name. See: https://url-decode.com/tool/url-encode?text=Queensr%C3%BFcheQueensry%CC%88che=Queensry%CC%88che&mode=decode
But they are not equivalent.
Do you know what the correct designation is for these different encodings, such that I could maybe use iconv or a similar tool to bulk-fix the files?
Thanks for any insight you may have!
Brent