Using 2.1.5, I'm getting an error message saying:

"Magento_Integration schema: current version - 2.2.0, required version - 2.0.1" 

I've tried setup:update and setup:db-data:upgrade.

The site was installed via cPanel/installation version 2.0.7 and has been upgraded several times.

The only thing that brings the site back online is if I edit the Magento_Integration entry of the setup_module table which I would think is not a good idea.


Have a look at setup_module table into the database.

You should see something similar to this:

enter image description here

In order to fix it, set the values manually to 2.0.1 for both schema and data and then try to upgrade again with the following:

bin/magento setup:upgrade

Then flush cache:

bin/magento cache:flush

It looks like for some reason the upgrade did not work or did not finish but Magento update setup_module table.

By setting those values manually and running the upgrade afterwards you are forcing the upgrade one more time.

You can actually see what this particular upgrade does in:

// \Magento\Integration\Setup\UpgradeData::upgrade()

public function upgrade(ModuleDataSetupInterface $setup, ModuleContextInterface $context)

        if (version_compare($context->getVersion(), '2.2.0', '<')) {


As you can see, all it does it to remove revoked and inactive tokens.

  • That is what I see. But I still get an error after running setup:upgrade and cache:flush. The error goes away if I change both to 2.0.1 but I'm guessing that's not a good idea. – Mike James Aug 14 '17 at 16:25
  • Could you try setting both values to 2.0.1 manually, and then executing bin/magento setup:upgrade – diazwatson Aug 14 '17 at 16:32
  • That works. But will I be causing a problem by doing that? Something set the values to 2.2.0. – Mike James Aug 14 '17 at 17:06
  • I have updated my answer with some more details. – diazwatson Aug 14 '17 at 20:25

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

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