0

I'm trying to install a new magento 2.4.5 store by CLI using this command:

composer create-project --repository-url=https://repo.magento.com/ magento/project-community-edition:2.4.5

Ok this install correctly, but when i run the setup:install command, it returns this error:

enter image description here

The same error happens when i run "php bin/magento cache:flush" and others commands. What could it be? any help is appreciated.

setup:install command:

bin/magento setup:install --base-url=http://loja245.local --base-url-secure=https://loja245.local --db-host=127.0.0.1 --db-name=magento --db-user=user --db-password=pass --admin-firstname=admin --admin-lastname=admin [email protected] --admin-user=user --admin-password=pass --language=pt_BR --currency=BRL --timezone=America/Sao_Paulo --use-rewrites=1 --search-engine=elasticsearch7 --elasticsearch-host=192.168.4.108 --elasticsearch-port=9200

I'm using PHP 8.1, MariaDB 10.4, mysql 8.0. Just like the adobe system requirements says.

2 Answers 2

1

The error message indicates Fiber::getCurrent() method is undefined, the Fiber class has been available since PHP 8.1, so make sure you are running at least PHP 8.1.

I see you mentioned you are using PHP 8.1 but could you double-check by running this command:

php -v

3
  • It's running on PHP 8.1.0-dev. Apr 24, 2023 at 19:34
  • I'm not sure PHP 8.1.0-dev contains Fiber class or not but since it has a vulnerability ('User-Agentt' Remote Code Execution). You should update your PHP version to at least 8.1.
    – Tu Van
    Apr 24, 2023 at 19:39
  • 1
    And you had this error so we can assume PHP 8.1.0-dev does not have Fiber class yet.
    – Tu Van
    Apr 24, 2023 at 19:42
0

try removing composer.lock file and re run composer install it will fix the issue.

Your Answer

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

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