• 1
  • 2
  • 3(current)
  • 4
  • 5
  • 41
HOW-TO:Share libraries using MySQL: Wiki Edition
#31
(2013-04-03, 06:15)ivanmmj Wrote:
(2013-04-02, 01:34)winestock Wrote:
(2013-03-28, 01:49)ivanmmj Wrote: Would you be interested in an addition to the Wiki on how to set this up in Arch with MySQL and/or MariaDB? I'm thinking of moving my server from Ubuntu to Arch as it's the only machine in the house that still runs Ubuntu and I figured I could always make a walkthrough as I do it.

I converted over not too long ago from mysql to mariadb for ALARM. Are you planning on updating: http://wiki.xbmc.org/index.php?title=HOW...ySQL/ALARM? I was planning on submitting some changes to Ned on this.

When you setup mariadb I suggest that you try out the myisam storage engine which I found was a lot faster then the default innodb storage engine for the purposes of XBMC.

The only thing I'd be afraid of with using myisam would be loss of data integrity. But then again, my server has a battery backup... Maybe I'll check it out. Have you tried any of the other storage engines?

The other storage engines I have tried is innodb and aria. Both are slower then myisam. I also have my server on battery backup. I backup the mysql data using mysqldump periodically. I also use the XBMC export to single file as another backup of the XBMC library. If I need to rebuild my XBMC library it would take me at most about 5 minutes using either of the backups.
Kodi 17, Transparency Skin
PogoPlug v4 running Arm Linux 4.4.63 as MySQL (mariadb) server.
Mac OS 10.12.5
2015 27" iMac 3.3 GHz Quad, 16GB RAM, 1TB SSD
2015 13" Macbook Pro, 8GB RAM, 256GB SSD
AppleTV 4 TV OS 10
Reply
#32
I'm not trying to hack this thread. But I use Plex Media Server and access it through XBMC and Plex Home Theater from different devices and different HTPCs... My only problem is with accessing Plex Media Server from XBMC, my homemenu widgets don't work because its grabbing my media from the video addon Plexbmc. Any work around for this?
Image
Reply
#33
Just following the Wiki to setup the MySQL database. I exported the library, then removed one of my movie sources

Movies-HD1 (G:\Movies-HD)

I then re-added it as:

