Drupal Migration: Steps to Migrate to Drupal 9

Drupal 9

Drupal is a popular, secure and free open-source content management system (CMS) that is used by education, government, churches, non-profits, large and small businesses and even Fortune 500 organizations. Over the years, Drupal has evolved and is still in the process of evolving with the technology sector. This is the reason there are multiple versions of Drupal currently being used by different companies. According to the Usage Statistics on the Drupal.org page as of 28th August 2022, more than 460K websites are still on Drupal 7 that is reaching end of life in November 2023.

This is a huge number and if you decide to continue with Drupal 7 or Drupal 8 then you might want to take into consideration the security concerns that you might face. But first let’s understand what Drupal migration means.

What is Drupal Migration?

Drupal migration is basically migrating a Drupal website or blog to Drupal 9 by converting it into a Drupal 9 installation. You can also install Drupal 9 from scratch. In order to migrate from Drupal 8 to Drupal 9, you must update both core and contributed modules and themes. You will need to convert any custom code into Drupal 9 compatible versions, such as custom content types, views, and fields. In addition, you may have to upgrade your database schema in order to support Drupal 9's new data model. As a final step, make sure that all your files have been converted to Drupal 9 standards.

What Do I Need to Know about Migrating to Drupal 9?

1. Preparation and Planning: 

The first step in the migration process is to prepare and plan for your website upgrade. Define what your targets are and ensure that you don't tag along any bad habits or abandoned features. After you are done with your planning, make sure you have a backup of your website and ensure that the required software is installed.

2. Update Your Site Core:

For your site to migrate successfully to Drupal 9, you must update to the latest version of Drupal 8 core. Using the same version of the core that you used during development will ensure your site works properly after migration.

3. Upgrade Modules and Plugins:

Your modules and plugins will need to be upgraded to their Drupal 9 versions when you migrate to Drupal 9. 

4. Convert Custom Code: 

In case of custom content types, views, or fields, you will have to convert them to Drupal 9 compatible versions. This will ensure that your new website works properly.

5. Modules Migration Path:

In order to make an informed decision, you need to know if there is a migration path for existing modules and identify alternative approaches where gaps exist. Typically, the process begins with taking an inventory of the existing modules and content, verifying and documenting existing functionality, and identifying code that has been deprecated.

Upgrading Drupal 7 to Drupal 8

Step 1: Take back-up of your website.
Step 2: Import the Drupal 7 database
Step 3: Install a fresh new site.
Step 4: Setup a local Drupal 8 website for the migration.
Step 5: Verify the modules are in core and enabled.
Step 6: Upgrade your website.
Step 7: Enter website details.
Step 8: Start the migration.

Upgrading Drupal 8 to Drupal 9

Migration to Drupal 9 from Drupal 8 is quite straightforward. It is much easier to upgrade Drupal 9 than it is to upgrade Drupal 8 because it is an extended version of Drupal 8.

Migration using Drush Command

When migrating complex sites to Drupal 8 it is more useful if you use Drush as it allows you to run migrations one by one and it allows rollbacks.

Those using Composer to build their Drupal 8 site already have Drush installed. Drush provides more flexibility to pick and choose your migrations. However, if that’s not the case then they can install Drush from the command line.

Migrating from one version to another can be challenging, but the process is simple once you learn how it's done. You can also check out documentations on Drupal.org and the list of known issues to go through the migration process.


Note: The vision of this web portal is to help promote news and stories around the Drupal community and promote and celebrate the people and organizations in the community. We strive to create and distribute our content based on these content policy. If you see any omission/variation on this please let us know in the comments below and we will try to address the issue as best we can.

Advertisement Here

Upcoming Events

Latest Opportunities

Advertisement Here