mysql的官方网站是 http://www.mysql.com
tar zxvf mysql-5.1.50.tar.gz
cd mysql-5.1.50
./configure --prefix=/usr/local/mysql --with-charset=gbk --with-extra-charset=all --enable-hread-safe-client
--enable-local-infile --with-low-memory
make && make install
chmod +w /usr/local/mysql
chown -R mysql:mysql /usr/local/mysql
cp support-files/my-medium.cnf /etc/my.cnf
/usr/local/mysql/bin/mysql_install_db --basedir=/usr/local/mysql --datadir=/usr/local/mysql/data --user=mysql
/bin/sh /usr/local/mysql/bin/mysqld_safe --defaults-file=/etc/my.cnf