3

I'm looking for provisioning a Debian 8.2 Virtualbox VM with MariaDB 10.

I use the following :

sudo export DEBIAN_FRONTEND=noninteractive
sudo debconf-set-selections <<< "mariadb-server mariadb-server/root_password password $ROOTDBPWD"
sudo debconf-set-selections <<< "mariadb-server mariadb-server/root_password_again password $ROOTDBPWD"
sudo debconf-set-selections <<< "mariadb-server mariadb-server/oneway_migration boolean true"
sudo apt-get install mariadb-server -y

When running, the script stop I think due to the last prompt "oneway_migration boolean true" because I can see this prompt unformatted in the console (even with "export DEBIAN_FRONTEND=noninteractive").

This is what I get before the script stops :

──────────┤ Configuring mariadb-server-10.0├────────────
MariaDB is a drop-in replacement for MySQL. It will use your current configuration file (my.cnf) and current databases.
Note that MariaDB has some enhanced features, which do not exist in MySQL and thus migration back to MySQL might not always work, at least not as automatically as migrating from MySQL to MariaDB.
Really migrate to MariaDB? <Yes><No>

Can anyone give me a hand on this or share the way they provision MariaDB 10(or more) with a shell script?

Thanks, Regards

3
  • are you migrating from mysql server to mariadb server in the vbox instance ? the last debconf-set-selection is normaly not needed if you are installing in first place, are you installing mariadb from debian repos or from mariadb repos ? Jan 7, 2016 at 4:18
  • 1
    @YonsySolis : You're right! I had to perform clean uninstall of mysql and after this I only have error on the root pwd. Jan 7, 2016 at 19:43
  • // , Can you rephrase the title for this as a question? Jun 12, 2018 at 1:31

1 Answer 1

2

the problem is that the questions don't come from package mariadb-server, the questions come from mariadb-server-10.0 (the first install the later one).

change your debconf set selections to:

sudo debconf-set-selections <<< "mariadb-server-10.0 mariadb-server/root_password password $ROOTDBPWD"
sudo debconf-set-selections <<< "mariadb-server-10.0 mariadb-server/root_password_again password $ROOTDBPWD"
sudo debconf-set-selections <<< "mariadb-server-10.0 mariadb-server/oneway_migration boolean true"
2
  • Thank you for your help. Is there a way to use something like mariadb-server-* or I need to mariadb-server-10.0 ? Jan 7, 2016 at 19:39
  • man debconf-set-selections ... ... The first value is the name of the package that owns the question ... no * mentioned ... Jan 7, 2016 at 23:39

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .