Mysql:
groupadd mysql
useradd -g mysql mysql
tar zxvf mysql-5.0.40.tar.gz
cd mysql-5.0.40
./configure --prefix=/usr/local/mysql5.0.40 --with-charset=utf8 && make && make install
cp support-files/my-medium.cnf /etc/my.cnf
cd /usr/local/mysql-5.0.40
bin/mysql_install_db --user=mysql
chown -R root .
chown -R mysql var
chgrp -R mysql .
bin/mysqld_safe --user=mysql &
性能优化:
key_buffer_size = 256M
max_connections = 400
table_cache = 256
read_buffer_size = 2M
query_cache_size = 32M
thread_cache_size = 8
Apache:
tar zxvf httpd-2.2.4.tar.gz &&
./configure \
--prefix=/usr/local/apache2 \
--enable-so \
--enable-shared=max \
--with-mpm=prefork \
--enable-deflate \
--enable-headers \
--enable-rewrite \
--enable-ssl \
--with-ssl=/usr/local/openssl-0.9.8d \
--enable-modules=all && make && make install
PHP支持GD、png、zlib库等
yum install gd
php支持连接到Mssql server
./configure --prefix=/usr/local/freetds-0.64 --with-tdsver=8.0 && make && make install
PHP:
./configure \
--prefix=/usr/local/php-5.2.3 \
--with-apxs2=/usr/local/apache2/bin/apxs \
--with-mysql=/usr/local/mysql-5.0.40 \
--enable-dba \
--enable-ftp \
--enable-debug \
--enable-versioning \
--enable-mbstring \
--enable-mbstr-enc-trans \
--enable-mbregex \
--with-png-dir=/usr/local/lib \
--with-zlib-dir=/usr/local/lib \
--with-gd \
--with-openssl=/usr/local/openssl-0.9.8d \
--with-wbmp \
--enable-sockets \
--with-mssql=/usr/local/freetds-0.64
make && make test && make install
ln -s /usr/local/php5.2.3/bin/php /usr/bin/
cp php.ini-dist /usr/local/lib/php.ini