来源: 红科网安

收集:X.DW

0、安装CentOS 5.0,并且升级
#yum check-update
#yum update
1、安装开发包
yum install libjpeg-devel zlib-devel tcl-devel freetype-devel libevent-devel openssl-devel db4-devel curl-devel pcre-devel
2、安装sqlite
#cd /sometemppath
#wget http://www.sqlite.org/sqlite-3.5.2.tar.gz
#tar xzvf sqlite-3.5.2.tar.gz
#cd sqlite-3.5.2
#./configure
#make
#make install
3、安装Python 2.5
#cd /sometemppath
#wget http://www.python.org/ftp/python/2.5.1/Python-2.5.1.tar.bz2
#tar xjvf python-2.5.1.tar.bz2
#cd python-2.5.1
#./configure --enable-unicode=ucs4
#make
#make install
4、安装MySQL 5.0
#cd /sometemppath
#wget http://dev.mysql.com/get/Downloads/MySQL-5.0/mysql-5.0.45.tar.gz/from/http://mysql.mirrors.hoobly.com/
#tar xzvf mysql-5.0.45.tar.gz
#cd mysql-5.0.45
#groupadd mysql
#useradd -g mysql mysql
#mkdir /opt/mysql-data
#CFLAGS="-O3" CXX=gcc CXXFLAGS="-O3 -felide-constructors \
-fno-exceptions -fno-rtti" ./configure \
--prefix=/usr/local/mysql --enable-assembler \
--with-charset=utf8 \
--with-extra-charsets=gbk,gb2312,latin1 \
--localstatedir=/opt/mysql-data \
--with-mysqld-user=mysql --enable-large-files --with-big-tables \
--without-debug \
--with-mysqld-ldflags=-all-static \
--with-client-ldflags=-all-static \
--enable-thread-safe-client
#make
#make install
#cp support-files/my-medium.cnf /etc/my.cnf
#cd /usr/local/mysql
#chown -R mysql .   
#chgrp -R mysql .
#chown -R mysql /opt/mysql-data
#chgrp -R mysql /opt/mysql-data
#bin/mysql_install_db --user=mysql  
#chown -R root .
#bin/mysqld_safe --user=mysql &
将/usr/local/mysql/bin加入PATH路径
#vi /etc/profile
加入
PATH=/usr/local/mysql/bin:$PATH
export PATH
:wq
#source /etc/profile
将mysql lib目录加入动态库路径
#echo "/usr/local/mysql/lib/mysql" > /etc/ld.so.conf.d/mysql.conf
#ldconfig
5、安装memcached
#cd /sometemppath
#wget http://www.danga.com/memcached/dist/memcached-1.2.2.tar.gz
#tar xzvf memcached-1.2.2.tar.gz
#cd memcached-1.2.2
#./configure --prefix=/usr/local/memcached
#make
#make install
6、安装setuptools
#cd /sometemppath
#wget http://pypi.python.org/packages/source/s/setuptools/setuptools-0.6c7.tar.gz#md5=dedbf6a4f71cd6deaf13ee885054f16b
#tar xzvf setuptools-0.6c7.tar.gz
#cd setuptools-0.6c7
#python setup.py install
7、安装Django
#cd /sometemppath
#svn co http://code.djangoproject.com/svn/django/trunk django-trunk
#cd django-trunk
#python setup.py install
8、安装SQLAlchemy
#cd /sometemppath
#svn co http://svn.sqlalchemy.org/sqlalchemy/trunk sqlalchemy-trunk
#cd sqlalchemy-trunk
#python setup.py install
9、安装MySQLdb
#cd /sometemppath
#wget http://nchc.dl.sourceforge.net/sourceforge/mysql-python/MySQL-python-1.2.2.tar.gz
#tar xzvf MySQL-python-1.2.2.tar.gz
#cd MySQL-python-1.2.2
#python setup.py install
10、安装Twisted
#cd /sometemppath
#wget http://tmrc.mit.edu/mirror/twisted/Twisted/2.5/Twisted-2.5.0.tar.bz2
#tar xjvf Twisted-2.5.0.tar.bz2
#cd Twisted-2.5.0/
#cd zope.interface-3.3.0
#python setup.py install
#cd ..
#python setup.py install
11、安装Pyro
#cd /sometemppath
#wget http://jaist.dl.sourceforge.net/sourceforge/pyro/Pyro-3.7.tar.gz
#tar xzvf Pyro-3.7.tar.gz
#cd Pyro-3.7
#python setup.py install
12、安装psyco
#cd /sometemppath
#svn co http://codespeak.net/svn/psyco/dist/ psyco-trunk
#cd psyco-trunk
#python setup.py install
13、安装python-memcached
#cd /sometemppath
#wget ftp://ftp.tummy.com/pub/python-memcached/python-memcached-1.40.tar.gz
#tar xzvf python-memcached-1.40.tar.gz
#cd python-memcached-1.40
#python setup.py install
*** 安装cmemcache(Python extension for libmemcache) ***
#cd /sometemppath
#wget http://people.freebsd.org/~seanc/libmemcache/libmemcache-1.4.0.rc2.tar.bz2
# tar xjvf libmemcache-1.4.0.rc2.tar.bz2
#cd libmemcache-1.4.0.rc2
#wget http://gijsbert.org/downloads/cmemcache/libmemcache-1.4.0.rc2.patch
#patch -p2 < libmemcache-1.4.0.rc2.patch
#./configure
#make
#make install
#cd /sometemppath
#wget http://gijsbert.org/downloads/cmemcache/cmemcache-0.91.tar.bz2
#tar xjvf cmemcache-0.91.tar.bz2
#cd cmemcache-0.91
#python setup.py install
14、安装PIL
#cd /sometemppath
#wget http://effbot.org/downloads/Imaging-1.1.6.tar.gz
#tar xzvf Imaging-1.1.6.tar.gz
#cd Imaging-1.1.6
#python setup.py install
15、安装flup
#cd /sometemppath
#wget http://www.saddi.com/software/flup/dist/flup-1.0.tar.gz
#tar xzvf flup-1.0.tar.gz
#cd flup-1.0
#python setup.py install
16、安装nginx
#cd /sometemppath
#wget http://sysoev.ru/nginx/nginx-0.5.33.tar.gz
#tar xzvf nginx-0.5.33.tar.gz
#cd nginx-0.5.33
#./configure --prefix=/usr/local/nginx \
--with-md5=/usr/lib \
--with-sha1=/usr/lib \
--with-http_ssl_module \
--without-mail_pop3_module \
--without-mail_imap_module \
--without-mail_smtp_module
#make
#make install

文章如转载,请注明转载自:http://www.5iadmin.com/post/127.html