mysql5.4-betaをソースコードからインストール

vmwareにubuntu8.0.4を入れてmysqlのテスト環境を構築する

先日betaがリリースされたmysql5.4をコンパイル

なぜかubuntuにデフォルトでgccとか入ってたのでそのままconfigure

で、途中でエラーで落ちた・・・

原因はncurses-develが無いとの事

shell> sudo apt-get install ncurses-dev

で再度コンパイル

オプションは以下の通り

./configure --prefix=/usr/local/mysql5.4 --enable-assembler --enable-local-infile --with-charset=utf8 --with-extra-charsets=cp932,ujis,sjis --with-unix-socket-path=/usr/local/mysql5.4/tmp/mysql.sock --with-mysqld-user=mysql --with-plugins=all

エラー等出なかったのでmake && make install

最初、本家のマニュアルと./configure --help見ながらオプション指定してたんだけど--with-innodbとか--with-blackhole-storage-engineとかって指定してたら「そんなオプション知らねー」とか言われたので--plugins=allで指定してみた

本家マニュアル
http://dev.mysql.com/doc/refman/5.4/en/configure-options.html

で、後はいつも通り

shell> sudo adduser mysql # 後でnologinにする

shell> /usr/local/mysql5.4/bin/mysql_install_db

shell> chown -R mysql:mysql /usr/local/mysql5.4

shell> /usr/local/mysql5.4/bin/mysqld_safe &

shell> /usr/local/mysql5.4/bin/mysqladmin -u root password '********'

shell> /usr/local/mysql5.4/bin/mysql -uroot -p********

で中身確認

おおお??

federatedが有効になってないよ?

何で?

ndbclusterはndbdとmgmd起動してないから分かるけど・・・


mysql> show engines;

Engine Support Comment Transactions XA Savepoints
ndbcluster NO Clustered, fault-tolerant tables NULL NULL NULL
MRG_MYISAM YES Collection of identical MyISAM tables NO NO NO
BLACKHOLE YES /dev/null storage engine (anything you write to it disappears) NO NO NO
CSV YES CSV storage engine NO NO NO
MEMORY YES Hash based, stored in memory, useful for temporary tables NO NO NO
FEDERATED NO Federated MySQL storage engine NULL NULL NULL
ARCHIVE YES Archive storage engine NO NO NO
InnoDB YES Supports transactions, row-level locking, and foreign keys YES YES YES
MyISAM DEFAULT Default engine as of MySQL 3.23 with great performance NO NO NO

9 rows in set (0.00 sec)

mysql> show plugins;

Name Status Type Library License
binlog ACTIVE STORAGE ENGINE NULL GPL
partition ACTIVE STORAGE ENGINE NULL GPL
ARCHIVE ACTIVE STORAGE ENGINE NULL GPL
BLACKHOLE ACTIVE STORAGE ENGINE NULL GPL
CSV ACTIVE STORAGE ENGINE NULL GPL
FEDERATED DISABLED STORAGE ENGINE NULL GPL
MEMORY ACTIVE STORAGE ENGINE NULL GPL
InnoDB ACTIVE STORAGE ENGINE NULL GPL
MyISAM ACTIVE STORAGE ENGINE NULL GPL
MRG_MYISAM ACTIVE STORAGE ENGINE NULL GPL
ndbcluster DISABLED STORAGE ENGINE NULL GPL

11 rows in set (0.00 sec)