Answer the question
In order to leave comments, you need to log in
Installing multiple versions of php handlers for apache2
There is a production server with php 4.4.9 installed on it (these were the requirements for the current CMS) The server is spinning under Ubuntu 10.04
Now there is a need to deploy php 5.3
I did everything according to the instructions www.bsntech.com/bsntech-blog-mainmenu-321/computers- mainmenu-281/1681-install-two-versions-of-php-on-ubuntu-lucid-1004-php-53-and-php-52.html
In particular, I downloaded and installed the necessary version of PHP 5.3 in /opt/ php5.3.19
and make the corresponding config in apache:
<VirtualHost 127.0.0.1:80>
ServerAdmin [email protected]
DocumentRoot /var/www/new.unistar.by
ServerName new.unistar.by
ErrorLog /var/log/apache2/unistar_error_log
CustomLog /var/log/unistar_custom_log combined
ScriptAlias /cgi-bin-php/ "/opt/php5.3.19/bin/"
SetEnv PHP_INI_SCAN_DIR "/opt/php5.3.19/"
AddHandler php-script .php
Action php-script /cgi-bin-php/php-cgi
<FilesMatch "\.php">
SetHandler php-script
</FilesMatch>
</VirtualHost>
Answer the question
In order to leave comments, you need to log in
Once I managed to run the second version according to this instruction aboutubuntu.ru/content/php-5-2-fastcgi-php-5-3-apache2-ubuntu-10-04 , only to support pdo There are correct compilation arguments in the comments.
I tried it, it should work.
Apache definitely restarted after the settings?
I used to run different versions of php either on different Apache instances, which hung on different ports, or one on Apache, the other through factcgi.
Solved a similar problem. Blog post https://www.olegpro.ru/post/odnovremennaya_rabota_...
Didn't find what you were looking for?
Ask your questionAsk a Question
731 491 924 answers to any question