Hello everyone,
I installed correctly magento 2.2, and my php version on the server is 7.1.4
When I try to launch a cmd such
php bin/magento cache:clean
the server said:
Magento supports 7.0.2, 7.0.4, and 7.0.6 or later. Please read http://devdocs.magento.com/guides/v1.0/install-gde/system-requirements.html
That's really strange, because in another server works perfect (and I followed the same instruction).
Is someone had the same issue?
Thank you very much
I have the same issue and I get
PHP 5.6.29 (cli) (built: Jan 6 2017 10:06:29) Copyright (c) 1997-2016 The PHP Group Zend Engine v2.6.0, Copyright (c) 1998-2016 Zend Technologies with the ionCube PHP Loader (enabled) + Intrusion Protection from ioncube24.com (unconfigured) v5.1.1, Copyright (c) 2002-2016, by ionCube Ltd. with Zend Guard Loader v3.3, Copyright (c) 1998-2014, by Zend Technologies
However my phpinfo.php shows
PHP Version | 7.1.7 |
Hi @cbinau,
That's becasue the version of PHP-CLI is different from the version used with the webserver.
You should fix that and then everything should work properly.
Hi, i had the same problem solved going around.
If you are using plesk this is the solution.
add:
/opt/plesk/php/7.1/bin/
before any php comand
example:
php bin/magento indexer:reindex
become
/opt/plesk/php/7.1/bin/php bin/magento indexer:reindex
php bin/magento cache:clean
become
/opt/plesk/php/7.1/bin/php bin/magento cache:clean
Hope this help
The command /opt/plesk/php/7.1/bin/ was fine for the magento commands, but when I use the compositor it does not work, it could indicate the solution. I need to uninstall an obsolete module swissup / absolute-metapackage to update magento2.
Thank you
add a PHP file named as "info.php" an at root directory with phpinfo()
open it through browser www.yourdomain.com/info.php
Here, search by $_ENV['PHPRC'] or PHPRC and get the value of it, in my case it was php:/opt/alt/php72/usr/bin/php-cgi so my final command to clear cache would be /opt/alt/php72/usr/bin/php bin/magento C:C