- Upgrading from Drupal 7 to Drupal 10 involves a sequence of technical steps involving pre-migration assessment, module updates, content migration, and testing.
- The upgrade process requires careful planning and patience as it involves a fair bit of technical knowledge and expertise.
- Not all modules used in Drupal 7 will have equivalents in Drupal 10. A careful audit of modules and functionalities is key before starting the upgrade process.
- Data migration is also a critical part of the upgrade and must be done with meticulous attention to ensure no content is lost or altered.
- Finally, pore- and post-migration testing is essential to ensure the new Drupal 10 website works as expected, and all the features, functionalities, and content are working properly.
Here is a list of best practices for upgrading Drupal 7 to Drupal 10. And, in fact, this list can be generalized for any major version software migration.
1) Audit Your Current Drupal 7 Site
Take stock of your current Drupal 7 website. Identify the modules you are using, their Drupal 10 equivalents, and any custom code. Determine what content types, views, taxonomies, and other features you have in place.
2) Prepare Your Drupal 7 Site
Update your Drupal 7 site to the latest minor version and ensure all modules are updated. It's also important to remove any unused modules, themes, and libraries.
3) Set Up a New Drupal 10 Site
Install a fresh copy of Drupal 10 in a separate development environment. This will serve as the base for your upgraded site.
4) Install and Configure Upgrade Modules
Install the Migrate, Migrate Upgrade, and Migrate Plus modules on your new Drupal 10 site. These modules will help you migrate your data and configuration from Drupal 7 to Drupal 10.
5) Run a Test Migration
Migrate Drupal (migrate_drupal) module helps to perform a test migration. This dry run will give you a sense of how the actual migration will progress and help identify any potential issues. And here are some additional modules you are your development agency will want to review:
6) Review and Resolve Migration Errors
Any errors or issues that arise during the test migration should be addressed before proceeding. This may involve adjusting the configuration of the migration modules or resolving conflicts in the data.
7) Perform the Actual Migration
Once all issues have been resolved, perform the actual migration. This will migrate your site's configuration and content to the new Drupal 10 site.
8) Manual Migration for Unhandled Items
Some items may not be automatically migrated and will need to be manually recreated in Drupal 10. This includes blocks, views, and certain configuration settings.
9) Theme Implementation
Although listed as step 9, this is perhaps one of the most time consuming parts of the upgrade process. Drupal 10 uses a new theming engine called Twig (https://twig.symfony.com/), so your Drupal 7 theme will need to be rewritten. This can be done using Drupal 10's default theme, a contributed theme, or a custom theme.
10) Post-Migration Testing and Training
Thoroughly test the new site to ensure everything is working as expected. Check all the pages, features, and functionalities. Depending on the size and functionality of your site, hiring a QA firm can really help save time and money. Once testing is completed, your team is ready to be trained on the new Drupal 10 site.
Note: You also will want to archive your Drupal 7 site for a few weeks so you can reference that site after the migration is complete. This will help you find missing content or images, or verify if something was done properly in case it was overlooked in the quality assurance effort.