mariadb install ( 설치)

mariadb 설치
설치하기 앞서 cmake 설치
[root@localhost ~]# yum -y install cmake
1. 파일 다운로드
[root@localhost ~]# wget https://downloads.mariadb.org/f/mariadb-5.5.36/kvm-tarbake-jaunty-x86/mariadb-5.5.36.tar.gz/from/http:/ftp.kaist.ac.kr/mariadb?serve
2. 파일 압축해제
[root@localhost ~]# tar xvfz mariadb-5.5.36.tar.gz
3. config 및 comfile 작업
[root@localhost ~]# cd mariadb-5.5.36
[root@localhost mariadb-5.5.36]# cmake \
-DWITH_READLINE=1 \
-DWITH_SSL=bundled \
-DWITH_ZLIB=system \
-DDEFAULT_CHARSET=utf8 \
-DDEFAULT_COLLATION=utf8_general_ci \
-DENABLED_LOCAL_INFILE=1 \
-DWITH_EXTRA_CHARSETS=all \
-DWITH_ARIA_STORAGE_ENGINE=1 \
-DWITH_XTRADB_STORAGE_ENGINE=1 \
-DWITH_ARCHIVE_STORAGE_ENGINE=1 \
-DWITH_INNOBASE_STORAGE_ENGINE=1 \
-DWITH_PARTITION_STORAGE_ENGINE=1 \
-DWITH_BLACKHOLE_STORAGE_ENGINE=1 \
-DWITH_FEDERATEDX_STORAGE_ENGINE=1 \
-DWITH_PERFSCHEMA_STORAGE_ENGINE=1 \
-DCMAKE_INSTALL_PREFIX=/usr/local/mariadb \
-DMYSQL_DATADIR=/free/mariadb_data
[root@localhost mariadb-5.5.36]# make
[root@localhost mariadb-5.5.36]# make install
4. 데이터베이스 설치 및 환결설정 파일 복사
사용자 추가
[root@localhost mariadb]# useradd -M mysql -u 27  >& /dev/null
데이터베이스 install
[root@localhost mariadb]# cd /usr/local/mariadb
[root@localhost mariadb]# ./scripts/mysql_install_db –user=mysql –datadir=/free/mariadb_data
권한설정
[root@localhost mariadb]# chown -R root /usr/local/mariadb/
[root@localhost mariadb]# chown -R mysql /free/mariadb_data/
[root@localhost mariadb]# chgrp -R mysql /usr/local/mariadb/
환결설정 및 시작파일 등록
[root@localhost mariadb]# cd /usr/local/mariadb/support-files/
[root@localhost support-files]# chmod 700 mysql.server
[root@localhost support-files]# cp -a mysql.server /usr/bin/
[root@localhost support-files]# cp -a mysql.server /etc/rc.d/init.d/mysql
[root@localhost support-files]# ln -s /etc/rc.d/init.d/mysql /etc/rc.d/rc3.d/S97mysql
[root@localhost support-files]# cp my-huge.cnf /etc/my.cnf
별도 튜닝
확인작업
[root@localhost support-files]# mysql.server start
[root@localhost local]# /usr/local/mariadb/bin/mysql
Welcome to the MariaDB monitor.  Commands end with ; or \g.
Your MariaDB connection id is 3
Server version: 5.5.36-MariaDB-log Source distribution
Copyright (c) 2000, 2014, Oracle, Monty Program Ab and others.
Type ‘help;’ or ‘\h’ for help. Type ‘\c’ to clear the current input statement.
MariaDB [(none)]> \s
————–
/usr/local/mariadb/bin/mysql  Ver 15.1 Distrib 5.5.36-MariaDB, for Linux (x86_64) using readline 5.1
Connection id:          3
Current database:
Current user:           root@localhost
SSL:                    Not in use
Current pager:          stdout
Using outfile:          ”
Using delimiter:        ;
Server:                 MariaDB
Server version:         5.5.36-MariaDB-log Source distribution
Protocol version:       10
Connection:             Localhost via UNIX socket
Server characterset:    utf8
Db     characterset:    utf8
Client characterset:    utf8
Conn.  characterset:    utf8
UNIX socket:            /tmp/mysql.sock
Uptime:                 1 min 39 sec
Threads: 1  Questions: 9  Slow queries: 0  Opens: 0  Flush tables: 2  Open tables: 26  Queries per second avg: 0.090
————–
MariaDB [(none)]> show engines;
+——————–+———+—————————————————————————-+————–+——+————+
| Engine             | Support | Comment                                                                    | Transactions | XA   | Savepoints |
+——————–+———+—————————————————————————-+————–+——+————+
| CSV                | YES     | CSV storage engine                                                         | NO           | NO   | NO         |
| MRG_MYISAM         | YES     | Collection of identical MyISAM tables                                      | NO           | NO   | NO         |
| MEMORY             | YES     | Hash based, stored in memory, useful for temporary tables                  | NO           | NO   | NO         |
| BLACKHOLE          | YES     | /dev/null storage engine (anything you write to it disappears)             | NO           | NO   | NO         |
| InnoDB             | DEFAULT | Percona-XtraDB, Supports transactions, row-level locking, and foreign keys | YES          | YES  | YES        |
| MyISAM             | YES     | MyISAM storage engine                                                      | NO           | NO   | NO         |
| ARCHIVE            | YES     | Archive storage engine                                                     | NO           | NO   | NO         |
| FEDERATED          | YES     | FederatedX pluggable storage engine                                        | YES          | NO   | YES        |
| PERFORMANCE_SCHEMA | YES     | Performance Schema                                                         | NO           | NO   | NO         |
| Aria               | YES     | Crash-safe tables with MyISAM heritage                                     | NO           | NO   | NO         |
+——————–+———+—————————————————————————-+————–+——+————+
태그

코멘트 쓰기

이메일은 공개되지 않습니다. 필수 입력창은 * 로 표시되어 있습니다.

다음의 HTML 태그와 속성을 사용할 수 있습니다:
<a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>



배송정보
배송조회를 하시려면 송장번호를 클릭하세요
배송조회
상품명
주문번호
택배사
송장번호