salt-stack hangs on installing mariadb in Ubuntu

385 views
Skip to first unread message

Aaron Galea

unread,
Sep 16, 2014, 3:18:06 AM9/16/14
to salt-...@googlegroups.com
Hi

I have been trying to install MariaDB on Ubuntu Trusty using Salt-Stack via Vagrant but it keeps getting stuck. Here is my sls for this:

mariadb-server-debconf:
  debconf
.set:
   
- name: mariadb-server-10.0
   
- data:
       
'mysql-server/root_password_again': {'type': 'password', 'value': 'root'}
       
'mysql-server/root_password': {'type': 'password', 'value': 'root'}
       
'mysql-server/start_on_boot': {'type': 'boolean', 'value': 'true'}


   
- require_in:
     
- pkg: mariadb-server


mariadb
-server:
  pkg
.installed:
   
- name: mariadb-server
   
- require:
     
- debconf: mariadb-server-debconf

#  cmd.run:
#    - names:
#      - 'LC_ALL=C DEBIAN_FRONTEND=noninteractive apt-get install -y mariadb-server'
#    - require:
#      - debconf: mariadb-server-debconf


  service
:
   
- running
   
- enable: True
   
- watch:
     
- pkg: mariadb-server

I think the problem is that this stops waiting for user input. Although I am setting mysql-server/root_password this seems to be overridden  on installing the package as querying debconf-get-selections I get the following:

>> debconf-get-selections | grep -i "mariadb"

# New password for the MariaDB "root" user:
mariadb
-server-10.0     mysql-server/root_password      password
mariadb
-server-5.5      mysql-server/root_password      password
# Repeat password for the MariaDB "root" user:
mariadb
-server-10.0     mysql-server/root_password_again        password        root
mariadb
-server-5.5      mysql-server/root_password_again        password        root
mariadb
-server-5.5      mysql-server-5.5/nis_warning    note
mariadb
-server-10.0     mysql-server/start_on_boot      boolean true
mariadb
-server-5.5      mysql-server/no_upgrade_when_using_ndb  error
# Unable to set password for the MariaDB "root" user
mariadb
-server-5.5      mysql-server/error_setting_password     error
mariadb
-server-5.5      mariadb-server-5.5/really_downgrade     boolean false
# Remove all MariaDB databases?
mariadb
-server-5.5      mysql-server-5.5/postrm_remove_databases        boolean false
mariadb
-server-5.5      mysql-server/password_mismatch  error
# Really migrate to MariaDB?
mariadb
-server-5.5      mariadb-server/oneway_migration boolean true



The mysql-server/password is not set. If I disable the maridb-server apt-get install in the sls above these values would be set correctly. So definitely they are being overridden on installing. 

Can anyone shed some light on this how to fix it as I already spent two days trying different things to make it work with no success? 

Regards
Aaron

kiorky

unread,
Sep 16, 2014, 4:35:40 AM9/16/14
to salt-...@googlegroups.com
--
You received this message because you are subscribed to the Google Groups "Salt-users" group.
To unsubscribe from this group and stop receiving emails from it, send an email to salt-users+...@googlegroups.com.
For more options, visit https://groups.google.com/d/optout.


-- 
Cordialement,
kiorky
GPG Key FingerPrint: 0x1A1194B7681112AF
Pensez à l’environnement. 
N’imprimez ce courriel que si vous en avez vraiment besoin.

Aaron Galea

unread,
Sep 16, 2014, 6:41:33 AM9/16/14
to salt-...@googlegroups.com
Hi Mathieu

Tried installing your patch using the following in Vagrant:

  config.vm.provision :salt do |salt|
    salt.minion_config = "salt/minion"
    salt.run_highstate = true
    salt.install_type = "git"
    salt.install_args = "f94f46e959543eeeefa6518e37aaf9c1ecf1a0d4"
  end

but it still hangs waiting when installing mariadb-server. :(
Reply all
Reply to author
Forward
0 new messages