环境 
linux AS4 2.6.9 
1.安装mysql
使用版本 mysql5.1.22-rc.tar.gz 
把安装包拷贝到/usr/local目录后执行如下命令: 
groupadd mysqluseradd -g mysql mysqlcd mysql scripts/mysql_install_db --user=mysqlchown -R mysql:mysql .cp /usr/local/mysql/support-files/my-medium.cnf /etc/my.cnfcp /usr/local/mysql/support-files/mysql.server /etc/rc.d/init.d/mysqldchmod +x /etc/rc.d/init.d/mysqldln -s /usr/local/mysql/bin/mysql /usr/sbin/mysqlchkconfig --add mysqld
启动mysql 
service mysqld start 
进入mysql 
mysql 
 
2.安装apache
版本 httpd-2.0.61.tar.gz 
./configure --prefix=/usr/local/apache --enable-module=so 
make 
make install 
cd /usr/local/apache/bin 
./apachectl start 
如果没有安装gcc编译工具,安装的时候会有提示。可以在光盘中找到! 
3.安装php
版本 php-4.4.7.tar.gz 
./configure --prefix=/usr/local/php --with-apxs2=/usr/local/apache/bin/apxs --with-config-file-path=/usr/local/lib --enable-track-vars --with-xml --with-mysql=/usr/local/mysql --with-mbstring --enable-mbstring=all 
make 
make install 
注释: 
--with-apxs=dir 作为apache的模块编译 
--with-config-file-path=dir php.ini所在目录 
--enable-track-vars 跟踪变量 
--with-xml xml支持 
--with-mysql=dir mysql支持