Install MariaDB on Centos 7

  1. 在MariaDB官网找到对应系统版本的repo
    https://downloads.mariadb.org/mariadb/repositories/#distro=CentOS&distro_release=centos7-amd64--centos7&mirror=nethub&version=10.4
    down-repo.png

    新增 /etc/yum.repo.d/MariaDB.repo
# MariaDB 10.4 CentOS repository list - created 2020-04-15 02:50 UTC
# http://downloads.mariadb.org/mariadb/repositories/
[mariadb]
name = MariaDB
baseurl = http://yum.mariadb.org/10.4/centos7-amd64
gpgkey=https://yum.mariadb.org/RPM-GPG-KEY-MariaDB
gpgcheck=1
  1. 安装
    yum install MariaDB-server MariaDB-client -y
  2. 启动服务后的安全配置
    mysql_secure_installation

你可能感兴趣的:(Install MariaDB on Centos 7)