Skip to content

Upgrading Ubercart from Drupal 7

Robert J. Lang edited this page Oct 13, 2022 · 8 revisions

UPDATE: Backdrop Core (as of version 1.22) now automatically enables required modules during upgrade.

Just make sure that you have Entity UI and Entity Plus modules in your codebase before starting the upgrade.

## Upgrade Instructions

If you are upgrading an existing Ubercart installation from Drupal 7, there are some steps you can (should) take to ensure that your upgraded installation is fully enabled at the end of the process.

Stub Modules

The issue to deal with is that Backdrop Ubercart relies on three modules that don't exist in Drupal:

  • Ubercart (ubercart), a wrapper module for the core Ubercart modules;
  • Entity UI (entity_ui), needed for the Backdrop version of Rules;
  • Entity Plus (entity_plus), also needed for the Backdrop version of Rules.

When the Backdrop version of update.php runs, if those modules are not present and enabled, then the update will disable all of the Backdrop modules that depend on them, which includes all of Ubercart, plus any further customization modules.

So the solution is to install "stub" modules in the Drupal installation prior to generating the database from which the Backdrop upgrade will take place.

Upgrade Process

Assuming you are following the official upgrade instructions or something similar like this, do the following:

  1. Download and unzip these three modules, which are Drupal "stub" modules:

  2. In Step 2, "Prepare your Drupal site for upgrade", prior to substep 9 ("Make a second backup...calling it backdrop-ready.sql"),

    1. Install those three modules into sites/all/modules of your Drupal installation;
    2. Enable those three modules. (They don't do anything. This just makes your database know that they exist, or rather, that they will be forthcoming.)
  3. Continue with substep 9: make your second backup of the database to be used for Backdrop, e.g., backdrop-ready.sql.

  4. Once you have made that second backup, you can uninstall and remove the three stub modules from your Drupal installation.

  5. Continue with the rest of the migration/upgrade process.

Of course, make sure that you've already installed the Backdrop versions of Rules, Entity Plus, and Entity UI in your Backdrop contrib folder prior to running update.php, or all of the above will be for naught.