• If you are still using CentOS 7.9, it's time to convert to Alma 8 with the free centos2alma tool by Plesk or Plesk Migrator. Please let us know your experiences or concerns in this thread:
    CentOS2Alma discussion

Unable to select 'run PHP as..' on /smb/web/php-settings

nilsringersma_nl

Basic Pleskian
Dear All,

Info:
OS ‪CentOS Linux 7.3.1611 (Core)‬
Product Plesk Onyx
Version 17.5.3 Update #3, last updated on April 19, 2017 04:29 AM

Problem:
As of today we were prompted by a client that he can no longer select a PHP version on any subscription with the PHP-settings button. The dropdown with installed PHP versions does appear, but the 'run PHP as' dropdown remains empty.

screenshot1.png:
screenshot1.png


When selecting a different version from the dropdown the following error comes up (where the id is the subscription id):
{"redirect":"\/web\/php-settings\/id\/293","status":"error","statusMessages":[]}

screenshot2.png:

screenshot2.png


When navigating back to the subscriptions panel the error 'Permission Denied' is printed above the subscription (on top of the page).

screenshot3.png
screenshot3.png


Changing the PHP versions from the 'Hosting Settings' menu does work. It is possible to select a PHP version and 'run PHP as..' is also available.

screenshot4.png:
screenshot4.png


Question:

There is no output in /var/log/sw-cp-server/error_log and /var/log/sw-cp-server/sw-engine.log. Neither does the plesk repair module output anything of interest.

I'm kinda lost here, any help or suggestions would be appreciated!
 
Hi Holtes Design,

could you pls. post the output of ( logged in as user "root" over SSH ):

Code:
plesk bin php_handler --list

Pls. consider as well to use the "RE-READ" option and check again the listing. ( => plesk bin php_handler --reread )
 
Hi Holtes Design,

could you pls. post the output of ( logged in as user "root" over SSH ):

Code:
plesk bin php_handler --list

Pls. consider as well to use the "RE-READ" option and check again the listing. ( => plesk bin php_handler --reread )

Dear UFHH01,

Thanks for your quick reply, really appreciated.

Please find the output attached.
 

Attachments

  • plesk bin php_handler --list.txt
    3 KB · Views: 3
  • REREAD_plesk bin php_handler --list.txt
    3.1 KB · Views: 1
Hi Holtes Design,

did you notice, that some PHP - handler are disabled by default now?
Code:
      plesk-php54-cgi               5.4.45         5.4.45       5.4      cgi   /opt/plesk/php/5.4/bin/php-cgi  /opt/plesk/php/5.4/bin/php  /opt/plesk/php/5.4/etc/php.ini     true disabled

      plesk-php56-cgi               5.6.30         5.6.30       5.6      cgi   /opt/plesk/php/5.6/bin/php-cgi  /opt/plesk/php/5.6/bin/php  /opt/plesk/php/5.6/etc/php.ini     true disabled

               module  5.4.16 by OS vendor         5.4.16       5.4   module                 /usr/bin/php-cgi                /usr/bin/php                    /etc/php.ini    false disabled

      plesk-php53-cgi               5.3.29         5.3.29       5.3      cgi   /opt/plesk/php/5.3/bin/php-cgi  /opt/plesk/php/5.3/bin/php  /opt/plesk/php/5.3/etc/php.ini     true disabled

      plesk-php70-cgi               7.0.18         7.0.18       7.0      cgi   /opt/plesk/php/7.0/bin/php-cgi  /opt/plesk/php/7.0/bin/php  /opt/plesk/php/7.0/etc/php.ini     true disabled
                  cgi  5.4.16 by OS vendor         5.4.16       5.4      cgi                 /usr/bin/php-cgi                /usr/bin/php                    /etc/php.ini    false disabled


To enable the disabled PHP - handler, you might use for example:
Code:
plesk bin php_handler --enable -id plesk-php54-cgi
or
Code:
plesk bin php_handler --enable -id plesk-php70-cgi

I still have to mention, that these DISABLED PHP - Handler are declared as insecure by now and therefore shouldn't be used anymore!


Pls. go as well to your subscription settings and check the default settings for each subscription and pls. don't forget that with your service plans, you might change all subsriptions at once, after changing the setting and syncing should be done automatically ( if the subscriptions are not "locked" ).


If you checked your settings and still experience any issues/erorrs/problems as described, pls. consider to use as well the Plesk Repair Utility: => Plesk Repair Utility

Example usage:
Just check, WITHOUT repair!
Code:
plesk repair all -n -v

Repair modus WITHOUT automatic YES answers to each question
Code:
plesk repair all -v

