Print this page

Multiple PHP versions

Does BlueOnyx support using multiple different PHP versions?

Yes, BlueOnyx 5209R does.

We just published updates for BlueOnyx 5209R to allow you to run multiple PHP versions at the same time. By default 5209R runs with the OS supplied PHP-5.4.16. Virtual sites can then use that version of PHP via various different selectable alternatives:

  • PHP (DSO)
  • PHP (DSO + mod_ruid2)
  • suPHP
  • PHP-FPM

Each of these implementation has different benefits. Naturally, for enhanced security you should use one of the last three options, as they allow to run PHP scripts under the UID and GID of the siteAdmin of the virtual site that they belong to.

Now after his massive BlueOnyx 5209R update you have a few more options available. There are several different optional PHP versions available in the BlueOnyx Shop:

  • 5209R-PHP53-5.3.29-1.pkg (EOL)
  • 5209R-PHP54-5.4 (latest version)
  • 5209R-PHP55-5.5 (latest version)
  • 5209R-PHP56-5.6 (latest version)
  • 5209R-PHP70-7.0 (latest version)
  • 5209R-PHP71-7.1 (latest version)
  • 5209R-PHP72-7.2 (latest version)

The new thing is that you can now install all of them at the same time - if you wish to do so!

Once installed, the new PHP version(s) become available for usage. Provided you enable them in the PHP settings of your BlueOnyx 5209R:

This GUI page allows you to enable/disable the various installed (optional) PHP versions. You can also choose to switch the Apache webserver to a different PHP version than the OS provided PHP-5.4.16. However, due to the new implementation of PHP this may no longer be necessary, as you can now choose which PHP version a virtual site should use:

If multiple PHP versions are installed (and active), then you can choose the PHP version which a virtual site should use in a pulldown called "Vsite PHP Version".

Please note: This only works if suPHP or "FPM/FastCGI" are used. The "PHP (DSO)" based methods still use the default PHP version. Which can either be the OS supplied one, or one from the extra PHP packages that are installed and active.

To make it easier to identify the PHP versions that virtual sites are using the Virtual Site List has also been modified to show the PHP version that virtual sites use:

The new PHP packages are available in the BlueOnyx shop. If you have purchased PHP for BlueOnyx with a current support subsription to the PHP packages, then you will also get the updates to these packages whenever we release them. Once you install an updated PHP package for a certain version, then all virtual sites that use this version will start using the updated version.

When you remove a PHP extra package, then all virtual sites that currently use it will revert back to the OS provided PHP version of PHP.

The overhead of running different PHP versions at the same time is very small. So you can easily install all extra PHP versions and can use them all at the same time for different virtual sites.