标签:数据 out ref chm cal 搭建discuz 3.0 fast efi
4.配置PHP服务4.2安装libmcrypt加密算法扩展库
4.3安装libvpx视频编码器
cd /usr/local/src
tar xjvf libvpx-v1.3.0.tar.bz2
cd libvpx-v1.3.0
./configure --prefix=/usr/local/libvpx --enable-shared --enable-vp9
4.4安装Tiff标签图像文件格式
cd /usr/local/src
tar zxvf tiff-4.0.3.tar.gz
cd tiff-4.0.3
./configure --prefix=/usr/local/tiff --enable-shared
make
make install
4.5安装libpng图片(png格式)函数库
cd /usr/local/src
tar zxvf libpng-1.6.12.tar.gz
cd libpng-1.6.12
./configure --prefix=/usr/local/libpng --enable-shared
make
make install
4.6安装freetype字体引擎
cd /usr/local/src
tar zxvf freetype-2.5.3.tar.gz
cd freetype-2.5.3
./configure --prefix=/usr/local/freetype --enable-shared
make
make install
4.7安装jpeg图片(jpeg格式)函数库
cd /usr/local/src
tar zxvf jpegsrc.v9a.tar.gz
cd jpeg-9a
./configure --prefix=/usr/local/jpeg --enable-shared
make
make install
4.8安装libgd图像处理程序
cd /usr/local/src
tar zxvf libgd-2.1.0.tar.gz
cd libgd-2.1.0
./configure --prefix=/usr/local/libgd --enable-shared --with-jpeg=/usr/local/jpeg --with-png=/usr/local/libpng --with-freetype=/usr/local/freetype --with-fontconfig=/usr/local/freetype --with-xpm=/usr/ --with-tiff=/usr/local/tiff --with-vpx=/usr/local/libvpx
make
make install
4.9将函数库文件放至合适的位置:
cd /usr/local/src
ln -s /usr/lib64/libltdl.so /usr/lib/libltdl.so
cp -frp /usr/lib64/libXpm.so* /usr/lib/
4.10安装php服务程序
tar -zvxf php-5.5.14.tar.gz
cd php-5.5.14
export LD_LIBRARY_PATH=/usr/local/libgd/lib
./configure --prefix=/usr/local/php --with-config-file-path=/usr/local/php/etc --with-mysql=/usr/local/mysql --with-mysqli=/usr/local/mysql/bin/mysql_config --with-mysql-sock=/tmp/mysql.sock --with-pdo-mysql=/usr/local/mysql --with-gd --with-png-dir=/usr/local/libpng --with-jpeg-dir=/usr/local/jpeg --with-freetype-dir=/usr/local/freetype --with-xpm-dir=/usr/ --with-vpx-dir=/usr/local/libvpx/ --with-zlib-dir=/usr/local/zlib --with-t1lib=/usr/local/t1lib --with-iconv --enable-libxml --enable-xml --enable-bcmath --enable-shmop --enable-sysvsem --enable-inline-optimization --enable-opcache --enable-mbregex --enable-fpm --enable-mbstring --enable-ftp --enable-gd-native-ttf --with-openssl --enable-pcntl --enable-sockets --with-xmlrpc --enable-zip --enable-soap --without-pear --with-gettext --enable-session --with-mcrypt --with-curl --enable-ctype
make
make install
4.11复制php服务程序的配置文件到安装目录:
cp php.ini-production /usr/local/php/etc/php.ini
4.12删除默认的php配置文件
rm -rf /etc/php.ini
4.13创建php配置文件的软连接到/etc/目录中:
cp /usr/local/php/etc/php-fpm.conf.default /usr/local/php/etc/php-fpm.conf
ln -s /usr/local/php/etc/php-fpm.conf /etc/php-fpm.conf
ln -s /usr/local/php/etc/php.ini /etc/php.ini
4.14编辑php服务程序的配置文件:
vim /usr/local/php/etc/php-fpm.conf
//将第25行参数前面的分号去掉。
pid = run/php-fpm.pid
//修改第148和149行,将user与group修改为www。
user = www
group = www
4.15添加php-fpm服务程序到开机启动项:
cp sapi/fpm/init.d.php-fpm /etc/rc.d/init.d/php-fpm
chmod +x /etc/rc.d/init.d/php-fpm
chkconfig php-fpm on
4.16配置nginx服务程序支持php:
vim /usr/local/nginx/conf/nginx.conf
//将第2行前面的#号去掉并修改为user www www ;
//将第45行参数修改为index index.html index.htm index.php;
//将第65-71行前面的#号去掉,修改为:
location ~ .php$ {
root html;
fastcgi_pass 127.0.0.1:9000;
fastcgi_index index.php;
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
include fastcgi_params;
}
4.18重启nginx与php-fpm服务程序:
systemctl restart nginx
systemctl restart php-fpm
5 搭建discuz论坛
5.1将discuz论坛数据放至网站目录
cd /usr/local/src/
unzip Discuz_X3.2_SC_GBK.zip
rm -rf /usr/local/nginx/html/{index.html,50x.html}
mv upload/* /usr/local/nginx/html/
chown -Rf www:www /usr/local/nginx/html
chmod -Rf 755 /usr/local/nginx/html
标签:数据 out ref chm cal 搭建discuz 3.0 fast efi
原文地址:http://blog.51cto.com/13956297/2177201