lnmp 环境搭建 (1)
硬件及软件环境:
rhel 4.7
内存 1G
硬盘80G
安装步骤:
一 安装依赖包:
gcc gcc-c++ autoconf libjpeg libjpeg-devel libpng libpng-devel freetype freetype-devel libxml2 libxml2-devel zlib zlib-devel glibc glibc-devel glib2 glib2-devel bzip2 bzip2-devel ncurses ncurses-devel curl curl-devel e2fsprogs e2fsprogs-devel krb5 krb5-devel libidn libidn-devel openssl openssl-devel openldap openldap-devel nss_ldap openldap-clients openldap-servers
这些包在安装光盘里都有,你可以用yum 来安装上边的包,但是最好用安装光盘里的吧
二 下载需要的包:
eaccelerator-0.9.6.tar.bz2 mysql-5.5.2-m2.tar.gz
ImageMagick.tar.gz nginx-0.8.34.tar.gz
imagick-2.3.0.tgz pcre-8.10.tar.gz
libiconv-1.13.tar.gz PDO_MYSQL-1.0.2.tgz
libmcrypt-2.5.8.tar.gz php-5.2.13-fpm-0.5.13.diff.gz
mcrypt-2.6.8.tar.gz php-5.2.13.tar.gz
memcache-2.2.5.tgz
mhash-0.9.9.9.tar.gz
三 安装php 5.2.13(fastcgi模式)
1 编译安装 php 5.2.13所需的支持库
tar -zxvf libiconv-1.13.tar.gz
cd libiconv-1.13.1/
./configure --prefix=/usr/local/ && make && make install && echo "come on yelang"
tar -zxvf libmcrypt-2.5.8.tar.gz
cd libmcrypt-2.5.8/
./configure && make && make install && echo "come on yelang"
tar -zxvf mhash-0.9.9.9.tar.gz
cd mhash-0.9.9.9
./configure && make && make install && echo "come on yelang"
ln -s /usr/local/lib/libmcrypt.la /usr/lib/libmcrypt.la
ln -s /usr/local/lib/libmcrypt.so /usr/lib/libmcrypt.so
ln -s /usr/local/lib/libmcrypt.so.4 /usr/lib/libmcrypt.so.4
ln -s /usr/local/lib/libmcrypt.so.4.4.8 /usr/lib/libmcrypt.so.4.4.8
ln -s /usr/local/lib/libmhash.a /usr/lib/libmhash.a
ln -s /usr/local/lib/libmhash.la /usr/lib/libmhash.la
ln -s /usr/local/lib/libmhash.so /usr/lib/libmhash.so
ln -s /usr/local/lib/libmhash.so.2 /usr/lib/libmhash.so.2
ln -s /usr/local/lib/libmhash.so.2.0.1 /usr/lib/libmhash.so.2.0.1
ln -s /usr/local/bin/libmcrypt-config /usr/bin/libmcrypt-config
可以把上边的软连接指令写入到一个脚本里边然后sh 下就可以解决问题.
tar -zxvf mcrypt-2.6.8.tar.gz
cd mcrypt-2.6.8/
./configure && make && make install && echo "come on yelang"
编译安装mysql:
阅读(644) | 评论(0) | 转发(0) |