As of this morning, I had a LAMP stack set up on my VPS with Ubuntu 14.04 php 5.5.9 and my sql version 5.5.53. I use this LAMP stack solly for hosting a couple of websites but I also want to use it for nextcloud. The first thing I did was install nextcloud as I want to set up a home server and I was prompted with the message:

This version of Nextcloud requires at least PHP 5.6.0 You are currently running 5.5.9-1ubuntu4.20. Please update your PHP version.

Consiquently, I updated my PHP to 5.6 following this method using a non root user with sudo privileges:

sudo add-apt-repository ppa:ondrej/php
sudo apt-get update
sudo apt-get -y install php5.6 php5.6-mcrypt php5.6-mbstring php5.6-curl php5.6-cli php5.6-mysql php5.6-gd php5.6-intl php5.6-xsl php5.6-zip

Everything worked ok and when I run php -v in the command line I get:

PHP 5.6.29-1+deb.sury.org~trusty+1 (cli)
Copyright (c) 1997-2016 The PHP Group
Zend Engine v2.6.0, Copyright (c) 1998-2016 Zend Technologies
    with Zend OPcache v7.0.6-dev, Copyright (c) 1999-2016, by Zend Technologies

So far so good however when I try to access nextcloud I am still greeted with the same message I got before upgrading php saying that I am running php 5.5.9-1ubuntu4.20. Furthermore, when I use a 'system status' plugin on my wordpress website theme it also says that I am running php 5.5.9.

So my question is this, even though I have updated php to 5.6 on my vps, why do apps like wordpress and nextcloud seem to think that I am still on 5.5.9? how can I fix this?

  • 1
    You also need to install the Apache module for PHP 5.6; I'll let you figure out whih package it is in.
    – fkraiem
    Dec 30, 2016 at 14:32

1 Answer 1


Ok so after fkraiem's comment I have done some digging and once I disabled the PHP5 module and then enabled the PHP5.6 module everything worked. I ran the following in the command line:

sudo a2dismod php5
sudo service apache2 restart
sudo a2enmod php5.6
sudo service apache2 restart

Thanks for the help in pointing me in the right direction :)

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.