I am running an OwnCloud instance on a Centos 7 VPS and recently had to upgrade PHP from 5.4.16 to 7.1.9 because OwnCloud considered PHP 5.x as "ancient". I managed to upgrade PHP with the following commands:
Install repos
Code: Select all
rpm -Uvh https://dl.fedoraproject.org/pub/epel/epel-release-latest-7.noarch.rpm
rpm -Uvh https://mirror.webtatic.com/yum/el7/webtatic-release.rpm
Code: Select all
cp /etc/php.ini /etc/php.ini.bak
Code: Select all
yum erase php*
Code: Select all
yum update
Code: Select all
sudo yum install -y mod_php71w php71w-cli php71w-common php71w-gd php71w-mbstring php71w-mcrypt php71w-mysqlnd php71w-xml php71w-devel php71w-intl php71w-ldap php71w-pear php71w-pecl-apcu php71w-pecl-igbinary php71w-pecl-redis php71w-php-process php71w-xmlrpc
Code: Select all
[admin@cloud mainuser]# php -v
PHP 7.1.11 (cli) (built: Oct 29 2017 17:26:51) ( NTS )
Copyright (c) 1997-2017 The PHP Group
Zend Engine v3.1.0, Copyright (c) 1998-2017 Zend Technologies
The problem is that I am experiencing all kind of strange issues with the webpage of Owncloud. Sometimes, I get blank pages, but a browser F5 brings the page back. File transfers are also sometimes timing out, the file list is sometimes not synced with the contents (for example I drag files to the cloud, they appear then I go back and the're gone but a refresh F5 makes them reappear.
I hava also other error messages from owncloud. The folks at Owncloud's forums are thinking PHP is crashing due to what I found in the apache logs:
in /var/log/httpd/php_errors
Code: Select all
[03-Dec-2017 00:18:07 UTC] PHP Warning: require_once(): open_basedir restriction in effect. File(/usr/share/pear/pearcmd.php) is not within the allowed path(s): (/var/log/httpd/:/var/www/html/:/tmp/:/mnt/data/:/dev/urandom) in /usr/share/pear/peclcmd.php on line 31
[03-Dec-2017 00:18:07 UTC] PHP Warning: require_once(/usr/share/pear/pearcmd.php): failed to open stream: Operation not permitted in /usr/share/pear/peclcmd.php on line 31
[03-Dec-2017 00:18:07 UTC] PHP Fatal error: require_once(): Failed opening required 'pearcmd.php' (include_path='/usr/share/pear:/usr/share/pear') in /usr/share/pear/peclcmd.php on line 31
Code: Select all
[Sat Dec 02 21:17:58.247970 2017] [core:notice] [pid 11963] AH00052: child pid 11964 exit signal Segmentation fault (11)
[Sat Dec 02 21:17:58.248047 2017] [core:notice] [pid 11963] AH00052: child pid 11966 exit signal Segmentation fault (11)
[Sat Dec 02 21:17:59.255186 2017] [core:notice] [pid 11963] AH00052: child pid 11965 exit signal Segmentation fault (11)
[Sat Dec 02 21:17:59.255338 2017] [core:notice] [pid 11963] AH00052: child pid 11967 exit signal Segmentation fault (11)
[Sat Dec 02 21:18:14.287865 2017] [core:notice] [pid 11963] AH00052: child pid 11979 exit signal Segmentation fault (11)
Apache
Code: Select all
Server version: Apache/2.4.6 (CentOS)
Server built: Oct 19 2017 20:39:16
Thanks!!