corrections to upgrading PHP docs

This commit is contained in:
Carla Schroder
2016-02-19 15:39:59 -08:00
parent 3731f1b45e
commit 39aab776f9
3 changed files with 21 additions and 32 deletions

View File

@@ -25,13 +25,9 @@ example installs the new PHP 5.4 module for MySQL/MariaDB::
yum install php54-php-mysqlnd
Activate the new PHP version permanently::
source /opt/rh/php54/enable
Disable loading the old PHP 5.3 Apache module::
mv /etc/httpd/conf.d/php.conf /etc/httpd/conf.d/php.conf.old
mv /etc/httpd/conf.d/php.conf /etc/httpd/conf.d/php53.off
You should now have a /etc/httpd/conf.d/php54-php.conf file, which loads the
correct PHP 5.4 module for Apache.
@@ -59,13 +55,9 @@ module for MySQL/MariaDB::
yum install php54-php-mysqlnd
Activate the new PHP version permanently::
source /opt/rh/php54/enable
Disable loading the old PHP 5.3 Apache module::
mv /etc/httpd/conf.d/php.conf /etc/httpd/conf.d/php.conf.old
mv /etc/httpd/conf.d/php.conf /etc/httpd/conf.d/php53.off
You should now have a /etc/httpd/conf.d/php54-php.conf file, which loads the
correct PHP 5.4 module for Apache.

View File

@@ -21,25 +21,24 @@ You must also install the updated database module for your database. This instal
yum install php55-php-mysqlnd
Activate the new PHP version permanently::
source /opt/rh/php55/enable
Disable loading the old PHP Apache module by changing its name. Look in ``/etc/httpd/conf.d/`` to verify the module name::
Disable loading the old PHP Apache modules by changing their names::
mv /etc/httpd/conf.d/php.conf /etc/httpd/conf.d/php.conf.old
mv /etc/httpd/conf.d/php.conf /etc/httpd/conf.d/php54.off
mv /etc/httpd/conf.modules.d/10-php.conf /etc/httpd/conf.modules.d/10-php54.off
Copy the PHP 5.5 Apache modules from /opt/rh/php55/::
Copy the PHP 5.5 Apache modules into place::
cp /opt/rh/httpd24/root/etc/httpd/conf.d/php55-php.conf /etc/httpd/conf.d/
cp /opt/rh/httpd24/root/etc/httpd/conf.modules.d/10-php55-php.conf /etc/httpd/conf.modules.d/
cp /opt/rh/httpd24/root/etc/httpd/modules/libphp-php55.so /etc/httpd/modules/
cp /opt/rh/httpd24/root/etc/httpd/conf.modules.d/10-php55-php.conf /etc/httpdconf.modules.d/
cp /opt/rh/httpd24/root/etc/httpd/modules/libphp55-php5.so /etc/httpd/modules/
Then restart Apache::
service httpd restart
Verify with ``phpinfo`` that your Apache server is using PHP 5.5 and loading the correct modules; see :ref:`label-phpinfo` to learn how to use phpinfo.
Verify with ``phpinfo`` that your Apache server is using PHP 5.5 and loading the
correct modules; see :ref:`label-phpinfo` to learn how to use phpinfo.
CentOS 7 Upgrade to PHP 5.5
---------------------------
@@ -59,23 +58,21 @@ Then install PHP 5.5 and these modules::
You must also install the updated database module for your database. This installs the new PHP 5.5 module for MySQL/MariaDB::
yum install php55-php-mysqlnd
Activate the new PHP version permanently::
source /opt/rh/php55/enable
Disable loading the old PHP Apache module by changing its name. Look in /etc/httpd/conf.d/ to verify the module name::
Disable loading the old PHP Apache modules by changing their names::
mv /etc/httpd/conf.d/php.conf /etc/httpd/conf.d/php.conf.old
mv /etc/httpd/conf.d/php.conf /etc/httpd/conf.d/php54.off
mv /etc/httpd/conf.modules.d/10-php.conf /etc/httpd/conf.modules.d/10-php54.off
Copy the PHP 5.5 Apache modules from /opt/rh/php55/::
Copy the PHP 5.5 Apache modules into place::
cp /opt/rh/httpd24/root/etc/httpd/conf.d/php55-php.conf /etc/httpd/conf.d/
cp /opt/rh/httpd24/root/etc/httpd/conf.modules.d/10-php55-php.conf /etc/httpd/conf.modules.d/
cp /opt/rh/httpd24/root/etc/httpd/modules/libphp-php55.so /etc/httpd/modules/
cp /opt/rh/httpd24/root/etc/httpd/conf.modules.d/10-php55-php.conf /etc/httpdconf.modules.d/
cp /opt/rh/httpd24/root/etc/httpd/modules/libphp55-php5.so /etc/httpd/modules/
Then restart Apache::
service httpd restart
Verify with ``phpinfo`` that your Apache server is using PHP 5.5 and loading the correct modules; see :ref:`label-phpinfo` to learn how to use phpinfo.
Verify with ``phpinfo`` that your Apache server is using PHP 5.5 and loading the
correct modules; see :ref:`label-phpinfo` to learn how to use ``phpinfo``.

View File

@@ -107,7 +107,7 @@ Open this file in a Web browser by pointing your browser to
.. figure:: ../images/phpinfo.png
Your PHP version is at the top, and the rest of the page contains abundant
system information such as active modules, active `.ini` files, and much more.
system information such as active modules, active ``.ini`` files, and much more.
When you are finished reviewing your information you must delete
``phpinfo.php``, or move it outside of your Web directory, because it is a
security risk to expose such sensitive data.