Sync iTunes Library between computers with BitTorrent Sync
At home I have an iTunes library of almost 200 music albums totaling 17GB. I also have multiple computers that I constantly use. At school and on the go I use my MacBook Pro and at home I use my Hackintosh.
The problem I now have is: How do I share my music collection between both machines and how do I keep them in sync?
There is an easy solution to this problem: stream music from services like Spotify or Deezer! I've been using Deezer for the last year because it's included with my internet subscription. I primarily use it to discover new music and I really like it. Deezer offers a large collection of music but not all my favorite artists are included. Bands like Metallica only offer a small selection of their music for streaming and others like AC/DC offer nothing at all!
While you can upload your own MP3s to get around these limitations it's not a nice experience. Also going offline can be a hassle if you haven't synced the songs you like. So having an iTunes library around is very nice, especially when you're offline.
When I discovered BitTorrent Sync, I thought: this is the best tool for syncing my music collection between machines!
Why BitTorrent Sync?
BitTorrent Sync is a free tool that allows you to sync files between your devices without using any cloud service. It currently supports Windows, OS X, Linux, iOS and Android. It's essentially a Dropbox alternative that runs on your hardware only. Like the BitTorrent protocol, everything is peer-to-peer. And because there is no central service, you can store and sync as much data as you want, for free!
This makes BitTorrent Sync incredibly interesting for syncing an iTunes library:
- No limits on file sizes. Sync as much data as you want. This is a huge deal when you want to syncing music files. Libraries tend to get quite big over time.
- Fast! BTSync goes as fast as your internet connection let's you.
There is however one downside to this solution: because there is no central place to store your data, you can only sync computers when they're online. When new content is added to one machine, it has to stay online until at least one other machine has finished syncing the new data. This might be a deal breaker for some use cases, but in case of an iTunes library it's not that important.
Setting everything up is very simple. In short: every machine that has your secret key can sync your folder. So all you have to do is select the folder to sync, generate a secret and use that secret to configure the remaining machines. Done!
- Open BitTorrent Sync
- Go to the 'Folders' tab and click the '+' sign
- Let BTSync generate a secret and give it the path of iTunes library
- Confirm by clicking 'Ok'
That's it! Our first machine is configured and ready to start syncing as soon as another machine is added. To add a second machine follow the same steps but use the secret key that was generated by the first computer. If you didn't copy the key, go back to BTSync and right click the folder. Now you can choose 'Copy secret'.
Read only key
Though this setup works perfectly, I was worried that the library might get corrupted when two machines are using iTunes at the same time. To prevent this from happening I made my Hackintosh a kind of 'master' and my MacBook a 'slave'.
I always add new music on my Hackintosh and copy it over to my MacBook. This means that my MacBook doesn't need to sync it's changes back to my Hackintosh. The way to set this is up in BitTorrent Sync is by using a Read-only secret.
- Open BitTorrent Sync
- Go to the 'Folders' tab and right click your iTunes folder
- Select 'Show folder preferences'
- A window pops up that shows you the Read-only secret
So I ended up copying the Read-only secret to my MacBook. That way, my MacBook never uploads local changes to my Hackintosh. Note that this isn't a requirement. I just feel safer doing it like this ;)
Depending on how large your iTunes library is, it can be quite a while before BitTorrent Sync finishes the first sync. To speed things up you could sync over LAN (through an ethernet cable, not WiFi!). Alternatively you could copy your iTunes library to an external HDD and place it on all your other computers. I picked the last option and it makes your first sync really fast. All BTSync then has to do is index your folder and verify that everything is in sync.
What about mobile?
BitTorrent Sync is also available for iOS and Android devices. I wondered if it was possible to stream my iTunes library to my iPad through BTSync. After scanning the QR code of my folder's secret, my iPad was all set up! This is how the iTunes folder looks on the iPad:
A bit messy, but it works! After digging in the folder structure (iTunes Library/iTunes Music/Music/) I found a list of folders for every artist in my library. Inside every artist folder are folders for each album of that artist. It's pretty nicely organized and quick to navigate.
You can even listen to songs from within the app. Simply select a song, wait for the download to finish and then 'Quick Look' the song. I was even surprised to find out that playback continues in the background when you switch to another app!
Songs start playing pretty quickly but they don't stream. The file has to be downloaded completely before it can be played. This might take some time depending on your internet connection.
Other supported devices
Besides running on Windows, OS X, iOS and Android, BitTorrent Sync also runs on Linux. That opens the door to a lot of possibilities. You could install BitTorrent Sync on a Linux based NAS devices (such as this one) or on your Raspberry Pi!
These devices can be kept running 24/7 to ensure you'll always have access to your music collection.
For me, BitTorrent Sync is the best solution for syncing an iTunes library between machines. It's fast, free and places no limits on file sizes. I've been using it for about a month now and I haven't had a single issue!
I'm definitely going to use BitTorrent Sync a lot more in the future! Not just for syncing my iTunes library.