Need help changing version of PHP apache uses - Ubuntu 12.04
Linux - ServerThis forum is for the discussion of Linux Software used in a server related context.
Notices
Welcome to LinuxQuestions.org, a friendly and active Linux Community.
You are currently viewing LQ as a guest. By joining our community you will have the ability to post topics, receive our newsletter, use the advanced search, subscribe to threads and access many other special features. Registration is quick, simple and absolutely free. Join our community today!
Note that registered members see fewer ads, and ContentLink is completely disabled once you log in.
If you have any problems with the registration process or your account login, please contact us. If you need to reset your password, click here.
Having a problem logging in? Please visit this page to clear all LQ-related cookies.
Get a virtual cloud desktop with the Linux distro that you want in less than five minutes with Shells! With over 10 pre-installed distros to choose from, the worry-free installation life is here! Whether you are a digital nomad or just looking for flexibility, Shells can put your Linux machine on the device that you want to use.
Exclusive for LQ members, get up to 45% off per month. Click here for more info.
you'd need to give more information than this, do you know how PHP is being loaded, is it mod_php, fcgi, php-fpm, etc? The phpinfo page should indicate what it is. And how do you have PHP 5.6 installed?
One of your highest priorities should be to plan a migration and then migrate that server to Ubuntu 14.04 LTS or 16.04 LTS. The version you have, 12.04, will reach end of life in a few days: https://wiki.ubuntu.com/Releases
After that, it will get no more support, not even security patches. So it will be rather important to see to the upgrade if you plan to keep the server around past the end of the month. On the way, the PHP version will be replaced with a newer version as part and parcel of the upgrade.
One of your highest priorities should be to plan a migration and then migrate that server to Ubuntu 14.04 LTS or 16.04 LTS. The version you have, 12.04, will reach end of life in a few days: https://wiki.ubuntu.com/Releases
After that, it will get no more support, not even security patches. So it will be rather important to see to the upgrade if you plan to keep the server around past the end of the month. On the way, the PHP version will be replaced with a newer version as part and parcel of the upgrade.
I know that 16.04 has neither PHP5 nor, so far as I can see, packages by which to install it.
The basic problem is that, with PHP-7, the authors rather-indiscriminately "deprecated" a whole bunch of things. It didn't seem to occur to them, for example, that production code might still be using the "old" regular-expression functions: out they go! (Until you write a very simple module to re-implement them.)
The original mysql interface functions are simply ... gone. There are two replacements and, as far as I can tell, one of them doesn't work. Neither one is plug-compatible with the old. (Until you write another not-quite-so-simple module to re-implement them, too.)
You'll be doing a lot of that kind of rework, and you'd better plan and budget for it. You'd better set up a virtual machine running this new version and see how your existing software base works blows-up with it.
Given the short amount of time left to make an initial migration and the general problems of PHP, even between point changes, I'd aim for testing 14.04 LTS first because it has one of the PHP5 variants still. That would buy a few years in which to migrate the web services to PHP7.
Given the short amount of time left to make an initial migration and the general problems of PHP, even between point changes, I'd aim for testing 14.04 LTS first because it has one of the PHP5 variants still. That would buy a few years in which to migrate the web services to PHP7.
That appears to me to be a sensible solution. I just finished working (with a very small team) to convert a major set of websites from PHP5 to PHP7 – and to the web – and it took about one year to do it.
I wrote a number of 'helper' tools, including one that can estimate register_globals requirements (given that this facility is entirely gone now ...), and to do a number of other related things, which I plan to soon post to GitHub.
if you are going PHP 7 then you should go for PHP 7.1, as far as PHP 7.0 goes, its EOL is before PHP 5.6's as PHP 5.6 has an extended EOL (due to being the last 5 release). http://php.net/supported-versions.php
Naturally I will be glad to see the death of mysql_query() when mysqli:repare and pdo:repare are much superior options. But things like the death of the old mysql module for php are probably some of the areas where major redevelopment is needed in code...
Last edited by r3sistance; 04-14-2017 at 07:35 AM.
Aidan:
To see if a machine is eligable manually, open a terminal and issue:
Code:
sudo ubuntu-support-status
peek at the result, similar to this one in output format, but yours will have differing details:
Code:
[sudo] password for jj:
Support status summary of 'mywik-fu':
You have 551 packages (91.5%) supported until May 2019 (5y)
You have 4 packages (0.7%) that can not/no-longer be downloaded
You have 47 packages (7.8%) that are unsupported
Your Hardware Enablement Stack (HWE) is supported until April 2019.
Run with --show-unsupported, --show-supported or --show-all to see more details
You really have to get "current" on an LTS. I suggest LTS to LTS with regular updates to the server.
LinuxQuestions.org is looking for people interested in writing
Editorials, Articles, Reviews, and more. If you'd like to contribute
content, let us know.