2010/09/20

MySQL 5.1 と Q4M のインストール

まぁまぁまぁ。

  • CentOS 5.5
  • MySQL 5.1.50
  • Q4M 0.9.4

MySQLのインストール

$ ./configure --prefix=/usr/local/mysql --with-charset=utf8 --with-extra-charsets=all --with-plugins=all
$ make
# make install
# cp support-files/my-medium.cnf /etc/my.cnf
# cp support-files/mysql.server /etc/rc.d/init.d/mysqld
# chmod a+x /etc/rc.d/init.d/mysql
# /sbin/chkconfig mysqld on
# vim /etc/ld.so.conf.d/mysql
+/usr/local/mysql/lib/mysql
# /sbin/ldconfig
# cd /usr/local/mysql
# chown -R mysql:mysql .
# sudo -u mysql ./bin/mysql_install_db
# ./bin/mysqld_safe --user=mysql &
# ./bin/mysql_secure_installation

Q4Mのインストール

$ ./configure --prefix=/usr/local/mysql --with-mysql=/usr/local/src/mysql-5.1.50
$ make
$ make test
# make install
# mysql -u root -f mysql < support-files/install.sql

PHPのMySQL拡張を個別に再インストール

# yum remove php-mysql
$ wget php-5.x.x
$ tar zxvf php-5.x.x
$ cd php-5.x.x/ext/mysql
$ phpize
$ ./configure --with-mysql=/usr/local/mysql
$ make
# make install
# vim /etc/php.ini