升级的步骤:参考https://www.digitalocean.com/community/questions/how-to-upgrade-from-php-v-5-5-9-to-v-5-6
sudo add-apt-repository ppa:ondrej/php
sudo apt-get update
sudo apt-get install php5.6 php5.6-mbstring php5.6-mcrypt php5.6-mysql php5.6-xml
(进行到这步的时候,php5.6就已经装好了,dpkg --get-selections | grep -v deinstall | grep php查看一下,可以看到后面的截图的效果!)
sudo a2dismod php5
(这个好像是移除php5的)
sudo a2enmod php5.6
sudo service apache2 restart
-------------------------------------------------------------------------------------------------------------
dpkg --get-selections | grep -v deinstall | grep php
用这个命令去看安装在你的服务器上的php的包,
You can also use dpkg --get-selections | grep -v deinstall | grep php
command to see the PHP packages installed on your server to add them for PHP 5.6 if necessary.
php进程还没有启动起来