1

I have installed fresh Magento 2.2.6 and i have installed two custom modules.

Then i have upgraded the Magento Version to 2.3.1 now i am trying to generate db_schema file for those module using below command.

php bin/magento setup:install --convert-old-scripts=1

Error:

[Symfony\Component\Console\Exception\RuntimeException]

The "--convert-old-scripts" option does not exist.

2
  • Will those modules have scripts that is InstallSchema Commented Apr 4, 2019 at 11:08
  • 1 has InsallSchema,UpgradeSchema, another has only UpgradeData Commented Apr 4, 2019 at 11:25

2 Answers 2

1

Run the below command

php bin/magento setup:install --convert_old_scripts=1

Instead of

php bin/magento setup:install --convert-old-scripts=1

For more information. Look at this

Guess this would be issue for your case.

EDIT :

Run this command in your root to check the available options there

php bin/magento setup:install -h

then you'll probably will get this

--convert-old-scripts[=CONVERT-OLD-SCRIPTS]

so run accordingly of whatever available for your version.

2
  • I have checked with fresh 2.3.1 setup the option convert-old-scripts is displaying but in the upgraded setup there are no convert-old-scripts found. Commented Apr 5, 2019 at 6:04
  • 1
    Guess the schema already been installed, try fresh magento with uninstalled modules on app/code @AshishViradiya Commented Apr 5, 2019 at 6:07
0

In order to generate db_schema.xml file for already installed modules follow below link

https://magento.stackexchange.com/a/273981/43981

1
  • Yes the answer is right but the command is not working after upgrade magento version. Commented May 10, 2019 at 14:35

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.