Description of problem: When a guest instance based on mariadb 5.5 (the default one shipped with RHEL) is started, the default configuration coming from the mariadb template contains two errors which prevent mariadb from starting. The template file is: trove/templates/mariadb/config.template Errors found: pid_file = /var/run/mysqld/mysqld.pid -> the directory /var/run/mysqld is not provided by mariadb-server-5.5.44-2.el7.x86_64 (it is provided by mariadb-galera-server-5.5.42-1.el7ost.x86_64 though). The temporary directory should be /var/run/maridb/ (so probably the default is a good choice, /var/run/mariadb/mariadb.pid ) !includedir /etc/my.conf.d/ -> the directory does not exist with both mariadb-server 5.5 and mariadb-galera-server 5.5; it should be /etc/my.cnf.d Version-Release number of selected component (if applicable): openstack-trove-common-4.0.0-2.el7ost.noarch openstack-trove-guestagent-4.0.0-2.el7ost.noarch python-trove-4.0.0-2.el7ost.noarch How reproducible: Steps to Reproduce: 1. Define a mariadb 5.5 datastore, with an associated instance with mariadb-server package preloaded (in addition to the guest agent, of course). 2. Create an trove instance based on mariadb 5.5 Actual results: The instance move to SHUTDOWN and the mariadb server can't start; the reported errors include: Initialization of MySQL database failed. Perhaps /etc/my.cnf is misconfigured. Expected results: Instance in ACTIVE state. Instances moves to ACTIVE state if the two parameters are fixes as described above in the templates included with the image.
Small correction: the templates need to be fixed in the control plane, as they are sent from there to the instance.
Also, /usr/lib/python2.7/site-packages/trove/templates/mysql/config.template has a datadir entry of /var/lib/mysql/data This is incompatible with the mysql 5.6 community RPM in that their systemd file is tuned to work with /var/lib/mysql. Using the upstream default can cause all manner of strange failures in the prepare phase like: "Access denied for user 'os_admin'@'localhost'" However, the upstream setting does seem compatible with the mariadb vendor RPMs. But those use init.d scripts which appear more resilient to the difference.
https://bugs.launchpad.net/trove/+bug/1370646 might be a reason NOT to do what's in #c2
The templates have been fixed, so that RHEL7.2-based mariadb instances can be created, namely mariadb 5.5 from RHEL repositories and mariadb 10 from community repositories. Verified on: openstack-trove-4.0.0-4.el7ost.noarch openstack-trove-api-4.0.0-4.el7ost.noarch openstack-trove-common-4.0.0-4.el7ost.noarch openstack-trove-conductor-4.0.0-4.el7ost.noarch openstack-trove-images-4.0.0-4.el7ost.noarch openstack-trove-taskmanager-4.0.0-4.el7ost.noarch python-trove-4.0.0-4.el7ost.noarch
Since the problem described in this bug report should be resolved in a recent advisory, it has been closed with a resolution of ERRATA. For information on the advisory, and where to find the updated files, follow the link below. If the solution does not work for you, open a new bug report. https://rhn.redhat.com/errata/RHBA-2016-0636.html