Categories
BSD/Linux Computer Tech

Upgrade from PHP5 to PHP7 on Debian

I just did what was documented here but added in case they go away ever.

1 – get the installed packages

dpkg -l | grep php | tee packages.txt

2 – get php 7

sudo apt install php7.3 php7.3-common php7.3-cli 

3 – get the rest of the packages that you got in step 1

4 – uninstall php5

sudo apt-get purge php5*

5 – if you have fpm for web serving point all the things that used to point to

/var/run/php5-fpm.sock

to

/var/run/php/php7-fpm.sock