I'm just starting learning Linux. I'm using CentOS 6.3 and i really like it. However I need PHP 5.4, currently not available for CentOS. I've read that CentOS, for its very own nature, doesn't update packages frequently.
Which distribution would you suggests for replacing CentOS and let me enjoy latest version of both Apache/PHP?
Don't give up on CentOS just yet!
A common process for resolving this problem is to tap into the REMI repository in order to obtain current PHP and MYSQL packages.
This should satisfy your request and still keep things manageable via Yum.
Instructions:
You will need the EPEL repository first. Then the REMI files.
That's all in order to get the repo. For PHP, something like:
You can install PHP 5.4 via Webtatic repo:
I have best results on Centos 6 using EPEL with IUS repositories.
# yum search php54
The combined repositories give excellent package access with very low version conflict. This is also a great way to get nginx and php-fpm.
If it's a development machine (i.e., not a long lived server), you can look at the closely related Fedora. The current version of Fedora ships with PHP 5.4.1.
The Fedora Project is sponsored by Red Hat as a sort of test bed for future RHEL ideas, so both CentOS and Fedora are closely related. The trick is that Fedora is cutting edge (new releases are every 6 months), but security and bug-fix updates will cease after about 13 months, which makes it unsuitable for server deployments.
You should also consider how PHP 5.4 will get installed on any future server platform. As noted, Fedora isn't suitable for server deployment unless you don't expect the server to be around a year later, as it will be unsupported at that point.
You could install the compiler, tools and libs;
Then compile Apache and PHP from source into /opt/local, then add that to your $PATH