• 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.

Resolved Loaded php.ini is not same on panel and ssh

Ahmad12

Basic Pleskian
Hello,

I've this issue with all my vhosts that in plesk panel the loaded php is not the same when i'm checking it in ssh:
in the panel as per phpinfo the php.ini is loaded from: /opt/plesk/php/7.0/etc/php.ini
in the ssh as per (php -i | grep "Loaded Configuration File") the php.ini is loaded from: /etc/php.ini

please help solving this issue..

Regards,
 
In Plesk for Linux, the PHP binary (the php file) is located in the following path:

/opt/plesk/php/<PHP version>/bin/php

Here <PHP version> should be replaced with a particular PHP version number.

For example, if you need to use PHP verion 7.0, use the following command to run the my_script.php script:

/opt/plesk/php/7.0/bin/php my_script.php
 
I'm installing magento 2, so the webserver php version is 7.0.8 but in command it is taking the os php version and not the webserver php, how to make the command use the webserver php version?
 
@IgorG how to make the vhost work always with assigned php version everywhere?

Yes it is working when i'm using : alias php='/opt/plesk/php/7.0/bin/php', but ehy do i need to use that every time i need to run something? my cronjobs reading the main php configuration on plesk panel.
 
Back
Top