0

I upgraded my magento store from 2.4.2-p1 to 2.4.5-p1 and changed php version from 7.4 to 8.1 and I ran "composer update" successfully, then upgrade,compile and deploy static content. Now i have a problem with the topsearch it doesnt show me search recommendations and that is the error in (system.log) "/public_html/vendor/magento/framework/Data/Structure.php(329): Magento\Framework\Data\Structure->_insertChild('header-wrapper', 'top.search.byca...', NULL, 'topSearch')"

And when i tried to install cron jobs I got this error in (magento.cron.log) "Fatal error: Composer detected issues in your platform: Your Composer dependencies require a PHP version ">= 8.1.0". You are running 7.4.33. in /public_html/vendor/composer/platform_check.php on line 24" although when I checked the php version in cpanel MultiPHP Manager it was 8.1 also I ran php -v in terminal and it showed 8.1

1
  • If your php -v and phpinfo gaving same php version then command start from php bin/Magento If both version are different then you have to run with php path... Mar 16 at 15:21

2 Answers 2

1

This happened when you have disabled PHP functions: exec. ask your hosting provider or modify your php.ini file to remove it form disable_functions. then try to run php bin/magento cron:install --force

1

If you run apache as www-data check your crontab by running in terminal sudo crontab -u www-data -e to check if you are "really" using /usr/bin/php (php8.1 as you said) or the /usr/bin/php7.4

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.