Configuring MySQL/MariaDB for SSB

After installing MySQL/MariaDB server, you must create a database and credentials for SQL Stream Builder (SSB) to be able to install the service on your cluster.

Before you begin

You need to install and configure MySQL or MariaDB based on which one you plan to use, before setting up the databases for SSB.

The following configuration only details the SSB specific steps. To install and configure MySQL or MariaDB, you must complete the basic steps in the Private Cloud Base documentation.

Creating MySQL/MariaDB database for SSB

You need to create the MySQL/MariaDB dabase that will be used for the Streaming SQL Console.

  1. Log in as the root user to MySQL:
    mysql -u root -p
    Enter password:
  2. Create databases for the Streaming SQL Console:
    CREATE DATABASE ssb_admin DEFAULT CHARACTER SET utf8 DEFAULT COLLATE utf8_general_ci;
  3. Grant all privileges for the created database:
    GRANT ALL ON ssb_admin.* TO 'ssb_admin'@'%' IDENTIFIED BY '<password>';
  4. Confirm that you have created the Streaming SQL Console database:
    SHOW DATABASES;

Installing the MySQL Python Connector

You need to install the 8.0.23 version of the MySQL python connector for SSB to connect to the MySQL database.

Use the following sample commands to install the correct version for MySQL:

RHEL

  1. Install the python-pip package:
    sudo yum install python3-pip
  2. Create a directory where you install the package:
    mkdir -p /usr/share/python3
  3. Install mysql connector 8.0.23 using pip:
    sudo pip3 install mysql-connector-python==8.0.23 -t /usr/share/python3

Ubuntu

  1. Install the python-pip package:
    sudo apt-get install python3-pip
  2. Create a directory where you install the package:
    mkdir -p /usr/share/python3
  3. Install mysql connector 8.0.23 using pip:
    sudo pip3 install mysql-connector-python==8.0.23 -t /usr/share/python3