Repair modus WITH automatic YES answers to each question
Code:
plesk repair all -n -v
Consider to POST the corresponding repair - log from "/var/log/plesk", if you still experience issues after your repair procedure.​



Additional notice:

Sometimes, it is as well a good idea to change the log - level ( TEMPORARILY! ), to get more informations in Plesk - log - files:

 
Last edited by a moderator:
Hi Holtes Design,

did you notice, that some PHP - handler are disabled by default now?
Code:
      plesk-php54-cgi               5.4.45         5.4.45       5.4      cgi   /opt/plesk/php/5.4/bin/php-cgi  /opt/plesk/php/5.4/bin/php  /opt/plesk/php/5.4/etc/php.ini     true disabled

      plesk-php56-cgi               5.6.30         5.6.30       5.6      cgi   /opt/plesk/php/5.6/bin/php-cgi  /opt/plesk/php/5.6/bin/php  /opt/plesk/php/5.6/etc/php.ini     true disabled

               module  5.4.16 by OS vendor         5.4.16       5.4   module                 /usr/bin/php-cgi                /usr/bin/php                    /etc/php.ini    false disabled

      plesk-php53-cgi               5.3.29         5.3.29       5.3      cgi   /opt/plesk/php/5.3/bin/php-cgi  /opt/plesk/php/5.3/bin/php  /opt/plesk/php/5.3/etc/php.ini     true disabled

      plesk-php70-cgi               7.0.18         7.0.18       7.0      cgi   /opt/plesk/php/7.0/bin/php-cgi  /opt/plesk/php/7.0/bin/php  /opt/plesk/php/7.0/etc/php.ini     true disabled
                  cgi  5.4.16 by OS vendor         5.4.16       5.4      cgi                 /usr/bin/php-cgi                /usr/bin/php                    /etc/php.ini    false disabled


To enable the disabled PHP - handler, you might use for example:
Code:
plesk bin php_handler --enable -id plesk-php54-cgi
or
Code:
plesk bin php_handler --enable -id plesk-php70-cgi

I still have to mention, that these DISABLED PHP - Handler are declared as insecure by now and therefore should be used anymore!


Pls. go as well to your subscription settings and check the default settings for each subscription and pls. don't forget that with your service plans, you might change all subsriptions at once, after changing the setting and syncing should be done automatically ( if the subscriptions are not "locked" ).


If you checked your settings and still experience any issues/erorrs/problems as described, pls. consider to use as well the Plesk Repair Utility: => Plesk Repair Utility

Example usage:
Just check, WITHOUT repair!
Code:
plesk repair all -n -v

Repair modus WITHOUT automatic YES answers to each question
Code:
plesk repair all -v

Repair modus WITH automatic YES answers to each question
Code:
plesk repair all -n -v
Consider to POST the corresponding repair - log from "/var/log/plesk", if you still experience issues after your repair procedure.​



Additional notice:

Sometimes, it is as well a good idea to change the log - level ( TEMPORARILY! ), to get more informations in Plesk - log - files:


Dear UFHH01,

When opening /usr/local/psa/admin/logs/panel.log I noticed that I did manage to retrieve some info from the Plesk Log when I reproduced the problem this morning. Perhaps this wil help you?

Code:
[2017-04-20 10:22:42] ERR [panel] Permission denied.
[20-Apr-2017 10:22:44 UTC] PHP Warning: array_key_exists(): The first argument should be either a string or an integer; File: /usr/local/psa/admin/plib/Smb/Form/Final/Web/PhpSettings.php, Line: 98

[2017-04-20 10:22:44] ERR [1] PHP Warning: array_key_exists(): The first argument should be either a string or an integer; File: /usr/local/psa/admin/plib/Smb/Form/Final/Web/PhpSettings.php, Line: 98

[2017-04-20 10:24:50] ERR [panel] Permission denied.
[2017-04-20 10:26:56] ERR [panel] Permission denied.
[2017-04-20 11:20:23] ERR [panel] Permission denied.
[2017-04-20 11:46:55] ERR [util_exec] proc_close() failed ['/usr/local/psa/admin/bin/vhostmng-content'] with exit code [1]
[2017-04-20 11:46:55] ERR [1] '/usr/local/psa/admin/bin/vhostmng-content' failed with code 1.

