반응형

1. 확인

[root@goni9071 ~]# rpm -qa | grep MariaDB


2. 저장소 추가

[root@goni9071 ~]# vi /etc/yum.repos.d/MariaDB.repo


[mariadb]
name = MariaDB
baseurl = http://yum.mariadb.org/10.1/centos7-amd64
gpgkey=https://yum.mariadb.org/RPM-GPG-KEY-MariaDB
gpgcheck=1


2-1. 저장소 확인

[root@goni9071 ~]# yum repolist


repo id                                                  repo name                                                                               status
base/7/x86_64                                            CentOS-7 - Base                                                                         10,019
epel/x86_64                                              Extra Packages for Enterprise Linux 7 - x86_64                                          12,745
extras/7/x86_64                                          CentOS-7 - Extras                                                                          321
mariadb                                                  MariaDB                                                                                     76
updates/7/x86_64                                         CentOS-7 - Updates                                                                         609
repolist: 23,770


3. 설치

[root@goni9071 ~]# yum install MariaDB-server


 
 
=======================================================================================================================================================
 Package                                   Arch                       Version                                        Repository                   Size
=======================================================================================================================================================
Installing:
 MariaDB-client                            x86_64                     10.1.37-1.el7.centos                           mariadb                      40 M
     replacing  mariadb.x86_64 1:5.5.56-2.el7
 MariaDB-server                            x86_64                     10.1.37-1.el7.centos                           mariadb                     104 M
     replacing  mariadb-server.x86_64 1:5.5.56-2.el7
 MariaDB-shared                            x86_64                     10.1.37-1.el7.centos                           mariadb                     1.3 M
     replacing  mariadb-libs.x86_64 1:5.5.56-2.el7
Installing for dependencies:
 MariaDB-common                            x86_64                     10.1.37-1.el7.centos                           mariadb                     123 k
 boost-program-options                     x86_64                     1.53.0-27.el7                                  base                        156 k
 galera                                    x86_64                     25.3.24-1.rhel7.el7.centos                     mariadb                     8.1 M
 jemalloc                                  x86_64                     3.6.0-1.el7                                    epel                        105 k
 lsof                                      x86_64                     4.87-6.el7                                     base                        331 k
 rsync                                     x86_64                     3.1.2-4.el7                                    base                        403 k
 
Transaction Summary
=======================================================================================================================================================
Install  3 Packages (+6 Dependent packages)
 
Total download size: 154 M
Is this ok [y/d/N]:
 
 
Downloading packages:
경고: /var/cache/yum/x86_64/7/mariadb/packages/MariaDB-10.1.37-centos73-x86_64-common.rpm: Header V4 DSA/SHA1 Signature, key ID 1bb943db: NOKEY:39 ETA
Public key for MariaDB-10.1.37-centos73-x86_64-common.rpm is not installed
(1/9): MariaDB-10.1.37-centos73-x86_64-common.rpm                                                                               | 123 kB  00:00:01
(2/9): MariaDB-10.1.37-centos73-x86_64-client.rpm                                                                               |  40 MB  00:01:11
(3/9): boost-program-options-1.53.0-27.el7.x86_64.rpm                                                                           | 156 kB  00:00:00
(4/9): MariaDB-10.1.37-centos73-x86_64-shared.rpm                                                                               | 1.3 MB  00:00:02
(5/9): lsof-4.87-6.el7.x86_64.rpm                                                                                               | 331 kB  00:00:00
(6/9): rsync-3.1.2-4.el7.x86_64.rpm                                                                                             | 403 kB  00:00:00
(7/9): jemalloc-3.6.0-1.el7.x86_64.rpm                                                                                          | 105 kB  00:00:02
(8/9): galera-25.3.24-1.rhel7.el7.centos.x86_64.rpm                                                                             | 8.1 MB  00:00:26
(9/9): MariaDB-10.1.37-centos73-x86_64-server.rpm                                                                               | 104 MB  00:02:16
-------------------------------------------------------------------------------------------------------------------------------------------------------
Total                                                                                                                  1.1 MB/s | 154 MB  00:02:17
Retrieving key from https://yum.mariadb.org/RPM-GPG-KEY-MariaDB
Importing GPG key 0x1BB943DB:
 Userid     : "MariaDB Package Signing Key <package-signing-key@mariadb.org>"
 Fingerprint: 1993 69e5 404b d5fc 7d2f e43b cbcb 082a 1bb9 43db
 From       : https://yum.mariadb.org/RPM-GPG-KEY-MariaDB
