Mysql not found in 9.0.2

Hi guys,

I have recently tried to enable my CE for an external MariaDB.
I have setup everything just fine on database side. I can connect from other clients using the same credentials as entered in the advancedsettings.xml file.
However, I am still getting this on startup of CE:
2015-01-01 01:00:18.186 T:3982676848 ERROR: Unable to open database: MyVideos86 [2002](Can't connect to MySQL server on '192.168.11.54' (101)) 2015-01-01 01:00:18.186 T:3982676848 ERROR: Unable to open database: MyVideos85 [2002](Can't connect to MySQL server on '192.168.11.54' (101)) 2015-01-01 01:00:18.186 T:3982676848 ERROR: Unable to open database: MyVideos84 [2002](Can't connect to MySQL server on '192.168.11.54' (101)) 2015-01-01 01:00:18.186 T:3982676848 ERROR: Unable to open database: MyVideos83 [2002](Can't connect to MySQL server on '192.168.11.54' (101)) 2015-01-01 01:00:18.186 T:3982676848 ERROR: Unable to open database: MyVideos82 [2002](Can't connect to MySQL server on '192.168.11.54' (101)) 2015-01-01 01:00:18.186 T:3982676848 ERROR: Unable to open database: MyVideos81 [2002](Can't connect to MySQL server on '192.168.11.54' (101)) 2015-01-01 01:00:18.186 T:3982676848 ERROR: Unable to open database: MyVideos80 [2002](Can't connect to MySQL server on '192.168.11.54' (101)) 2015-01-01 01:00:18.186 T:3982676848 ERROR: Unable to open database: MyVideos79 [2002](Can't connect to MySQL server on '192.168.11.54' (101)) 2015-01-01 01:00:18.186 T:3982676848 ERROR: Unable to open database: MyVideos78 [2002](Can't connect to MySQL server on '192.168.11.54' (101)) 2015-01-01 01:00:18.187 T:3982676848 ERROR: Unable to open database: MyVideos77 [2002](Can't connect to MySQL server on '192.168.11.54' (101)) 2015-01-01 01:00:18.187 T:3982676848 ERROR: Unable to open database: MyVideos76 [2002](Can't connect to MySQL server on '192.168.11.54' (101)) 2015-01-01 01:00:18.187 T:3982676848 ERROR: Unable to open database: MyVideos75 [2002](Can't connect to MySQL server on '192.168.11.54' (101)) 2015-01-01 01:00:18.187 T:3982676848 ERROR: Unable to open database: MyVideos116 [2002](Can't connect to MySQL server on '192.168.11.54' (101))

There are of course no DBs existing like that - it is the first time I am trying to do that setup.
I have also tried to connect to mysql using the direct mysql command inside the SSH shell:
mysql -u root -p <password> MyVideos116
I am getting the following:
-sh: mysql: not found

It appears that in CE 9.0.2 (at least on my machine), there is no mysql support at all as the binaries are missing.
What could I do in order to get this working?
Thanks for your help!

Kodi starts by looking for the video database version that it wants - in 9.0.2’s case that’s (I think) MyVideos116.db. If it can’t find it it goes looking for an older version to update, which is what’s happening in your log.
Do you have anything else running leia that uses that mysql MyVideos116.db?
Is it able to connect to the server?

Hi trogggy,
as I tried to say: There is no DB existing as I have never had that setup. So I would expect CE to create the DB it needs - which does not happen.
Also, the direct usage of mysql is not working. I think Kodi relies on what is offered by CE and apparently mysql is not found.
I can try out with a different Kodi version on a different machine, but can only tell by tomorrow.
Thanks!

Main problem is probably

Can't connect to MySQL server on '192.168.11.54'

which means Kodi can’t even connect to that MySQL server.

For mysql command you can try to install mariadb addon from coreelec repo. After use remove the addon because it install mariadb server too.

That appears to be the solution.

1 Like

Does that mean you have an existing (working) mysql database on another device but with no leia version accessing it (in other words all your other clients are running krypton or earlier)?
CE works fine with mysql on a remote machine.

For Kodi you don’t need the mysql command on the bash, because Kodi includes its own mysql client.
Which version of mariadb is installed on your server?
Team Kodi declared some versions of mysql and mariadb as deprecated.

Also enable “Wait for network before starting Kodi” because main problem I see is that Kodi can’t connect to db server.
Regarding mysql command: I though the purpose is to check connection with a server. Obviously it is not needed for normal use.