stdout:
Fatal error: std::runtime_error(can not parse data from stdin : Invalid or unsupported Unicode character or escape sequence found in string. UTF8 encoded characters and '\u' escape sequences are not supported. Error occured at offset 418246, character '\'. Also system error occured: No such file or directory (2).)


stderr:
Fatal error: std::runtime_error(can not parse data from stdin : Invalid or unsupported Unicode character or escape sequence found in string. UTF8 encoded characters and '\u' escape sequences are not supported. Error occured at offset 418246, character '\'. Also system error occured: No such file or directory (2).)

Besides this snippet, I just took all the steps suggested by you. It had no effect on the PHP selector. When repairing Plesk I generated a debug log, please find it attached. Any ideas?
 

Attachments

  • debug_repair.txt
    1,005.5 KB · Views: 6
Hi Holtes Design,

your issue:
Code:
Invalid or unsupported Unicode character or escape sequence found in string
Could point to some issues, when folders/files for example are named with unsupported characters ( i.e. hieroglyphs or something similar ).

If this is the case, then you might have hit a current bug for such issues and it should be fixed in an upcoming update/upgrade/patch. You might consider to post your "bug" - report as well at => Home > Forum > Plesk Discussion > Reports , so that this may be forwarded to the Plesk developpers. :)
 
Hi all,

same issue here, but only for domains create _before_ the upgrade to 17.5.3. New domains are ok. Logs look similar to what was posted above. Is there any way to find out what is causing the permission denied error? To me it looks like it trys to read something and that fails which then causes the subsequent errors regarding characters (array not popolated?). Just an idea...

Axel
 
Hi Axel P,

pls. consider to stick to ONE thread, so that it is easier to help you with possible issues/errors/problems! ;) ( Double post: => #7 )
 
I have the same issue. On opening the selectbox for "run as" is empty. When selecting another PHP Version e.g. from 7.0 to 7.1 the logfile (/usr/local/psa/admin/logs/panel.log) shows the following error:

[2017-04-25 09:37:35] ERR [panel] Zugriff verweigert.​

I have updated two Servers to Version 17.5.3 Update #3 on Debian 7.11‬ where this issue apears.

The Solutions mentioned above doesn't work.
 
I confirm the issue mentioned above by Rene, it is replicated on 3 different servers based on CentOS 6.9 (all updated to Plesk Onyx 17.5.3).
 
I have exact the same problem since update to Onyx 17.5.3 on ‪Ubuntu 14.04.5

array_key_exists(): The first argument should be either a string or an integer; File: /opt/psa/admin/plib/Smb/Form/Final/Web/PhpSettings.php, Line: 98
 
I have exact the same problem since update to Onyx 17.5.3 on ‪Ubuntu 14.04.5

array_key_exists(): The first argument should be either a string or an integer; File: /opt/psa/admin/plib/Smb/Form/Final/Web/PhpSettings.php, Line: 98

Yes this error occure on save the settings with empty "run as" setting, at my servers too.
 
The error still exists after checking all steps an enabling/disabling php-handler.
I also installed the latest update 4 for plesk 17.5.3

When selecting the php-handler in php-settings of domain i get the "permission denied" error.
PHP version/handler could be changed successfully via hosting settings of an domain!

Interesting:
The error exists only for domains that have been created before upgrading to plesk 17.5.3. (from 17.0.xx from 12.5.xx)
Fresh created domains

@plesk
Please consider this as global bug not as individual errors! I've created an bug report.
Please tell us what logs do you need to investigate that problem.

Thanks!
 
Hey,

For those who just want to change PHP version of domains, you may change the PHP version in "Hosting Settings" page instead of "PHP Settings" page. This option works in Hosting Settings page. (PHP Settings page, seems to have a bug in it).

Hope that helps.
Iman
 
We have the same issue since update from 17.0 to 17.5.

This option works on new account, old account have the same issue. Please check!

Betriebssystem‪Debian 8.7‬
Produkt Plesk Onyx
Version 17.5.3 Update #4, zuletzt aktualisiert: 27. April 2017 06:30:28
 
Last edited:
Same issues here on two different servers(CentOS 6.9 and CentOS 7.3) both after installed Plesk Onyx 17.5 update 4
 
Same Issue here on CentOS 6.9, but only Domains/Subscriptions which are created under 12.x and earlier are affected.
On domains which where created under Onyx 17.0 or 17.5 everything seems to be fine!
 
I have the same problem. If I want to switch to php 7.0.13 I will get the message

{"redirect":"\/web\/php-settings\/id\/4","status":"error","statusMessages":[]}

and in /var/log/plesk/panel.log I get

ERR [panel] Access denied.

My system:
  • Debian 7.11‬
  • Plesk Onyx
    Version 17.5.3 Update #4, zuletzt aktualisiert: 2. Mai 2017 14:05:59
 
Back
Top