This is my first post.
I wanted to be able to share my video library across our private network. I purchased two AppleTV2's for just the airplay functionality. I was happy to find a couple of better solutions than Apples iTunes Home Sharing for my 500 Movies and TV Shows. I tried the first one, easy setup, but slow performance. Found out they forked XBMC and bounced away.
Then I bit the bullet and began the journey called XBMC.
I've started a OS X Server with the native MySQL Server running and created the database and advancedsettings.zml outlined in the LifeHacker post. This was pretty good... until I changed the title or artwork of a movie from an AppleTV or MAC OS X Client. POOF. Database gone from view. Run a nightly build? POOF! database gone.
DROP database, CREATE database... I'd say half a dozen times over 2 weeks until I concluded that it was the Apple TV's having WRITE access to xbmc_video!!!!! Oooooo.
Without fanfair, and purely for myself should I ever need it, here is how I'm set up today.
First, The MySQL 'my.cnf' needs a few performance tweeks.
Code:
[client]
socket = /var/mysql/mysql.sock
[mysqld]
skip-sync-frm
skip-thread-priority
skip-name-resolve
Second, Need to create the database users. We need a read/write and read only user.
Code:
CREATE USER 'xbmc' IDENTIFIED BY 'yourpassword';
CREATE USER 'xbmcadmin' IDENTIFIED BY 'adminpassword';
...and the databases.
Code:
CREATE database xbmc_video;
CREATE database xbmc_music;
...and grant the rights allowing the Server to write and the Apple TV's read only.
Code:
GRANT ALL ON *.* TO 'xbmcadmin';
GRANT ALL ON *.* TO 'xbmcadmin'@'localhost';
GRANT SELECT ON *.* TO 'xbmc';
Everything is cool at this point EXCEPT my Wife says that she can't stop watching in one room and resume from where she left off in the other room. In other words, a showstopper
So I investigated this a bit and came up with another GRANT...
Code:
GRANT ALL ON [b]xbmc_video.bookmark[/b] TO 'xbmc';
and another for Watched/Unwatched.
Code:
GRANT ALL ON xbmc_video.files to 'xbmc';
I then setup 2 SAMBA sharepoints with guest access on the OS X Server, 'Movies' and 'TV'.
During earlier setups I ran into mongo issues with thumbnails. After resolving that I wanted them outside the /Library, I put them on another drive and setup a SAMBA share point with guest access.
To get XBMC on the server pointed where I wanted it to go, I created a symbolic link in /XBMC to my chosen thumbnail folder.
Code:
ln -s /YourDesiredLocation/thumbnails/ /Users/USERNAME/Library/Application\ Support/XBMC/Thumbnails
Then I setup the advancedsettings.xml on SERVERNAME
Code:
<advancedsettings>
<videodatabase>
<type>mysql</type>
<host>SERVERNAME</host>
<port>3306</port>
<user>xbmcadmin</user>
<pass>ADMINPASSWORD</pass>
<name>xbmc_video</name>
</videodatabase>
<musicdatabase>
<type>mysql</type>
<host>SERVERNAME</host>
<port>3306</port>
<user>xbmcadmin</user>
<pass>ADMINPASSWORD</pass>
<name>xbmc_music</name>
</musicdatabase>
</advancedsettings>
... And the Apple TV's.
Code:
<videodatabase>
<type>mysql</type>
<host>SERVERNAME</host>
<port>3306</port>
<user>xbmc</user>
<pass>YOURPASSWORD</pass>
<name>xbmc_video</name>
</videodatabase>
<musicdatabase>
<type>mysql</type>
<host>SERVERNAME</host>
<port>3306</port>
<user>xbmc</user>
<pass>YOURPASSWORD</pass>
<name>xbmc_music</name>
</musicdatabase>
<pathsubstitution>
<substitute>
<from>special://thumbnails</from>
<to>smb://SERVERNAME/xbmc.thumbnails/</to>
</substitute>
</pathsubstitution>
</advancedsettings>
I then used XBMC on the Server with this Sources.xml
Code:
<sources>
<programs>
<default pathversion="1"></default>
</programs>
<video>
<default pathversion="1"></default>
<source>
<name>Movies</name>
<path pathversion="1">smb://USERNAME:PASSWORD@SERVERNAME/Movies/</path>
</source>
<source>
<name>TV</name>
<path pathversion="1">smb://USERNAME:PASSWORD@SERVERNAME/TV/</path>
</source>
</video>
<music>
<default pathversion="1"></default>
</music>
<pictures>
<default pathversion="1"></default>
</pictures>
<files>
<default pathversion="1"></default>
</files>
</sources>
Using XBMC, I added the 'Movie' and 'TV" as Sources and scraped the database. Reviewing and correcting the scraping errors over a day cleaned up the database and I exported from XBMC incase it went POOF again.
I'm glad to say it's ROCKING!!! The Apple TV's have "Movies" and "TV" with all artwork and resumability.
I wanted to say THANK YOU to anyone having to do with this project and kindly answering questions to those that ask.
TheRealDL