yum安裝php7和相關(guān)擴展

【radhat yum 源】

成都創(chuàng)新互聯(lián)公司-成都網(wǎng)站建設(shè)公司,專注網(wǎng)站設(shè)計制作、網(wǎng)站設(shè)計、網(wǎng)站營銷推廣,國際域名空間,雅安服務(wù)器托管網(wǎng)站托管有關(guān)企業(yè)網(wǎng)站制作方案、改版、費用等問題,請聯(lián)系成都創(chuàng)新互聯(lián)公司

rpm -aq|grep yum|xargs rpm -e --nodeps 

wget http://mirrors.163.com/centos/6/os/x86_64/Packages/yum-3.2.29-73.el6.centos.noarch.rpm 

wget http://mirrors.163.com/centos/6/os/x86_64/Packages/yum-metadata-parser-1.1.2-16.el6.x86_64.rpm

wget http://mirrors.163.com/centos/6/os/x86_64/Packages/yum-plugin-fastestmirror-1.1.30-37.el6.noarch.rpm

wget http://mirrors.163.com/centos/6/os/x86_64/Packages/python-iniparse-0.3.1-2.1.el6.noarch.rpm

wget http://mirrors.163.com/centos/6/os/x86_64/Packages/python-urlgrabber-3.9.1-11.el6.noarch.rpm

安裝下載的應(yīng)用

rpm -ivh python-iniparse-0.3.1-2.1.el6.noarch.rpm

rpm -ivh yum-metadata-parser-1.1.2-16.el6.x86_64.rpm

rpm -Uvh python-urlgrabber-3.9.1-11.el6.noarch.rpm

rpm -ivh yum-3.2.29-73.el6.centos.noarch.rpm yum-plugin-fastestmirror-1.1.30-37.el6.noarch.rpm

新建/etc/yum.repos.d/centos.repo

[base]

name=CentOS-$releasever - Base

baseurl=http://mirrors.163.com/centos/6/os/$basearch/

gpgcheck=1

gpgkey=http://mirrors.163.com/centos/RPM-GPG-KEY-CentOS-6

#released updates

[updates]

name=CentOS-$releasever - Updates

baseurl=http://mirrors.163.com/centos/6/updates/$basearch/

gpgcheck=1

gpgkey=http://mirrors.163.com/centos/RPM-GPG-KEY-CentOS-6

[extras]

name=CentOS-$releasever - Extras

baseurl=http://mirrors.163.com/centos/6/extras/$basearch/

gpgcheck=1

gpgkey=http://mirrors.163.com/centos/RPM-GPG-KEY-CentOS-6

#additional packages that extend functionality of existing packages

[centosplus]

name=CentOS-$releasever - Plus

baseurl=http://mirrors.163.com/centos/6/centosplus/$basearch/

gpgcheck=1

enabled=0

【centos  yum 源】

安裝php7和相關(guān)擴展

rpm -Uvh http://download.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm    

rpm -ivh http://nginx.org/packages/centos/6/noarch/RPMS/nginx-release-centos-6-0.el6.ngx.noarch.rpm   (nginx)

rpm -Uvh http://rpms.famillecollet.com/enterprise/remi-release-6.rpm

備注:如果發(fā)現(xiàn)上面三行有的執(zhí)行不成功;可以先通過wget獲取包,然后在rpm;

例如:rpm -Uvh http://download.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm    

(1) wget http://download.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm    

(2) rpm -Uvh  epel-release-6-8.noarch.rpm   

1.cd /etc/yum.repos.d

2.nano remi.repo 

>>>>

[remi-php55]

name=Remi's PHP 5.5 RPM repository for Enterprise Linux 6 - $basearch

#baseurl=http://rpms.remirepo.net/enterprise/6/php55/$basearch/

mirrorlist=http://rpms.remirepo.net/enterprise/6/php55/mirror

# NOTICE: common dependencies are in "remi-safe"

enabled=1

gpgcheck=1

gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-remi

>>>>>

將enabled設(shè)置為0;

3.nano remi.repo 

   >>>

[remi-php70]

name=Remi's PHP 7.0 RPM repository for Enterprise Linux 6 - $basearch

#baseurl=http://rpms.remirepo.net/enterprise/6/php70/$basearch/

mirrorlist=http://rpms.remirepo.net/enterprise/6/php70/mirror

enabled=0

gpgcheck=1

gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-remi

>>>>>

將enabled設(shè)置為1;

4.安裝擴展:

yum install php-solr php-opcache php-seasLog php-MySQLnd php-hprose php-mbstring php-mcrypt php-MongoDB php-mysqli php-gd php-dom php-apc php-memcache php-redis

service php-fpm restart && service nginx restart

卸載多余的應(yīng)用:

yum groupremove "KDE 桌面" "通用桌面"  "Java 平臺"  "互聯(lián)網(wǎng)瀏覽器"  "辦公套件和生產(chǎn)率" "Java 平臺" "互聯(lián)網(wǎng)應(yīng)用程序" "圖形生成工具" "圖形管理工具" "打印客戶端"  "桌面調(diào)試和運行工具"  "目錄客戶端" "電子郵件服務(wù)器" "MySQL 數(shù)據(jù)庫客戶端" "MySQL 數(shù)據(jù)庫服務(wù)器”

名稱欄目:yum安裝php7和相關(guān)擴展
轉(zhuǎn)載來于:http://muchs.cn/article40/jooeho.html

成都網(wǎng)站建設(shè)公司_創(chuàng)新互聯(lián),為您提供云服務(wù)器、微信公眾號Google、用戶體驗、自適應(yīng)網(wǎng)站、定制網(wǎng)站

廣告

聲明:本網(wǎng)站發(fā)布的內(nèi)容(圖片、視頻和文字)以用戶投稿、用戶轉(zhuǎn)載內(nèi)容為主,如果涉及侵權(quán)請盡快告知,我們將會在第一時間刪除。文章觀點不代表本網(wǎng)站立場,如需處理請聯(lián)系客服。電話:028-86922220;郵箱:631063699@qq.com。內(nèi)容未經(jīng)允許不得轉(zhuǎn)載,或轉(zhuǎn)載時需注明來源: 創(chuàng)新互聯(lián)

綿陽服務(wù)器托管