• We value your experience with Plesk during 2024
    Plesk strives to perform even better in 2025. To help us improve further, please answer a few questions about your experience with Plesk Obsidian 2024.
    Please take this short survey:

    https://pt-research.typeform.com/to/AmZvSXkx
  • 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.

Changing php setup is not being written to apache config files

andre.spindler

Basic Pleskian
Environment:
CentOS 6.7 64bit (patches full up-to-date)
Plesk 12.5.30 Update #28 (full up-to-date)

My Setting:
Different service plans for each php version. Like "CMS 5.5", "CMS 5.6" or "CMS 7.0".
PHP is configured in all cases as FastCGI.

What occured now:
I wanted to change php version for one subscription from 5.5 to 5.6. Output in Plesk in subscription before: "PHP-Version: 5.5.34". Also shown when calling phpinfo(). Now I switch complete subscription to service plan 5.6. Success message is: "Information: Das Abonnement wurde erfolgreich neuen Service-Paketen zugewiesen.". Plesk shows "PHP-Version: 5.6.20". But output of phpinfo() is still version 5.5.34. All version references like ini path and configure command show version 5.5.

Now I did some research:
Vhost configuration is included in /etc/httpd/conf/plesk.conf.d/vhosts/. Configuration file of affected vhost is a symlink to /var/www/vhosts/system/XXXXXX/conf/httpd.conf.
listing the files in this directory I get:
insgesamt 52
-rw-r-----. 1 root apache 1935 8. Nov 2013 13839336850.79737700_httpd.conf
-rw-r-----. 1 root apache 5073 8. Nov 2013 13839337290.62611700_httpd.conf
-rw-r-----. 1 root apache 5089 8. Nov 2013 13839478300.70464800_httpd.conf
-rw-r-----. 1 root apache 5180 17. Jan 2014 13899150480.49837600_httpd.conf
-rw-------. 1 root apache 6254 18. Nov 01:00 httpd.conf
-rw-------. 1 root apache 6254 18. Nov 01:00 httpd.conf.bak
lrwxrwxrwx. 1 root root 10 18. Nov 01:00 last_httpd.conf -> httpd.conf
-rw-r--r--. 1 root root 0 1. Apr 09:53 prev_month.found
-rw-r--r--. 1 root root 3 17. Apr 05:03 stat_ttl.conf
-rw-r-----. 1 root apache 303 8. Nov 2013 vhost.conf
As you can clearly see, plesk hasn't touched the configuration file. And therefore the php version has not changed and is still on 5.5.

Attempt to fix also failed:
Back in Plesk web interface, I opened the subscription to change directly the php version of the affected subdomain in its webhosting settings. But version 5.6.20 is already selected in the dropdown. I don't modify any input field and submit the current configuration to get plesk refactoring the configuration of this singe vhost.
I now get an error message: "Fehler: hosting update is failed: vhostmng-structure failed: Cannot create directory /advent_httpdocs/cms: Permission denied System error 13: Permission denied". And this a wrong error message. There is not "no access" to this directory but it already exists and couldn't be created a second time. Access rights for this directory are "drwxrwx---. 3 apache psacln 4096 24. Nov 01:00 advent_httpdocs". Parent directory has "drwxr-x---. 13 <user, blacked> psaserv 4096 8. Nov 2013 <domain, blacked>".

Directory structure looks good, must be a plesk bug.
 
I have checked this issue according to your steps and can't reproduce this issue. After changing service plan for subscription, version of PHP has been changed correctly (with phpinfo). You can try to repair web configuration with repair utility and check this issue again. Contact Support Team if it does not help.
 
Last edited:
I just have created a new domain/vhost within the subscription. When I changed PHP version of this newly created one, all works as expected.
Crosschecking with the vhost I tried yesterday: still the same error. I had to manually change the httpd.conf.

In my opinion these are at least two issues:
  1. Plesk fails when writing the new configuration.
  2. Pleak even doesn't notice it. Plesk for itself stores the new values, but apace config still uses the old ones. And You receive a success message in Plesk that changing of configuration has benn successfull. What a shi...!
Is it important here that the server was initially setup some years ago with Plesk 10.0.1? In the directory listing above you see that the last modification on th httpd.conf file was on Nov 18th. I think this was the day I did the upgrade from Plesk 12.0.x (18? 52?) to 12.5.x.
Perhaps this is a migration issue?

What repair utility do you mean? Is it 100% to use it? Or must I be aware of killing some ather running vhost? I hope not?
I think you mean the tool available with "plesk repair".
I just di a test and got the following:
------------------------------------------------------------------------------------------------------
[root@<hostname>]# plesk repair web -n

Repairing web server configuration .................................. [OK]

Checking the usage of PHP handlers .................................. [OK]

Error messages: 0; Warnings: 0; Errors resolved: 0
------------------------------------------------------------------------------------------------------
Seems like there are no errors and issues...
 
Back
Top