Skip to content

Instantly share code, notes, and snippets.

@eyecatchup
Created April 4, 2017 08:22
Show Gist options
  • Star 17 You must be signed in to star a gist
  • Fork 4 You must be signed in to fork a gist
  • Save eyecatchup/ae9365aeaca55dd873631841703ec12a to your computer and use it in GitHub Desktop.
Save eyecatchup/ae9365aeaca55dd873631841703ec12a to your computer and use it in GitHub Desktop.
Update PHP 5.x to PHP 5.6 on Ubuntu 14.04
#!/bin/sh
# In case df shows >90% for /boot run:
#sudo apt-get autoremove
# Add repository
sudo add-apt-repository ppa:ondrej/php
# Install required packages
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
# Switch Apache PHP module
sudo a2dismod php5
sudo a2enmod php5.6
# Restart Apache
sudo service apache2 restart
@thisismzm
Copy link

Ondrej/php doesn't support Ubuntu 14.04 anymore

@ihemantkumar
Copy link

Ondrej/php doesn't support Ubuntu 14.04 anymore

Yes, you are right, I am trying to install PHP 5.6 on Ubuntu 14.04 and it's not locating 5.6 packages anymore.

ppa:ondrej/php5-5.6 doesn't support Ubuntu 14.04 anymore

@chichilatte
Copy link

chichilatte commented Jun 25, 2021

I was having the same problem trying to install php 5.6 using the Ubuntu 14 and 16 docker images. Ended up using Ubuntu 18. More information here... https://askubuntu.com/questions/1183626/installation-php5-6-on-ubuntu-19-10-doesnt-work-even-with-ppaondrej-php

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment