Created
September 5, 2016 11:55
-
-
Save Caffe1neAdd1ct/61ee53380fa3ea2821e8b0d652ec7320 to your computer and use it in GitHub Desktop.
Upgrading PHP from 5.3 to 5.4 on Sentora CentOS 6
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| sudo su root -l | |
| yum install centos-release-scl | |
| yum install php54.x86_64 php54-build.x86_64 php54-php.x86_64 php54-php-bcmath.x86_64 php54-php-cli.x86_64 php54-php-common.x86_64 php54-php-dba.x86_64 php54-php-devel.x86_64 php54-php-enchant.x86_64 php54-php-fpm.x86_64 php54-php-gd.x86_64 php54-php-imap.x86_64 php54-php-intl.x86_64 php54-php-ldap.x86_64 php54-php-mbstring.x86_64 php54-php-mysqlnd.x86_64 php54-php-odbc.x86_64 php54-php-pdo.x86_64 php54-php-pear.noarch php54-php-pecl-apc.x86_64 php54-php-pecl-zendopcache.x86_64 php54-php-pgsql.x86_64 php54-php-process.x86_64 php54-php-pspell.x86_64 php54-php-recode.x86_64 php54-php-snmp.x86_64 php54-php-soap.x86_64 php54-php-tidy.x86_64 php54-php-xml.x86_64 php54-php-xmlrpc.x86_64 | |
| echo "source /opt/rh/php54/enable" >> /etc/bashrc | |
| source /opt/rh/php54/enable | |
| ## Install suhosin | |
| wget -nv -O suhosin.zip https://github.com/stefanesser/suhosin/archive/0.9.37.1.zip | |
| unzip -q suhosin.zip | |
| rm -f suhosin.zip | |
| cd suhosin-0.9.37.1/ | |
| phpize &> /dev/null | |
| ./configure &> /dev/null | |
| make &> /dev/null | |
| make install | |
| cd ../ | |
| rm -rf suhosin-0.9.37.1/ | |
| touch /opt/rh/php54/root/etc/php.d/suhosin.ini | |
| echo "extension=suhosin.so" >> /opt/rh/php54/root/etc/php.d/suhosin.ini | |
| ## Disable all lines in the following file: | |
| sudo vim /etc/httpd/conf.d/php.conf | |
| service httpd restart | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment