Hàng trăm 6 php 8
Việ cài đặt PHP bằng yum như trong bài sẽ tương tác hoạt động với dịch vụ Apache dưới dạng Trình xử lý PHP là DSO (mod_php), là 1 mô-đun của Apache. Nên nếu bạn có nhu cầu cài đặt dưới dạng Trình xử lý PHP khác như fcgi, php-fpm, fastcgi,. thì nên nhắc trước khi cài đặt. Mặc định đã cài đặt dịch vụ Apache trước rồi nhé Show nội dung
1. Cài đặt Repo REMI và EPEL– Việ cài đặt gói chương trình PHP 5. 6 will information through Repository of REMI is main. Nhưng bạn phải cài đặt repo Epel để hỗ trợ repo REMI + CentOS 7 # wget http://dl.fedoraproject.org/pub/epel/7/x86_64/e/epel-release-7-8.noarch.rpm # wget http://rpms.famillecollet.com/enterprise/remi-release-7.rpm # rpm -Uvh remi-release-7*.rpm epel-release-7*.rpm
# wget http://dl.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm # wget http://rpms.famillecollet.com/enterprise/remi-release-6.rpm # rpm -Uvh remi-release-6*.rpm epel-release-6*.rpm
2. Kích hoạt Repo của Remi– Ta cần đảm bảo rằng repo của REMI và EPEL đã được kích hoạt cho phép kết nối với Repo của họ để tải xuống ứng dụng. Mặc định EPEL thông thường khi cài đặt đã kích hoạt tự động, còn REMI thì chưa. Giờ ta sẽ kích hoạt REMI Repo như sau # vi /etc/yum.repos.d/remi.repo [remi] name=Remi's RPM repository for Enterprise Linux 6 - $basearch #baseurl=http://rpms.remirepo.net/enterprise/6/remi/$basearch/ mirrorlist=http://rpms.remirepo.net/enterprise/6/remi/mirror enabled=1 gpgcheck=1 gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-remi 2. 1 Không cài đặt PHP 5. 5– Bây giờ ta sẽ kích hoạt repo remi sử dụng cho PHP 5. 5. Các bạn kéo xuống phần tệp nội dung ở phần [remi-php55] , hãy kích hoạt 'enabled= 1 '. Còn phần [remi-php56] thì kiểm tra set ‘enabled= 0 ‘ nhé để không kích hoạt repo chứa gói cài đặt PHP 5. 6. Vì ta chỉ cần cài đặt phiên bản PHP 5. 5. # vi /etc/yum.repos.d/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 [remi-php56] name=Remi's PHP 5.6 RPM repository for Enterprise Linux 6 - $basearch #baseurl=http://rpms.remirepo.net/enterprise/6/php56/$basearch/ mirrorlist=http://rpms.remirepo.net/enterprise/6/php56/mirror # NOTICE: common dependencies are in "remi-safe" enabled=0 gpgcheck=1 gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-remi 2. 1 Không cài đặt PHP 5. 6– Bây giờ ta sẽ kích hoạt repo remi sử dụng cho PHP 5. 6. Các bạn kéo xuống phần tệp nội dung ở phần [remi-php56] , hãy kích hoạt 'enabled= 1 ' as side on. Còn phần [remi-php55] thì kiểm tra set 'enabled= 0 ' nhé để không kích hoạt repo chứa gói cài đặt PHP 5. 5, because no not must be nhu cầu của chúng ta. # vi /etc/yum.repos.d/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=0 gpgcheck=1 gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-remi [remi-php56] name=Remi's PHP 5.6 RPM repository for Enterprise Linux 6 - $basearch #baseurl=http://rpms.remirepo.net/enterprise/6/php56/$basearch/ mirrorlist=http://rpms.remirepo.net/enterprise/6/php56/mirror # NOTICE: common dependencies are in "remi-safe" enabled=1 gpgcheck=1 gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-remi # yum update 3. Cài đặt PHP 5. 5 hoặc 5. 6– Bây giờ nhiệm vụ của chúng ta khá đơn giản, chỉ cần cài đặt Các gói phần mềm php tương ứng là xong. Dưới lệnh Camu này là cài đặt các gói phần mềm chống sốt cần phải thết chi ho động của php, mình sẽ không liệt kê các gói nội dung các gói này là gì nhưng có hỗ trợ chắc chắn Cho mysql, gd, mcrypt,. + Lệnh caii PHP 5. 5 # yum install --enablerepo=remi,remi-php55 php php-mysql php-bcmath php-cli php-common php-dba php-devel php-embedded php-enchant php-gd php-imap php-mbstring php-mcrypt php-pdo php-xml -y # yum --enablerepo=remi,remi-php56 search php* # wget http://dl.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm # wget http://rpms.famillecollet.com/enterprise/remi-release-6.rpm # rpm -Uvh remi-release-6*.rpm epel-release-6*.rpm0 4. Khởi động lại Apache– Giờ ta cần khởi động lại dịch vụ Apache để áp dụng chương trình PHP # wget http://dl.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm # wget http://rpms.famillecollet.com/enterprise/remi-release-6.rpm # rpm -Uvh remi-release-6*.rpm epel-release-6*.rpm1 # wget http://dl.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm # wget http://rpms.famillecollet.com/enterprise/remi-release-6.rpm # rpm -Uvh remi-release-6*.rpm epel-release-6*.rpm2 5. Gỡ chương trình PHP– Giờ bạn đã cài đặt rồi, rồi muốn xóa hết cài đặt khác thì làm thế nào? . Thấy bạn # wget http://dl.fedoraproject.org/pub/epel/6/x86_64/epel-release-6-8.noarch.rpm # wget http://rpms.famillecollet.com/enterprise/remi-release-6.rpm # rpm -Uvh remi-release-6*.rpm epel-release-6*.rpm3
liên kết bức điện tín Bài viết trước [DirectAdmin] Sửa lỗi 'Tên miền đã tồn tại' trên Quản trị viên trực tiếp khi có mười tên miền lưu trữ Bài viết tiếp theo [Linux] Hướng dẫn cài đặt Git trên CentOS 6/7 Quách Chí Cường https. // cuongquach. với/ Bạn đang theo dõi website " https. // cuongquach. com/"nơi lưu trữ những kiến thức tổng hợp và chia sẻ tại đây nhân vền hệ thống dịch vụ & mạng, được xây dựng lại dưới nền tảng kin thử nghiệm của bản thạch chí cường. Hy vọng bạn sẽ thích nơi này |