Kodi Community Forum

Full Version: Frodo RC1/RC2 regression with mysql shared db
You're currently viewing a stripped down version of our content. View the full version with proper formatting.
Pages: 1 2
Having previously been able to create a remotely shared MySQL database, share it between 2 windows and a Linux (openelec or xbmcubantu) instance I am no longer able to connect this once moving to RC1 or RC2.

I have verified that another colleague is experiencing the exact same issues on a similar configuration. We have dropped all DBs, recreated xbmc user accounts and tried it on two different MySQL backends (synology nas and Linux)

Advanced settings, as previously used on Frodo betas which had no issues.

<advancedsettings>
<videodatabase>
<type>mysql</type>
<host>192.168.0.4</host>
<port>3306</port>
<user>xbmc</user>
<pass>xbmc</pass>
</videodatabase>
<musicdatabase>
<type>mysql</type>
<host>192.168.0.4</host>
<port>3306</port>
<user>xbmc</user>
<pass>xbmc</pass>
</musicdatabase>
</advancedsettings>


xbmc.log shows on RC1/ RC2 builds.

07:50:13 T:140730869622592 ERROR: Unable to open database: xbmc_music2 [2003](Can't connect to MySQL server on '192.168.0.4' (101))
07:50:13 T:140730869622592 ERROR: Unable to open database: xbmc_music1 [2003](Can't connect to MySQL server on '192.168.0.4' (101))
07:50:13 T:140730869622592 ERROR: Unable to open database: xbmc_music [2003](Can't connect to MySQL server on '192.168.0.4' (101))
07:50:13 T:140730869622592 ERROR: Unable to open database: xbmc_music32 [2003](Can't connect to MySQL server on '192.168.0.4' (101))
07:50:13 T:140730869622592 ERROR: Unable to create new database
07:50:13 T:140730869622592 ERROR: Unable to open database: xbmc_video75 [2003](Can't connect to MySQL server on '192.168.0.4' (101))
07:50:13 T:140730869622592 ERROR: Unable to open database: xbmc_video74 [2003](Can't connect to MySQL server on '192.168.0.4' (101))
07:50:13 T:140730869622592 ERROR: Unable to open database: xbmc_video73 [2003](Can't connect to MySQL server on '192.168.0.4' (101))
07:50:13 T:140730869622592 ERROR: Unable to open database: xbmc_video72 [2003](Can't connect to MySQL server on '192.168.0.4' (101))
07:50:13 T:140730869622592 ERROR: Unable to open database: xbmc_video71 [2003](Can't connect to MySQL server on '192.168.0.4' (101))

Any help would be appreciated.
I have the same issue. I even blew away the databases I did have in mysql and it recreated them, but after a reboot I now cannot connect. I am at a loss.

Running XBMCUbuntu and Apple TV2 - Frodo RC2 versions.

I hope someone has some suggestions on things to try.

Thanks

Toby
Were you ever able to resolve this issue?

I'm having the same problem.

Thanks
I haven't been able to resolve this yet Sad im going to install tcpdump and see what its up to
After doing a bit of testing I have got some more information.

1. Start up device from a cold boot (XBMCbuntu RC2)
--- xbmc.log shows that it cannot connect to the db.

2. Exit XBMC application (without rebooting)

3. Start XBMC by logging back in
--- xbmc.log shows that it CAN connect to the DB and movies/TV menu items get populated.
Put a "sleep 20" in the /etc/init/xbmc.conf or whatever config file launches xbmc, it sounds like it's starting before the network is up.
(2012-12-24, 07:26)Dilligaf Wrote: [ -> ]Put a "sleep 20" in the /etc/init/xbmc.conf or whatever config file launches xbmc, it sounds like it's starting before the network is up.

I thought this might be happening for my issue with openELEC as well, attempting to access mySQL before it has network connectivity.

See my thread here: http://forum.xbmc.org/showthread.php?tid=148936

So XBMC won't reattempt the database connection until the next reboot? Could a static IP fix this issue?
(2012-12-24, 07:26)Dilligaf Wrote: [ -> ]Put a "sleep 20" in the /etc/init/xbmc.conf or whatever config file launches xbmc, it sounds like it's starting before the network is up.

Thanks dilligaf. This solved my issue, I appreciate your comment.

For others with this issue:

I modified /etc/init/xbmcbuntu-wait.conf and added a "sleep 2", example below.

script
status xbmcbuntu | grep -q "start/running" && exit 0
sleep 2
start xbmcbuntu || true


For anyone interested I am running an Intel NUC, hardwired to the LAN with a static DHCP address. ASUS router providing DHCP.
Would this also apply to openELEC users?
(2012-12-24, 09:21)RAND0M1ZER Wrote: [ -> ]Would this also apply to openELEC users?

If you can edit the file, I think OpenElec uses squashfs

Thank you so much Dilligaf; your suggestion for the sleep fixed my issue. Actually this morning before I checked this forum, I was wondering if my issue was timing related. I was also getting an error in my path substitution command for my sources.xml (basically saying that it timed out trying to connect to the SMB share where I have sources.xml stored). I guess I was too tired last night to think straight (that and wrapping presents for the kids takes time!)

Thanks again and I hope everyone who struggles with XBMCbuntu and a MYSQL install sees this tread as something changed between the Frodo betas and this RC2 release with respect to the speed the network is brought online and the XBMC application begins it's startup.

Cheers

Toby
All these thanks and no one can be bothered to click on the plus sign at the bottom of the post?
(2012-12-24, 21:19)Dilligaf Wrote: [ -> ]All these thanks and no one can be bothered to click on the plus sign at the bottom of the post?

You would probably see by our post count we are new, but thanks again for future reference. You wont be getting one out of me for a snide comment like that.


Merry Christmas!
(2012-12-24, 09:21)RAND0M1ZER Wrote: [ -> ]Would this also apply to openELEC users?

I'm having the same issue with openelec. Just updated to "OpenELEC-Fusion.x86_64-2.95.6", which is great because the wireless network driver is now built-in for my Zotac Zbox AD04. Only problem is once installed, I can't connect to my shared MySQL database with any of the 2.9.x release candidate versions.

Taking Dilligaf's advice, I SSH'd into my openelec machine, and attempted to modify /etc/init.d/93_xbmc to add in a delay for a few seconds right before xbmc starts, but I can't make mods to this file due to being a system file, and being write protected. Not to mention I'm taking a shot in the dark that this would even be the correct file to modify. So for the time being I reverted back to v2.0.0 and I once again CAN connect to my database just fine.

Any additional help on this one would be greatly appreciated, as it does seem to be an issue with the Release Candidate versions of OE for several people.

- phpjunkie
As stated earlier I think OpenElect uses squashfs which you can't edit but did you try with sudo? Only other way would be to edit the file before building the image. I choose not to participate in the Raspberry Pi XBMC distro wars but I prefer Raspbmc as it's not locked down, they're all good and perform about the same.
Pages: 1 2