Movies-HD1 (smb://ComputerName/Movies-HD1)

Seemed to go through quite quick and re-add all the movies. I then checked then recently added movies list and this still looks the same except the watched status seems to have been lost for any that have been watched

I checked the .nfo file for 1 and it shows

<playcount>1</playcount>
<lastplayed>2013-02-24</lastplayed>

Is this where it gets the watched status from? Have I done something wrong/missed something?

Thanks Smile
Reply
#34
Did you include this in your advancedsettings.xml file for the importing XBMC device?

Code:
<videolibrary>
     <importwatchedstate>true</importwatchedstate>
</videolibrary>

If not, you can remove the source, add that to your advancedsettings.xml file, and then reimport.
Reply
#35
Thanks Ned Scott. My fault.

Hadn't restarted XBMC since I added the advancedsettings.xml

Removed and re-added the source and the watched status seems to be there now
Reply
#36
Folks i'm using mysql and this query seems to be causing issues with the skin widgets service and as a result its slowing the opening of addons. Anything that can be done to speed it up? I have a large video library.

15:49:09 T:139864761595648 DEBUG: RunQuery took 118872 ms for 324 items query: SELECT * FROM tvshowview WHERE (tvshowview.idShow IN (select tvshowview.idShow from tvshowview where (watchedcount > 0 AND watchedcount < totalCount) OR (watchedcount = 0 AND tvshowview.idShow IN (select episodeview.idShow from episodeview WHERE episodeview.idShow = tvshowview.idShow AND episodeview.resumeTimeInSeconds > 0))))
Reply
#37
I suppose this is a good place to include my noob comments to this wiki page

It appears the options and walkthrough were current and worked fine for pre-5 releases of MySQL. At the best, I can only find a 5.0 release, but I can't find anything prior. Without *thinking* I went ahead with the obvious release 5.6

First Issue
  • Line 2 of this installation for Windows guide which indicates we should choose "Standard Configuration"
  • Here is what the *actual* options are
  • Of note, I first used "developer machine" to minimize memory usage. This makes a "resume from sleep" on OpenELEC lock up for 1-2 minutes. Not 10-30 seconds, literally over a minute
  • Re-doing the install and selecting "server machine" brings life back to ordinary for "resume from sleep" on the OE box. My typical memory usage is at about 4GB on the server, but other things are in use and I've yet to check how much mysql specifically uses

Second Issue
  • The advanced settings xml from that link doesn't ever build a music library in MySQL 5.6 as I'm aware
  • This could be a problem that exists only for me
  • According to this thread there is a problem unrelated to the MySQL version, but it seems others using pre-5 releases never had issue
  • The same member offered me advice to fix the issue here and I sadly haven't attempted to use it at this point. Another member indicated directly below that the script fixed the issue for them, but it's still on my to-do list
Reply
#38
(2013-05-28, 19:48)Dark_Slayer Wrote: Without *thinking* I went ahead with the obvious release 5.6

I guess you completely missed the big red box and Image "warning" sign? Get rid of 5.6 and start again with 5.5.

Oh and if anyone wants to synchronise their thumbnails/texture cache without hacks such as path substitution or rsyncing databases/folders... Texture Cache Maintenance is your friend. Smile
Texture Cache Maintenance Utility: Preload your texture cache for optimal UI performance. Remotely manage media libraries. Purge unused artwork to free up space. Find missing media. Configurable QA check to highlight metadata issues. Aid in diagnosis of library and cache related problems.
Reply
#39
First issue: The configuration screen you've linked to is actually something you shouldn't need to fiddle with at all for a Windows MySQL server install. It's only something you'll see if you dive deeper into the configuration wizard. See howtogeek.com's guide here and they mention using "standard" as well for 5.5: http://www.howtogeek.com/75535/how-to-sy...with-xbmc/

Quote:The MySQL configuration wizard will launch and present you with the option to select between Detailed and Standard Configuration. Select Standard Configuration and click Next.


Second issue: This is a known issue in XBMC. Until the bug in XBMC is fixed (and yes, it is a bug in XBMC, despite what that other user says), users should stay on 5.5.
Reply
#40
Thanks, and yes I missed the big red box and warning sign

I don't know how long it's been there, but I think I did this back in February and don't recall seeing it

Easy enough, 5.5 it will be (when I get to it)
Reply
#41
Is it possible to have 2 different MySQL databases sync with 1 user on multiple XBMC boxes? There are 2 different NAS boxes (both are on the same LAN) that contain files needing to be synced. How would the advancedsettings look?
Reply
#42
Two different databases accessed by the same client isn't possible (unless you use profiles, which might work, one database per profile).

But if what you want to do is have your XBMC clients access all of the media stored on the two different NAS devices, then that's entirely possible with a single MySQL database. Just add both NAS as sources on your clients (or just the scraper client), then scrape in the content to your single MySQL database. Add the MySQL database settings to the advancedsettings.xml on each client, which should then have access to all the media on the two NAS devices.
Texture Cache Maintenance Utility: Preload your texture cache for optimal UI performance. Remotely manage media libraries. Purge unused artwork to free up space. Find missing media. Configurable QA check to highlight metadata issues. Aid in diagnosis of library and cache related problems.
Reply
#43
Thanks. That makes sense to just have 1 central database for all media on all of the different NASs. I'm not sure why I was thinking to have 2 different databases.
Reply
#44
Finally getting a chance to switch my server to Arch, today. I'll be writing up the how to as soon as I get it set up. Note that Arch has switched to MariaDB so I'll be using that for the walkthrough instead of MySQL.
Reply
#45
Ok, finally got it done and updated the wiki in between the newborn napping. lol
I haven't had a chance to test it with XBMC, but that does allow me to access the database remotely through other means.
Reply
  • 1
  • 2
  • 3(current)
  • 4
  • 5
  • 41

Logout Mark Read Team Forum Stats Members Help
HOW-TO:Share libraries using MySQL: Wiki Edition2
This forum uses Lukasz Tkacz MyBB addons.