Start a conversation

Setting environment manually PHP 5.4 - CentOS

This article describes how to install the PHP 5.4 on a CentOS 5 or CentOS 6 server

1. First, detect if any PHP packages are installed:


   If packages are installed remove them, for example:

2. Add PHP 5.4 packages to yum using this command for CentOS 5.x

    Or, for CentOS 6.x:

    Now, you can check if the new PHP (5.4: php54w ) packages are available:

    Or, version specific search: 

3. Next, install the PHP 5.4 packages, for example when installing PHP 5.4 packages I used:

    PHP should now be upgraded to the new version, you can verify with the command: 

4. Finally, restart the Web server:

Choose files or drag and drop files
Was this article helpful?
  1. Ronyan Alves

  2. Posted
  3. Updated