Compile of MariaDB[edit]

Install[edit]

Pre[edit]

# yum install -y gnutls-devel

Download[edit]

# cd /usr/local/src
# wget ftp://www.nsl.tuis.ac.jp/pub/mariadb/mariadb-X.Y.Z.tar.gz
# zcat mariadb-X.Y.Z.tar.gz |tar xfv -

Compile[edit]

# cd mariadb-X.Y.Z
# mkdir build
# cd build
# cmake -DWITH_READLINE=true -DWITHOUT_TOKUDB_STORAGE_ENGINE=true -DHAVE_SYSTEMD=true ..
# make
# make install
# ls -l /usr/local

Setup[edit]

ユーザ作成[edit]

# vipw                        # 確認
# adduser mysql -u 103 -d /var/mysql -s /sbin/nologin
# \rm  /var/mysql/.b*         # B-Shell 関係のファイルを削除する

ディレクトリのパーミッション[edit]

# cd /usr/local
# chmod -R o+r mysql
# find mysql -type d |xargs chmod o+x

設定ファイル[edit]

起動スクリプト[edit]

# cd /usr/local/src/mariadb-X.Y.Z/build
# cp support-files/mariadb.service  /usr/lib/systemd/system
# systemctl enable mariadb.service

初期化[edit]

# cd /usr/local/mysql
# scripts/mysql_install_db  --user=mysql  --ldata=/var/lib/mysql  --basedir=/usr/local/mysql

トップ   新規 ページ一覧 検索 最終更新   ヘルプ   最終更新のRSS