Jump to content

MariaDB and xbmc


Recommended Posts

My issue is that I can't access the db from any remote host, hence XBMC can't even create the db.

 

I don't know how to understand needos FIRST TIME USERS GUIDE which is saying: "A completely empty database will be generated upon first run. You must secure it by creating users and passwords."

 

These are the required steps in general (XBMC Wiki: Setting up MySQL):

Get into the MySQL command line utility: $mysql -u root -p
Enter the following commands:
Type in: CREATE USER 'xbmc' IDENTIFIED BY 'xbmc'; and press return
Type in: GRANT ALL ON *.* TO 'xbmc'; and press return
Close out the command line tool with \q

 

But how can this be done?

Link to comment

I am also unable to utilise my existing XBMC database when using needo's MariaDB docker.  The problem seems to be that there are values specified in the my.cnf file which conflict with the existing database.  The MariaDB docker will start up and run fine with the database/configuration as delivered, however, as soon as I point it at my existing database, the docker fails with an error that the size of the ib_logfile0 size conflicts with the size specified in my.cnf.

 

For the time being, I have reverted to MariaDB running in an ArchVM.

I think you can delete that logfile and mariadb will create it when it starts.

 

No, it's not a 'standard' logfile.  It does actually hold data/table definitions.  I tried substituting the ib_logfile0 which comes with the docker container and the system complained of many missing definitions.

Link to comment

I am also unable to utilise my existing XBMC database when using needo's MariaDB docker.  The problem seems to be that there are values specified in the my.cnf file which conflict with the existing database.  The MariaDB docker will start up and run fine with the database/configuration as delivered, however, as soon as I point it at my existing database, the docker fails with an error that the size of the ib_logfile0 size conflicts with the size specified in my.cnf.

 

For the time being, I have reverted to MariaDB running in an ArchVM.

I think you can delete that logfile and mariadb will create it when it starts.

 

No, it's not a 'standard' logfile.  It does actually hold data/table definitions.  I tried substituting the ib_logfile0 which comes with the docker container and the system complained of many missing definitions.

PeterB, take a look at this.  http://octathorpeweb.com/blog/2012/06/12/fixing-innodb-error-log-file-ib_logfile0-is-of-different-size-error/

 

Another thing might be that InnoDB might not be an enabled plugin in needo's MariaDB.

Link to comment

My issue is that I can't access the db from any remote host, hence XBMC can't even create the db.

 

I don't know how to understand needos FIRST TIME USERS GUIDE which is saying: "A completely empty database will be generated upon first run. You must secure it by creating users and passwords."

 

These are the required steps in general (XBMC Wiki: Setting up MySQL):

Get into the MySQL command line utility: $mysql -u root -p
Enter the following commands:
Type in: CREATE USER 'xbmc' IDENTIFIED BY 'xbmc'; and press return
Type in: GRANT ALL ON *.* TO 'xbmc'; and press return
Close out the command line tool with \q

 

But how can this be done?

EdgarWallace,

I used HeidiSQL, a mySQL gui,  to create users and grant privileges.

Link to comment

eroz, this was the hint that was needed.

 

To give something back to the community let me summarize a step-by-step approach for those who want to migrate their MariaDB from any existing VM to Docker:

  1. [*]start HeidiSQL (Windows) or Sequel Pro (Mac), open the existing database of your VM. Export both music and movie databases as SQL files

[*]write down all accounts/permissions that you might need

[*]install needos MariaDB

[*]open your new MariaDB instance (user: root, NO password) with HeidiSQL/Sequel Pro and add users/passwords/permissions as written down in step 2

[*]change the IP of your advancedsettings.xml file (must be the IP of your server, e.g. <host>192.168.178.10</host>)

[*]fire up XBMC (this will create the databases)

[*]shut down XBMC

[*]open HeidiSQL/Sequel Pro once more, select the movie database and import the content of your movies.sql file that has been exported in step 1

[*]do the same for the music database

[*]you are done

Link to comment

eroz, this was the hint that was needed.

 

To give something back to the community let me summarize a step-by-step approach for those who want to migrate their MariaDB from any existing VM to Docker:

  1. [*]start HeidiSQL (Windows) or Sequel Pro (Mac), open the existing database of your VM. Export both music and movie databases as SQL files

[*]write down all accounts/permissions that you might need

[*]install needos MariaDB

[*]open your new MariaDB instance (user: root, NO password) with HeidiSQL/Sequel Pro and add users/passwords/permissions as written down in step 2

[*]change the IP of your advancedsettings.xml file (must be the IP of your server, e.g. <host>192.168.178.10</host>)

[*]fire up XBMC (this will create the databases)

[*]shut down XBMC

[*]open HeidiSQL/Sequel Pro once more, select the movie database and import the content of your movies.sql file that has been exported in step 1

[*]do the same for the music database

[*]you are done

Awesome!  Glad you got it worked out.  And I'm sure your steps will help someone else out and still apply if you are moving from docker to VM.
Link to comment

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...