Upgrade from Drupal 6 to 7, how hard is it?


  • May 2012 - One year have past since I initially wrote this article. Upgrading these days from Drupal 6 to 7 have become easier, safer, and a lot less nerve wrecking, though it will never become a cakewalk.
  • May 2015 - Started writing a longer series using Migrate and Migrate D2D.
  • May 2015 - Cleaned up language a corrected grammar erros.

To migrate or upgrade?

As writing do I still have a few more complex sites running on Drupal 6. Knowing these sites, their complexity, and all existing glue code, a fast and easy upgrade will be hard pull off. It might be easier for complex sites to only migrate the content using modules like migrate and migrate_d2d.

A data migration

  • Do a clean Drupal 7 installation.
  • Build basic needed content types and configurations.
  • Recreate the theme in D7 or port you existing CSS/SASS styles.

Then migrate your content by using modules like http://drupal.org/project/feeds, or for even more flexibility and power http://drupal.org/project/migrate. I'll promise do a blog post of a more complex Drupal 6 to 7 migration as soon as my remaining sites are running Drupal 7.

The upgrade process. What core upgrades what not

First thing first. It is vital to understand this. Drupal core it self upgrade just perfectly from 6 to 7. Meaning if you are running a super small and simple installation of Drupal 6, the upgrade it self should be a breeze. Before you attempt to upgrade read the short but concise UPGRADE.txt located in your Drupal root directory, and make sure you understand it before attempting to run any upgrade.

3 part modules

The tricky part of the upgrade is getting all the extra modules you have installed upgraded. The fewer modules your site is using, the simpler your upgrade path will be. So before you even begin. Make sure your site uses only uses modules it REALLY need. Make sure you properly uninstall the modules you decide to get rid of. Uninstalling help Drupal to keep the database clean and with as little as possible orphan data and configurations.

Modules dies, morph and some even get eaten by core

Drupal 7 is now into its third year of development. All this time have given the core developers a lot of time to add some pretty impressive new features, but also time to do a lot of changes to modules and exiting functionality.

Daniel wrote this post a while back http://www.unleashedmind.com/en/blog/sun/more-than-50-drupal-modules-mov... that is relly worth its read. It is pretty vital to understand how this will affect your upgrade path and planning. The rule of thumb is. Modules that get included into core are still responsible for providing an upgrade path of the configuration and data. This will not be provided by core is self.

A good example is http://drupal.org/project/cck. that got moved or even more correctly, replaced by core in Drupal 7. Core it self does not migrate any of the fields provided by CCK during the Drupal 6 to 7 upgrade. This upgrade have to be performed by CCK it self meaning you will need the Drupal 7 version of CCK to upgrade to Drupal 7 field system. It comes with its own UI that enable you to select and see what field that you have, have not upgraded. It also work as a API allowing other CCK-based fields to provide its own upgrade path.

Plan you upgrade and stay away from the blues

Larger sites is naturally more complicated to upgrade and will require quite some planning. Read up on the different module project pages documentation, look for issues and try to come up with battle plan per module.

I find that we are in better shape then we where back in the days when we moved from Drupal 5 to 6, but there still projects dragging their feet's and have not yet provided a Drupal 7.x branch or/and a upgrade path. Search the project issue queue for Drupal 7 port related titles and join the conversation. Even better, help testing out patches or provide the maintainer(s) with your own beautiful hand crafted code.

Architecture change

Changes in D7 architecture will force some modules to die or to morph into other projects. Here is a few examples where a lot of stuff is changing:


thanks man. i had basically no problems with core updates. the fun began with migration of cck and some other small modules errors in update hooks. finally i ended up doing manual work with the cck part. especially with list fields that got the wrong keys in the db (after cck migrate). ashok, i would use xdebug to stop at these lines and analyze the arrays.

Same problem here. CCK's are almost impossible to migrate. Even with the help of the migrate module. I feel reluctant to continue migrating as I might face the same issues going forward to Drupal 8. I hate to ditch drupal as it provides me with extremely powerful options, but migrating a site is proving to be hell.

I revisited 6 -> 7 migration a few weeks ago. An quite simple site and as suspected everything just worked. No special preparations. That been sad, I was a rather simple site. Migrations between 5->6 was never that hard, that's true. 6->7 have been a more hairy experience. Can you tell me more about what type of fields you are having problem with migrating?

Hi, I had problems with text_textfield widgets which contained lots of text, the migration failed while trying to squeeze it into (i think) a varchar. Converting this to text_textarea widgets before migrating solved that problem. Another problem were multiple-values cck fields without key|value pairs eg: 001:label1. The migration module created these key|value pairs in the widget settings field (content_node_field_instance, widget_settings), but failed to update the relevant cck fields: e.g table: content_field_yourfieldname field:field_yourfieldname_value. In this field I had to change the label to to the correct key as specified in table content_node_field_instance, field widget_settings for the cck field in question. I had to repeat this for table: field_data_field_yourfieldname with field: yourfieldname for every cck widget. I hope this makes sense :-) Anyway, I'm glad I figured things out and hope the next upgrade will be less of a pain. I guess every CMS has it strengths and weaknesses, updating isn't drupals strength, perhaps due to it's powerful feature set. Regards, Arend

Hi, I am developing elearning website for that i required module like open meeting but i am using drupal 7. Is this possible to convert drupal 6 open meeting module to drupal 7. Thanks in advance

I'm afraid I have not heard of it, you have the URL to the module project page? With more then 19 000 project on drupal.org there no way knowing them all ;)

I upgraded drupal 6 site to drupal 7. Now when I am trying to login i am not able to login. Site is redirecting to https mode. My site is not working under HTTPS. Only login and Sighnup pages are redirecting to HTTPS mode. I am able to access other pages and not redirecting to https. Any Idea.

And where is that redirect coming from? Perhaps you have some old settings in settings.php. This is not default D7 so you have some custom config. Grab your code and test it locally in you private sandbox. That will eliminate any webserver rewrites/redirects.