We are running CentOS 6 and PHP 5.3.8 (being an apache module) that ought to have JSON included in it's core (I am told). Searching at
# php -i around the command line I can tell under Configure Command
'--enable-json=shared' ... great!
However, searching at php_info() on the web site Configure Command shows
Not a problem I figured, I'll just do the installation using pecl:
# yum update php # yum install php-pear # yum install gcc # pecl install json # service httpd restart
Success, that aught to get it done I figured. However php -m shows:
PHP Warning: PHP Startup: Not able to load dynamic library '/usr/lib64/php/modules/json.so' - /usr/lib64/php/modules/json.so: undefined symbol: ZVAL_DELREF in Unknown online
Apologies if this sounds like an exotic question but does anybody know what's happening here and may you point me within the right direction regarding how to fix this to ensure that JSON begins working?
Thought I'd follow-up using the solution. The PECL installation appeared to conflict with PHP 5.3.8 so after a little of research plus some advice I considered the thought of:
# yum remove php # yum install php
However, after further advice rather opted for:
# yumdownloader php-common # rpm -Uvh --force php-common*.rpm # service httpd reload # rm php-common*.rpm
This have been effective and JSON has become working again. Hope this can help another person.
- Login to SSH
Make tmp and var/tmp professional
mount -v -o remount,exec /tmp
mount -v -o remount,exec /var/tmp
No proceed and install JSON
pecl install json
And lastly, make tmp and var/tmp noexec again
mount -v -o remount,noexec /tmp
mount -v -o remount,noexec /var/tmp