• Please be aware: Kaspersky Anti-Virus has been deprecated
    With the upgrade to Plesk Obsidian 18.0.64, "Kaspersky Anti-Virus for Servers" will be automatically removed from the servers it is installed on. We recommend that you migrate to Sophos Anti-Virus for Servers.
  • The Horde webmail has been deprecated. Its complete removal is scheduled for April 2025. For details and recommended actions, see the Feature and Deprecation Plan.
  • We’re working on enhancing the Monitoring feature in Plesk, and we could really use your expertise! If you’re open to sharing your experiences with server and website monitoring or providing feedback, we’d love to have a one-hour online meeting with you.

FastCGI PHP 5.2.13 / 5.3.2 NTS (Non thread safe)

error

Actually you need to keep the packaged PHP installs provided by Plesk untouched.

You can add some additional PHP versions in the C:\Program Files (x86)\Parallels\Plesk\Additional\.

Here is the procedure I am using:
- you create a folder named PHP535NTSVC9X64 (I named it to know exactly what type of build it is).
- unzip the build inside.
- add a php.ini (if it is PHP5.3, you might need to start over with a fresh configuration)
- pay attention to have the correct folders for extension. Mine is include_path=".;C:\Program Files (x86)\Parallels\Plesk\Additional\PHP534NTSVC9\pear;./includes;./pear"
- add any compatible additional extension (like Wincache) in the ext folder.
- in your Plesk domain site, uncheck PHP support.
- in IIS7, go to the given site.com and click on Handler Mappings
- Click on the right, on Add Module Mapping
- Request path: *.php Module: FastCgiModule
- for the Executable: browse, look for php-cgi.exe and don't forget to add double quotes. For instance: "C:\Program Files (x86)\Parallels\Plesk\Additional\PHP535NTSVC9X64\php-cgi.exe"
- Name it clearly PHP_5_3_5_NTS_VC9_name_site
- When you click ok you got a message to create a FastCGI application for this executable, click on Yes.
- In IIS7, go to the server main node (right below Start Page).
- Click on FastCgi Settings
- Select the proper Full Path corresponding to your new PHP application and double click on it
- Set InstanceMaxRequests to 10000 instead of 200 (I am not sure why I still do that)
- At the same line, to the right of EnvironmentVariables, double click on (Collection)
- In the environmentVariables Collector Editor, create a variable
- Name: PHPRC Value: C:\Program Files (x86)\Parallels\Plesk\Additional\PHP535NTSVC9X64\ (that's your new PHP install path). The PHPRC env variable provides some information to where to find the php.ini file.
- Eventually restart the application pool linked to your domain, or restart the IIS service from the IIS7 main node. (not forcefully required)
- Place a phpinfo.php file containing <?php phpinfo(); ?> in your site web root
- Try to see if you can access it, and check out that all is ok and loaded.

I have more than 9 versions of PHP on my server. It works nicely. Still, you might need to be careful if you have several versions using the same application pool for several subdomains. Sometimes, mixing a PHP 5.2 32bit build with a PHP 5.3 64bit build causes issues. Though I just managed to have two PHP 5.3 x64 NTS builds working together on the same domain.
Note that you can also make the handler using a web.config in your web root.

I hope you will be able to make it.
Arnaud.

edit to fix typos

Hi,
thanks for this guide,
for 5.3.10 its working (with php.ini from 5.1.x).
For 5.4 I do unfortunately get the following error (even with fresh php.ini)

In addition:
How do I get it done to have this/another PHP Version added to the existing ones offered by Plesk (dropdown list under Webhosting) for everyone to choose?

Thanks for your help

HTTP Error 500.0 - Internal Server Error
C:\Program Files (x86)\Parallels\Plesk\Additional\php540\php-cgi.exe - The FastCGI process exited unexpectedly
-----------------
Module FastCgiModule
Notification ExecuteRequestHandler
Handler php540_Christian_siebers.de
Error Code 0xffffffff
Requested URL http://mydomain.de:80/phpinfo.php
Physical Path C:\inetpub\vhosts\mydomain.de\httpdocs\phpinfo.php
Logon Method Anonymous
Logon User Anonymous

Where do I look for the solution?
 
No icon for FastCgi Settings in Main Node of the server

Plesk Version: 9.0.1 for Windows

After creating domain handler mapping as instructed, when I went to main node of the server in IIS7, I did not see any icon for FastCgi Settings. However there is a domain working with FastCgi option and module is very much listed that is why I was able to create Handler Mapping for the domain for "FastCgiModule".

Screenshots of both the screens are given below:
Domain Handler Mapping: http://i.imgur.com/r0gV5.gif
Server's Main Node: http://i.imgur.com/HUvwL.gif

I am now stuck here and can not proceed further.

Here, I would like to mention that my first preference was not to have PHP 5.3.10 in addition to existing PHP 5.2.6 but to have the latest version instead. Therefore, first I followed the instructions as per article ttp://kb.parallels.com/6670 which did not work out and new version was not recognizable by Plesk at all and I could not see it in Server Components. After this, I followed the instructions given here by ArnaudT which I found very interesting and may be the only possible work around to my problem.

Can someone help me here?

Thanks.
 

Attachments

  • ServerMainNode.gif
    ServerMainNode.gif
    26.7 KB · Views: 3
  • DomainHandlerMapping.gif
    DomainHandlerMapping.gif
    13.2 KB · Views: 5
Back
Top