本篇內(nèi)容主要講解“php5.3版本的安裝教程”,感興趣的朋友不妨來(lái)看看。本文介紹的方法操作簡(jiǎn)單快捷,實(shí)用性強(qiáng)。下面就讓小編來(lái)帶大家學(xué)習(xí)“php5.3版本的安裝教程”吧!
成都創(chuàng)新互聯(lián)是一家專注于成都網(wǎng)站設(shè)計(jì)、成都網(wǎng)站建設(shè)與策劃設(shè)計(jì),寬城網(wǎng)站建設(shè)哪家好?成都創(chuàng)新互聯(lián)做網(wǎng)站,專注于網(wǎng)站建設(shè)十年,網(wǎng)設(shè)計(jì)領(lǐng)域的專業(yè)建站公司;建站業(yè)務(wù)涵蓋:寬城等地區(qū)。寬城做網(wǎng)站價(jià)格咨詢:028-86922220
本文操作環(huán)境:centOS6.8系統(tǒng)、php5.3版,DELL G3電腦
php5.3安裝教程
php5.3安裝
sudo apt-get install gcc sudo apt-get install g++ sudo apt-get install autoconf sudo apt-get install libxml2 sudo apt-get install libxml2-dev sudo apt-get install libevent-1.4-2 sudo apt-get install libevent-dev sudo apt-get install bzip2 sudo apt-get install libbz2-dev sudo apt-get install libcurl3-gnutls sudo apt-get install libcurl4-gnutls-dev sudo apt-get install libpng12-0 sudo apt-get install libpng12-dev sudo apt-get install libjpeg62 sudo apt-get install libjpeg62-dev sudo apt-get install libfreetype6 sudo apt-get install libfreetype6-dev sudo apt-get install libmcrypt4 sudo apt-get install libmcrypt-dev sudo apt-get install zlib1g-dev sudo apt-get install libtidy-dev
sudo apt-get install autoconf g++ libxml2-dev libevent-dev libbz2-dev libcurl4-gnutls-dev libpng12-dev libjpeg62-dev libfreetype6-dev libmcrypt-dev zlib1g-dev ./configure --prefix=/usr/local/php55 --with-gettext --with-MySQL=mysqlnd --with-gd --with-jpeg-dir --with-png-dir --with-curl --with-freetype-dir --enable-gd-native-ttf --enable-mbstring --enable-sockets --with-mcrypt --with-pdo-mysql=mysqlnd --enable-fpm --with-zlib --enable-zip --with-bz2 --enable-bcmath --enable-sysvmsg --enable-sysvsem --enable-sysvshm --enable-pcntl
注意:
如果是RH,需要:
yum -y install curl-devel yum install libjpeg-devel yum install libpng-devel yum install freetype-devel yum install -y libmcrypt-devel.x86_64 yum install -y libxml2-devel.x86_64 yum install -y bzip2-devel.x86_64 yum install libtool-ltdl-devel (在 make的時(shí)候會(huì)出現(xiàn):/usr/bin/ld: cannot find -lltdl) yum install autoconf yum install -y libtidy-devel.x86_64
編譯、安裝
./configure --prefix=/usr/local/php-5.3.3 --with-gettext --with-mysql=mysqlnd --with-gd --with-jpeg-dir --with-png-dir --with-curl --with-freetype-dir --enable-gd-native-ttf --enable-mbstring --enable-sockets --with-mcrypt --with-pdo-mysql=mysqlnd --enable-fpm --with-zlib --enable-zip --with-bz2 --enable-bcmath --with-tidy make make install
編譯安裝完成之后,還需要對(duì)php-fpm 進(jìn)行配置,因?yàn)閜hp5.3不再需要打php-fpm補(bǔ)丁,所以以前控制php-fpm(啟動(dòng)、重啟)的方式需要改變。操作步驟如下:
從源碼包復(fù)制:
sudo path/to/php-source/folder/sapi/fpm/init.d.php-fpm /etc/init.d/php-fpm sudo chmod a+x /etx/init.d/php-fpm
然后就可以通過(guò) /etc/init.d/php-fpm (start|stop|force-quit|restart|reload) 進(jìn)行控制
一般擴(kuò)展安裝
memcached:
wget http://pecl.php.net/get/memcache-2.2.5.tgz tar -xvf memcache-2.2.5.tgz cd memcache-2.2.5 /usr/local/php-5.3.3/bin/phpize ./configure --with-php-config=/usr/local/php-5.3.3/bin/php-config make make install
solr
wget http://pecl.php.net/get/solr-0.9.11.tgz tar -xvf solr-0.9.11.tgz cd solr-0.9.11 /usr/local/php-5.3.3/bin/phpize ./configure --with-php-config=/usr/local/php-5.3.3/bin/php-config make make install
xcache
wget http://xcache.lighttpd.net/pub/Releases/1.3.0/xcache-1.3.0.tar.bz2 tar -xjvf xcache-1.3.0.tar.bz2 cd xcache-1.3.0 /usr/local/php-5.3.3/bin/phpize ./configure --with-php-config=/usr/local/php-5.3.3/bin/php-config make make install
php_ini
expose_php = off error_reporting = E_ALL display_errors = On short_open_tag = On extension=memcache.so extension=xcache.so extension=solr.so bbs需要 ;log_errors = on error_log = syslog linux系統(tǒng)可以使用這個(gè),把errorlog 輸出到syslog中 date.timezone = Asia/Shanghai
到此,相信大家對(duì)“php5.3版本的安裝教程”有了更深的了解,不妨來(lái)實(shí)際操作一番吧!這里是創(chuàng)新互聯(lián)網(wǎng)站,更多相關(guān)內(nèi)容可以進(jìn)入相關(guān)頻道進(jìn)行查詢,關(guān)注我們,繼續(xù)學(xué)習(xí)!
網(wǎng)站標(biāo)題:php5.3版本的安裝教程
標(biāo)題網(wǎng)址:http://jinyejixie.com/article36/psgdpg.html
成都網(wǎng)站建設(shè)公司_創(chuàng)新互聯(lián),為您提供建站公司、網(wǎng)站改版、營(yíng)銷型網(wǎng)站建設(shè)、品牌網(wǎng)站建設(shè)、虛擬主機(jī)、網(wǎng)站排名
聲明:本網(wǎng)站發(fā)布的內(nèi)容(圖片、視頻和文字)以用戶投稿、用戶轉(zhuǎn)載內(nèi)容為主,如果涉及侵權(quán)請(qǐng)盡快告知,我們將會(huì)在第一時(shí)間刪除。文章觀點(diǎn)不代表本網(wǎng)站立場(chǎng),如需處理請(qǐng)聯(lián)系客服。電話:028-86922220;郵箱:631063699@qq.com。內(nèi)容未經(jīng)允許不得轉(zhuǎn)載,或轉(zhuǎn)載時(shí)需注明來(lái)源: 創(chuàng)新互聯(lián)