Advice on which Centos version, due to PHP versions

8 posts / 0 new
Last post
#1 Fri, 10/16/2015 - 04:05
amityweb

Advice on which Centos version, due to PHP versions

Hi

I wondered if someone could help me make a decision...

I have been using Centos 6 for years and its very stable. But the PHP version is 5.3 and I can add a second version 5.4. Well, 5.4 is old now, there's newer versions not available for Centos.

I need to think of future proofing my servers for as long as possible. I ideally would like a server that I can have PHP 5.5, 5.6 in the future.

Firstly, does Centos 7 have these versions, and if so, is Centos 7 a stable OS to use right now? And with Virtualmin/Webmin on it? If so, then I can move onto Centos 7 and have newer PHP. But if its not syable, buggy etc. then I dont want to move to that, but then I am stuck with PHP 5.4 on Centos 6.

I dont want to use Ubuntu, I have installed an Ubuntu server and got Php 5.6 on it, but I am finding I get fcgi errors on that often with 500 errors on sites, I cant fix them, and this has really put me off using Ubunu when my Centos 6 installations have been very stable. You also cannot move sites between Centos and Ubuntu servers using Cloudmin as they dont work due to errors in the apache conf files.

Thanks

Fri, 10/16/2015 - 09:19
andreychek

Howdy,

There is support for using multiple PHP versions through the SCL repository.

The documentation for this currently only shows how to get this working with CentOS 6 -- we're working on updating this, and soon it will work with CentOS 7 as well.

In the meantime, you may want to check and see if there's a newer version of PHP in the SCL repo for CentOS 6 though, it wouldn't surprise me to see 5.5 or 5.6.

-Eric

Fri, 10/16/2015 - 15:31
Diabolico
Diabolico's picture

Firstly, does Centos 7 have these versions, and if so, is Centos 7 a stable OS to use right now? Yes, there are few repo what have never versions and they work but guys from Vmin prefer SCL. Wait for them to update wiki or use google to find the help. And with Virtualmin/Webmin on it? What i know 5.5 and 5.6 should work without any problem, not sure for other versions. If so, then I can move onto Centos 7 and have newer PHP. But if its not syable, buggy etc. then I dont want to move to that, but then I am stuck with PHP 5.4 on Centos 6. Centos 7 right now is stable so if you have the opportunity you can switch from Centos 6. My only advice do not upgrade 6 to 7 but rather go for fresh install.

- I often come to the conclusion that my brain has too many tabs open. -
Failing at desktop publishing & graphic design since 1994.

Fri, 10/16/2015 - 16:58
nibb

CentOS 7 is stable but upgrading will not solve your PHP problem either. CentOS 7 ships with 5.4.16 which already reached its end of life as well, so you will need to install an alternative PHP repo if not replacing the default one.

This PHP version is secure, as bugs and patches are back ported but still some applications will warn you and complain that your PHP version is old. Its safe to run it unless you need newer versions.

Sat, 10/17/2015 - 04:40
amityweb

Although I have found various ways online to install higher versions of PHP on Centos 7, I've read on various topics here it could be risky using 3rd party repos, so I've always avoided those just in case. Also, some methods I found required manual changes to php.ini and httpd.conf I think.

On Centos 6 I have used the SCL to install PHP 5.4 as a second PHP version, and because of documentation on Virtualmin website about it, I went with this approach.

So do you think waiting for the ability to install a second version using SCL may be the best approach? Or is using 3rd party repos to upgrade PHP fine, and if so is there any preferred one?

Fri, 10/23/2015 - 16:52 (Reply to #5)
Joe
Joe's picture

We recommend SCL. And, we recommend not using third party repos that don't stick to those conventions (there are tons of SCL PHP packages now, from multiple packagers, so there's very little reason to look elsewhere).

I was just testing SCL versions on CentOS a couple days ago, and they aren't yet detected, but Jamie is working on making Virtualmin aware of SCL installed packages. In the short term, it take a bit of hacking (I modified the detection code in Virtualmin to detect the version I wanted to use), but in the next release or two, Virtualmin will Just Know what PHP version you prefer based on what is configured via the scl command.

SCL is kind of a fast-moving target lately, as they've been refactoring and adding support tools to make it easier to use SCL. It's really getting nice to use, and we'll be adding support for it as the tools stabilize. If you have trouble getting an SCL installed PHP version recognized, post about it, and we'll help you sort it out. I think Eric has been suggesting symlinks, but I think I prefer just updating the detection code in Virtualmin. Neither one is a good long-term solution, but either will get you up and running with newer PHP versions without a huge amount of hassle.

--

Check out the forum guidelines!

Mon, 10/26/2015 - 05:06
amityweb

Thanks. I have decided to install Centos 7 with PHP 5.4 based what is said above, that SCL is coming to it soon, which will allow me to install higher versions of PHP for future proofing.

Thanks

Mon, 10/26/2015 - 10:17
andreychek

I'm working on instructions for the SCL repo on CentOS 7 now, we should have something posted soon!

-Eric

Topic locked