shell> groupadd mysql shell> useradd -g mysql mysql shell> cd /usr/local shell> gunzip < /path/to/mysql-VERSION-OS.tar.gz | tar xvf - shell> ln -s full-path-to-mysql-VERSION-OS mysql shell> cd mysql shell> scripts/mysql_install_db shell> chown -R root . shell> chown -R mysql data shell> chgrp -R mysql .
shell> bin/mysqld_safe --user=mysql &
设置自动启动mysql 在/etc/rc.local中加入一行: cd /usr/local/mysql;bin/safe_mysqld --user=mysql &
开始编译安装: 这里使用DSO方式编译apache,这样可以很方便的升级PHP以及其他模块,不用每次都重新编译apache。apache安装到/usr/local/apache tar -xzvf httpd-2.0.45.tar.gz cd httpd-2.0.45 ./configure --prefix=/usr/local/httpd --enable-deflate/ --enable-so --enable-rewrite --enable-spellingdir=/usr/lib make make install