A neat new feature of the work-in-progress XBMC 10, aka Dharma, is it can keep its Libraries in a MySQL database. With the database, your multiple installation of XBMC (in the living room, bedroom, your Mac etc) can all share just one central library. You no longer have to repeat adding new movies manually to all your machines. Best of all, you can stop watching a movie in one location (the living room), and continue without skipping a beat in another (the bedroom). That’s right, no more fast forwarding to find where you were.

The reference tutorial to set up this feature is here. Go read up on the relatively simple instructions.

Unfortunately the tutorial does not detail how to install MySQL for our dear Mac OS X, and here’s where I pick up the task.

  1. First, download the .dmg for your version of Mac OS X from here. I’m using “mysql-5.1.51-osx10.6-x86_64” for my iMac running on Snow Leopard[1] (Works great in Lion too).
  2. Mount the downloaded .dmg, and inside you’ll find two .pkg and one .prefPane files. Double-click to install all three files on one of your Mac that you keep running 7/24.
  3. Go to System Preferences -> MySQL, and click on “Start MySQL Server”.  You’ll also want to tick to enable the “Automatically … on Startup” option.
  4. Launch the Terminal app on your Mac and issue the following commands, one line at a time:
    • sudo /usr/local/mysql/bin/mysql
    • CREATE USER 'xbmc' IDENTIFIED BY 'xbmc';
    • CREATE database xbmc_video;
    • CREATE database xbmc_music;
    • GRANT ALL ON *.* TO 'xbmc';

Done! You now have MySQL running and ready to accept your XBMC library. Just follow the mentioned tutorial to finish up the setup.

[1] I have a G4 Mac mini which I prefer to use as the MySQL server, but I’m not able to find a PPC version of the MySQL installation package. If you know where I could download a PowerPC Mac OS X 10.5.8 Leopard compatible version of MySQL, please do let me know. Thank you.