Rate This Document
Findability
Accuracy
Completeness
Readability

Installing the SQL Database

Install the SQL database on the controller node.

  1. Install the software package.
    yum install mariadb mariadb-server python3-PyMySQL python3-pyparsing-2.4.7-3.oe2203sp2
  2. Configure the /etc/my.cnf.d/openstack.cnf file.
    1. Open the file.
      vi /etc/my.cnf.d/openstack.cnf
    2. Press i to enter the insert mode and add the following content:
      [mysqld] 
      bind-address = 192.168.14.2 
      default-storage-engine = innodb 
      innodb_file_per_table = on 
      max_connections = 4096 
      collation-server = utf8_general_ci 
      character-set-server = utf8

      192.168.14.2 is the controller node IP address of the current node in the environment. You can replace it as required.

    1. Press Esc to exit the insert mode. Type :wq! and press Enter to save the file and exit.
  3. Start the SQL database service and configure it to automatically start upon system startup.
    systemctl enable mariadb.service 
    systemctl start mariadb.service
  4. Configure the preset password of the SQL database.
    mysql_secure_installation

    If MariaDB is installed for the first time, the password of user root is empty by default. You can press Enter to set a password for user root as required. The password cannot contain the characters including #@$ and can contain the special characters including &=-_.+!*()

    As shown in the following figure, perform subsequent operations.