Is this ok [y/N]:
 
Running transaction check
Running transaction test
Transaction test succeeded
Running transaction
  Installing : MariaDB-common-10.1.37-1.el7.centos.x86_64                                                                                         1/12
  Installing : MariaDB-client-10.1.37-1.el7.centos.x86_64                                                                                         2/12
  Installing : boost-program-options-1.53.0-27.el7.x86_64                                                                                         3/12
  Installing : galera-25.3.24-1.rhel7.el7.centos.x86_64                                                                                           4/12
  Installing : rsync-3.1.2-4.el7.x86_64                                                                                                           5/12
  Installing : lsof-4.87-6.el7.x86_64                                                                                                             6/12
  Installing : jemalloc-3.6.0-1.el7.x86_64                                                                                                        7/12
  Installing : MariaDB-server-10.1.37-1.el7.centos.x86_64                                                                                         8/12
  Installing : MariaDB-shared-10.1.37-1.el7.centos.x86_64                                                                                         9/12
  Erasing    : 1:mariadb-server-5.5.56-2.el7.x86_64                                                                                              10/12
warning: /var/log/mariadb/mariadb.log saved as /var/log/mariadb/mariadb.log.rpmsave
  Erasing    : 1:mariadb-5.5.56-2.el7.x86_64                                                                                                     11/12
  Erasing    : 1:mariadb-libs-5.5.56-2.el7.x86_64                                                                                                12/12
  Verifying  : MariaDB-client-10.1.37-1.el7.centos.x86_64                                                                                         1/12
  Verifying  : jemalloc-3.6.0-1.el7.x86_64                                                                                                        2/12
  Verifying  : MariaDB-shared-10.1.37-1.el7.centos.x86_64                                                                                         3/12
  Verifying  : galera-25.3.24-1.rhel7.el7.centos.x86_64                                                                                           4/12
  Verifying  : lsof-4.87-6.el7.x86_64                                                                                                             5/12
  Verifying  : rsync-3.1.2-4.el7.x86_64                                                                                                           6/12
  Verifying  : boost-program-options-1.53.0-27.el7.x86_64                                                                                         7/12
  Verifying  : MariaDB-common-10.1.37-1.el7.centos.x86_64                                                                                         8/12
  Verifying  : MariaDB-server-10.1.37-1.el7.centos.x86_64                                                                                         9/12
  Verifying  : 1:mariadb-libs-5.5.56-2.el7.x86_64                                                                                                10/12
  Verifying  : 1:mariadb-server-5.5.56-2.el7.x86_64                                                                                              11/12
  Verifying  : 1:mariadb-5.5.56-2.el7.x86_64                                                                                                     12/12
 
Installed:
  MariaDB-client.x86_64 0:10.1.37-1.el7.centos      MariaDB-server.x86_64 0:10.1.37-1.el7.centos      MariaDB-shared.x86_64 0:10.1.37-1.el7.centos
 
Dependency Installed:
  MariaDB-common.x86_64 0:10.1.37-1.el7.centos      boost-program-options.x86_64 0:1.53.0-27.el7      galera.x86_64 0:25.3.24-1.rhel7.el7.centos
  jemalloc.x86_64 0:3.6.0-1.el7                     lsof.x86_64 0:4.87-6.el7                          rsync.x86_64 0:3.1.2-4.el7
 
Replaced:
  mariadb.x86_64 1:5.5.56-2.el7                 mariadb-libs.x86_64 1:5.5.56-2.el7                 mariadb-server.x86_64 1:5.5.56-2.el7
 
Complete!


4. 확인

[root@goni9071 ~]# rpm -qa | grep MariaDB


tcp6       0      0 :::3306                 :::*                    LISTEN


5. root 패스워드 설정

[root@goni9071 ~]# /usr/bin/mysqladmin -u root password -p
Enter password:
New password:
Confirm new password:


6. 접속

[root@goni9071 ~]# /usr/bin/mysql -u root -p
 
 
Enter password:
Welcome to the MariaDB monitor.  Commands end with ; or \g.
Your MariaDB connection id is 5
Server version: 10.1.37-MariaDB MariaDB Server
 
Copyright (c) 2000, 2018, Oracle, MariaDB Corporation Ab and others.
 
Type 'help;' or '\h' for help. Type '\c' to clear the current input statement.
 
MariaDB [(none)]>


반응형

+ Recent posts