PHP7 ist verfügbar und wird unter OL7 unterstützt. Der YUM-Verteilungskanal muss manuell aktiviert werden, damit die RPM-Pakete verfügbar sind:
1. Bearbeiten Sie /etc/yum.repos.d/public-yum-ol7.repo Datei und vergewissern Sie sich, dass Sie „ol7_software_collections“ aktivieren ” Repo.
[ol7_software_collections] name=Software Collection Library release 3.0 packages for Oracle Linux 7 (x86_64) baseurl=https://yum.oracle.com/repo/OracleLinux/OL7/SoftwareCollections/x86_64/ gpgkey=file:///etc/pki/rpm-gpg/RPM-GPG-KEY-oracle gpgcheck=1 enabled=1
2. Installieren Sie PHP7.0 und http24:
# yum install rh-php70-php rh-php70 httpd24-mod_ssl
3. Beenden Sie alle anderen alten httpd-Dienste und deaktivieren Sie sie ebenfalls:
# systemctl stop httpd # systemctl disable httpd # systemctl status httpd
4. Starten Sie den Dienst httpd24 und aktivieren Sie ihn auch:
# systemctl start httpd24-httpd24-httpd.service # systemctl enable httpd24-httpd24-httpd.service # systemctl status httpd24-httpd24-httpd.service
5. Testen Sie PHP7.0 und httpd24.
# echo ' ' >/opt/rh/httpd24/root/var/www/html/phpinfo.php # rpm -q elinks >/dev/null || yum install elinks # elinks -dump http://localhost/phpinfo.php | head -15