Kodi Community Forum

Full Version: Failed first attempt at mySQL shared DB
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Hi guys,

I tried and failed to successfully setup a mySQL shared DB yesterday. I followed the WIKI to the letter except synching thumbnails and any extra stuff.

Debug Log File -- this log file might be useless for this... sorry.

I don't really care about having a shared library, I just wanted to get it working. So why am i bothering you with this? I dunno... I'm a guy and I like getting things working and figuring out what's wrong. Smile

Now I like tinkering with this stuff so I will get back to it at another time, but I just thought I'd post my findings and see if anyone spots a step I've missed.

The import of my library seemed to work fine. All my titles were migrated to mySQL. (DBs were named "myvideos60 and mymusic18"). The log doesn't show the import, sorry.

Issues experienced:

1) Flags were missing. i.e. aspect ratio, path etc.... which caused my playlists to not pick up anything (They search via path). I noticed if I played a movie file, the flags came back for that specific file.

2) Update library didn't work? It didn't error in the log file. It just takes 0 seconds to update.

Config:

* Windows 7, XBMC Eden, NAS.
* Mapped drive M:\ on HTPC which points to my Media on the NAS

And a final sidenote question:

What does this error mean?

Code:
14:50:34 T:3340   ERROR: CRemoteControl::Connect - failed to connect
14:50:34 T:3340    INFO: CRemoteControl::Process - failed to connect to irss, will keep retrying every 5 seconds

What remote control is it trying to connect to?

Thanks for any help. Again, why am I bothering you with this? Well, the wife doesn't listen so I have to tell someone. Smile
OK. Found my issue to be path substitution and not setting it up properly. (Yes, my comment above about following the wiki to the letter was incorrect. I'm blind).

This is in my advancedsettings:

Code:
<substitute>
   <from>M:\Movies\</from>
   <to>SMB://192.168.1.106/Volume_1/Media/Movies/</to>
</substitute>

The normal Movies and TV Shows menus work fine, however I still haven't got my smart playlists to work properly as I'm confusing myself over this path subsitution stuff.

On my HTPC, M:\ is mapped to my nas share.

Questions:

1) Do I have to modify my sources on my HTPC to SMB shares as well as setup path substitution in advancedsettings.xml?
2) Depending on the answer to the above question; when setting up my playlists which select according to "Path" starts with "M:\Movies".... Do I know need to change them to "Path" starts with "\\192.168.1.106\etc...", or "smb://nas/etc..."
3) If I change my sources, is there any reason to have a mapped drive? I remember back with Dharma mapped drives worked best as I had issues with network shares...

Thanks.
Within playlists, you should use the path as in the database.

If the paths in your database are M:\ then you're heading for a world of hurt (mysql + win32 paths == problem).
Thanks jmarshall.

I guess I'll have to run a query on the DB to see what the path is set to. I guess my issue is I'm not 100% sure on how the path substitution works. I thought if I set it up as above, and then imported my old library, it would substitute the path in the mysql DB on import. Probably notHuh

When I get home from work I'll try the following, unless you or someone else suggests otherwise:

1) Revert to old xbmc database (non-mysql). Export library to separate files. (This will store all info on my shares).
2) Remove path substitution from my advancedsettings.xml
3) Edit ALL of my sources to SMB shares instead of the mapped windows drive.
4) Delete current mysql DBs
5) Run an update library
6) Test playlist

I'll query the DB to see what path is set. I'm assuming it will be smb://ipaddress/etc...

Are smart playlists rules case sensitive? smb == SMB?

Thanks again.
Ok.

I have it working now.

I found out that "clean library" doesn't seem to care what sources are listed. It just checks if the path for the item exists. If it does, the item is left in the library. So just modifying my sources didn't remove all the "old path" items from the library. You have to make sure xbmc can't access the path, then the files were removed.

Also, easy way to make your library look odd... set your TV Shows to type "movie". Smile

Anyone know if I need to run the mysql speed up tweaks, or does Eden already set the db up this way. Speed Up Tweaks linked from wiki

Ah and before I forget... emptying the library seems to also get rid of what content is set for each source. Once I cleaned the library and got rid of everything (only empty library left), it also reset my sources to have no content set. So I had to set them up again. (In case anyone has the same issue).

All the index tweaks from the wiki as far as I'm aware have been included. There may be some other things that may still be useful (I've heard some have success with IP vs hostname, but that's usually after they have severely slow connection times).
Ok, thanks. Yeah, I've used ip addresses already, and the skip-name-resolve for my.ini.

I'm quite happy with the speed.

Cheers for the help.
I have heard that mapping a share to a windows drive instead of connecting directly to the share over SMB through XBMC may slow things down considerably.

I think (but am not concrete on this) that it may have something to do with Windows caching of remote shares. Personally I added my Movies and TV shares via the SMB option in "Add Sources" and used IP address instead of hostname. But this is because I didn't want to enable write access to the shares for the rest of Windows (via Hostname) so that the Media Player integration in Windows can't willfully destroy my album art or litter my shares with hidden trash files. So windows connects via hostname with one password / username (with read-only access), and XBMC connects via IP address with a different username / password with write access.

Wink