Kodi Community Forum

Full Version: Problem with MySQL config.
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
I have troubles getting mysql to work. I followed the instructions in the wiki to the letter, but still xvmc crashes upon start.

What I have:
Fedora 19, MariaDB (mysql replacement) 5.5, xmbc 12.3

What I did:
- Configured the database server to listen to 0.0.0.0:3306, create a xbmc user.
- Given this user enough privileges. I've tested this by loving in as user xvmc, and creating and dropping database.
- created the advancedsettings.xml, with the following content:
Code:
<advancedsettings>
                                            <videodatabase>
                                                <type>mysql</type>
                                                <host>192.168.1.3</host>
                                                <port>3306</port>
                                                <name>xbmc_video</name>
                                                <user>xbmc</user>
                                                <pass>xbmc</pass>
                                              </videodatabase>
                                              <musicdatabase>
                                                <type>mysql</type>
                                                <host>192.168.1.3</host>
                                                <port>3306</port>
                                                <name>xbmc_audio</name>
                                                <user>xbmc</user>
                                                <pass>xbmc</pass>
                                              </musicdatabase>
                                              <videolibrary>
                                                <importwatchedstate>true</importwatchedstate>
                                                <importresumepoint>true</importresumepoint>
                                              </videolibrary>
                                            </advancedsettings>
What I expecct:
- As indicated in the wiki, I expected XBMC to connect to the database server and create its databases and tables.

What happened in stead:
- XBMC crashes:
- Crash log contains:
Code:
ERROR: SQL: SQL error or missing database
                                            Query: SELECT idVersion FROM version

Now according to the wiki this is caused by bad permissions, which is 100% certain not the case here.
I noticed that the advancedsetings.xml is read, as it is mentioned verbatim in the crash logs.

I also noticed that on first glance xbmc isn't even attempting to talk to the DB. There are no mentions in the mysql log file of some program trying something.

Now what could be the reason here? What have I overlooked?
As a first, try dropping the <name></name> part in your advancedsettings.xml and let xbmc use its own naming scheme. I know this has caused issues in the past.

If that doesn't fix it, get a debug log (wiki) and post it to pastebin or xbmclogs, and post a link back to it here.
(2014-07-03, 21:23)black_eagle Wrote: [ -> ]As a first, try dropping the <name></name> part in your advancedsettings.xml and let xbmc use its own naming scheme. I know this has caused issues in the past.

If that doesn't fix it, get a debug log (wiki) and post it to pastebin or xbmclogs, and post a link back to it here.

I had if without the "<name></name>" and it didn't work either. The info on the wiki is a bit confusing as one example contains these tags, and another doesn't.

I have also completely removed the advanced settings.xml and I still get the same error. Looks like something more fundamental.

I enabled debugging, but I do not get in more information. The resulting log file only contains 89 lines...

It ends with this:

Code:
19:55:05 T:140237467388096   DEBUG: CAESinkALSA::InitializeHW - Request: periodSize 2205, bufferSize 8820
19:55:05 T:140237467388096   DEBUG: CAESinkALSA::InitializeHW - Got: periodSize 2205, bufferSize 8820
19:55:05 T:140237467388096   DEBUG: CAESinkALSA::InitializeHW - Setting timeout to 200 ms
19:55:05 T:140237467388096   DEBUG: CSoftAE::InternalOpenSink - ALSA Initialized:
19:55:05 T:140237467388096   DEBUG:   Output Device : HDA Intel PCH
19:55:05 T:140237467388096   DEBUG:   Sample Rate   : 44100
19:55:05 T:140237467388096   DEBUG:   Sample Format : AE_FMT_S32NE
19:55:05 T:140237467388096   DEBUG:   Channel Count : 2
19:55:05 T:140237467388096   DEBUG:   Channel Layout: FL,FR
19:55:05 T:140237467388096   DEBUG:   Frames        : 2205
19:55:05 T:140237467388096   DEBUG:   Frame Samples : 4410
19:55:05 T:140237467388096   DEBUG:   Frame Size    : 8
19:55:05 T:140237467388096   DEBUG: CSoftAE::InternalOpenSink - Using speaker layout: 2.0
19:55:05 T:140237467388096   DEBUG: CSoftAE::InternalOpenSink - Internal Buffer Size: 17640
19:55:05 T:140237393688320  NOTICE: Thread CSoftAE start, auto delete: false
19:55:05 T:140237393688320    INFO: CSoftAE::Run - Thread Started
19:55:05 T:140237467388096   ERROR: SQL: SQL error or missing database
                                            Query: SELECT idVersion FROM version
Delete .xbmc/userdata/Databases/*.db (or rename each one individually until you find the problem) and restart xbmc... I think the error you are seeing is a SQLite error.

And please use pastebin.com or xbmclogs.org when posting logs, and best not to truncate logs as you have done.