Installing MySQL

You must install MySQL for IBM Financial Transactions Repository.

For a small topology installation, install MySQL on the hadoop.master node computer. For a medium topology installation, install it on the hadoop.secondary node computer.

Procedure

  1. Log in to the hadoop.master or the hadoop.secondary computer.
  2. Run the following command to create a mysql.repo in the /etc/yum.repos.d directory.
    vi /etc/yum.repos.d/mysql.repo
  3. Add the following text to the mysql.repo file:
    [mysql-connectors-community]
    name=MySQL Connectors Community
    baseurl=http://repo.mysql.com/yum/mysql-connectors-community/el/7/$basearch/
    enabled=1
    gpgcheck=0
    gpgkey=file:/etc/pki/rpm-gpg/RPM-GPG-KEY-mysql
    [mysql-tools-community]
    name=MySQL Tools Community
    baseurl=http://repo.mysql.com/yum/mysql-tools-community/el/7/$basearch/
    enabled=1
    gpgcheck=0
    gpgkey=file:/etc/pki/rpm-gpg/RPM-GPG-KEY-mysql
    
    # Enable to use MySQL 5.5
    [mysql55-community]
    name=MySQL 5.5 Community Server
    baseurl=http://repo.mysql.com/yum/mysql-5.5-community/el/7/$basearch/
    enabled=0
    gpgcheck=0
    gpgkey=file:/etc/pki/rpm-gpg/RPM-GPG-KEY-mysql
    
    # Enable to use MySQL 5.6
    [mysql56-community]
    name=MySQL 5.6 Community Server
    baseurl=http://repo.mysql.com/yum/mysql-5.6-community/el/7/$basearch/
    enabled=1
    gpgcheck=0
    gpgkey=file:/etc/pki/rpm-gpg/RPM-GPG-KEY-mysql
  4. Save and close the file.
  5. Ensure that you do not have the mariadb packages installed.

    If you do, you must remove them. You can check to see if you have the mariadb packages installed by running the following command:

    rpm -qa | grep mariadb

    If you do have the packages installed, run the following command to remove them:

    rpm -e --nodeps <package_name>
  6. Run the following commands to install MySQL:
    yum -y install mysql-community-release-el7-5.noarch
    yum -y install mysql-community-common-5.6.39-2.el7.x86_64
    yum -y install mysql-community-libs-5.6.39-2.el7.x86_64
    yum -y install mysql-community-client-5.6.39-2.el7.x86_64
    yum -y install mysql-community-server-5.6.39-2.el7.x86_64