Upgrading to Drupal 7                                           NCTech4Good                                        April 1...
A bit about us• DesignHammer is a web design and  development firm based in Durham• We do Drupal• Themes, modules, informat...
What is Drupal 7?        3
What is Drupal 7?• Powerful content management system• D7 has a great number of usability,  performance, security, and API...
Why you shouldn’tupgrade to Drupal 7         5
Drupal is an          eco-system• Modules• Themes• Install Profiles• People!                    6
Modules & Themes• Many important contributed modules  (Nodewords) are not ported• Many others (Views) don’t have stable  r...
Modules & Themes6000450030001500                           Drupal 6   Drupal 7   0        Modules   Themes                ...
More reasons not to          upgrade?• There are bugs in Drupal 7 (1 critical, 200  major, 800+ normal)• Upgrading is a ma...
Good reasons to        upgrade• Preparing for an overhaul of your website  structure / design• Currently running Drupal 5 ...
Let’s upgrade!      11
Site inventory• Figure out what you have, what you need,  and what you can get rid of.• Modules, themes, custom code• Confi...
Module inventory  admin/build/modules           13
Use Drush          http://drupal.org/project/drush• Drush is a command-line tool to interact  with the Drupal shell• Essen...
Drush inventorydrush pml --type=module --status=enabled --no-core                        15
drush pml --type=module --status=enabled --no-core--pipe                        16
Drush inventorydrush pml --type=module --status=enabled --no-core--package=designhammer                        17
Content type inventory          18
Field inventory       19
Theme inventory            Won’t work in D7       20
Theme work    21
Other configuration• Views• Panels• Menu structure• Block placement                    22
Content inventory• Get to know your database•SHOW TABLES;•SELECT COUNT(*) FROM users;•SELECT COUNT(*) FROM node;• Use View...
Inventory complete?  Not if you didn’t take lots of notes!                   24
Migration environments          25
Development        environments• Production (http://designhammer.com)• Staging (http://stage.designhammer.com)• Developmen...
Migration environments• Staging (http://d7stage.designhammer.com)• Development (http://dh7.local)• Don’t attempt an upgrad...
Source control• We use Git• Branches for develop-7.x and master-7.x• Branches for features and issues                    28
Which migration path?   How frequently is your site updated?                    29
Drupal’s update.php             http://yoursite.org/update.php            Pros                               Cons•   Stand...
Migrate module            http://drupal.org/project/migrate           Pros                              Cons•   Extremely ...
Migrate module• Write code for each entity you want to  import• Run imports and roll back• Supports pulling data from the ...
Migrate module      33
Migrate module      34
35
Drupal 7 update.php•    Follow the 18 step guide in UPGRADE.txt    • Disable all modules, themes, set core      theme• Whe...
Data migrated! Now comes the hard work           37
Configuration and code• Upgrade your theme(s)• Upgrade your custom code• Upgrade all your contributed modules• Reset your b...
DesignHammer   A Case Study        39
DH Migration Path• We tried the standard update.php process,  and failed• Tried Migrate module• Then went with the update....
Pain points• Converting the theme• Fixing broken Views• Resetting configuration (blocks, tokens,  menu items)• Learning D7 ...
Conclusions• Plan carefully• Have a good reason to upgrade• Think about your migration path• Study D7 before attempting to...
Kosta Harlan   Jay RobertsDevelopers @DesignHammer   @dh_kosta @dh_jay  www.designhammer.com           43
Upcoming SlideShare
Loading in...5
×

Upgrading to Drupal 7

3,401

Published on

Presentation at the NCTech4Good conference in Chapel Hill, NC on April 15, 2011. The presentation covers upgrading to Drupal 7 from Drupal 6 (or another system), and covers best practices, recommendations. Update.php and migrate module are both discussed.

Published in: Technology
0 Comments
2 Likes
Statistics
Notes
  • Be the first to comment

No Downloads
Views
Total Views
3,401
On Slideshare
0
From Embeds
0
Number of Embeds
6
Actions
Shares
0
Downloads
0
Comments
0
Likes
2
Embeds 0
No embeds

No notes for slide

Upgrading to Drupal 7

  1. 1. Upgrading to Drupal 7 NCTech4Good April 15, 2011 Kosta Harlan @dh_kostaNotes: Jay Roberts @dh_jay Developer @DesignHammerhttp://designhammer.com/blog http://designhammer.com 1
  2. 2. A bit about us• DesignHammer is a web design and development firm based in Durham• We do Drupal• Themes, modules, information architecture, mobile, 3rd party integration 2
  3. 3. What is Drupal 7? 3
  4. 4. What is Drupal 7?• Powerful content management system• D7 has a great number of usability, performance, security, and API improvements• Drupal 7 currently used by NPR, The Examiner, Drupal Gardens 4
  5. 5. Why you shouldn’tupgrade to Drupal 7 5
  6. 6. Drupal is an eco-system• Modules• Themes• Install Profiles• People! 6
  7. 7. Modules & Themes• Many important contributed modules (Nodewords) are not ported• Many others (Views) don’t have stable releases• Lots of others have major/critical bugs 7
  8. 8. Modules & Themes6000450030001500 Drupal 6 Drupal 7 0 Modules Themes 8
  9. 9. More reasons not to upgrade?• There are bugs in Drupal 7 (1 critical, 200 major, 800+ normal)• Upgrading is a major investment of time and resources• Drupal 6 still has at least 2-3 years of support 9
  10. 10. Good reasons to upgrade• Preparing for an overhaul of your website structure / design• Currently running Drupal 5 or hacked core• Preparing for a presentation on how to upgrade Drupal 6 to Drupal 7! 10
  11. 11. Let’s upgrade! 11
  12. 12. Site inventory• Figure out what you have, what you need, and what you can get rid of.• Modules, themes, custom code• Configuration and content 12
  13. 13. Module inventory admin/build/modules 13
  14. 14. Use Drush http://drupal.org/project/drush• Drush is a command-line tool to interact with the Drupal shell• Essential for managing sites• drush site-upgrade @d7 14
  15. 15. Drush inventorydrush pml --type=module --status=enabled --no-core 15
  16. 16. drush pml --type=module --status=enabled --no-core--pipe 16
  17. 17. Drush inventorydrush pml --type=module --status=enabled --no-core--package=designhammer 17
  18. 18. Content type inventory 18
  19. 19. Field inventory 19
  20. 20. Theme inventory Won’t work in D7 20
  21. 21. Theme work 21
  22. 22. Other configuration• Views• Panels• Menu structure• Block placement 22
  23. 23. Content inventory• Get to know your database•SHOW TABLES;•SELECT COUNT(*) FROM users;•SELECT COUNT(*) FROM node;• Use Views to help with content inventory 23
  24. 24. Inventory complete? Not if you didn’t take lots of notes! 24
  25. 25. Migration environments 25
  26. 26. Development environments• Production (http://designhammer.com)• Staging (http://stage.designhammer.com)• Development (http://designhammer.local) 26
  27. 27. Migration environments• Staging (http://d7stage.designhammer.com)• Development (http://dh7.local)• Don’t attempt an upgrade on your live site! 27
  28. 28. Source control• We use Git• Branches for develop-7.x and master-7.x• Branches for features and issues 28
  29. 29. Which migration path? How frequently is your site updated? 29
  30. 30. Drupal’s update.php http://yoursite.org/update.php Pros Cons• Standard, community • The remaining 10% can supported upgrade path cause big headaches• Easy! • Field migration not quite there yet• Migrates configuration • No ability for ongoing data settings migration• Will get you 90% of the way there 30
  31. 31. Migrate module http://drupal.org/project/migrate Pros Cons• Extremely flexible and • More complicated to set powerful up• Excellent for ongoing • Time consuming data migration • Not great for Drupal to• Integrates with issue Drupal migrations trackers • No configuration settings migrated 31
  32. 32. Migrate module• Write code for each entity you want to import• Run imports and roll back• Supports pulling data from the production database 32
  33. 33. Migrate module 33
  34. 34. Migrate module 34
  35. 35. 35
  36. 36. Drupal 7 update.php• Follow the 18 step guide in UPGRADE.txt • Disable all modules, themes, set core theme• When you are done, download cck-3.x-dev and enable the content_migrate module• Start migrating your fields 36
  37. 37. Data migrated! Now comes the hard work 37
  38. 38. Configuration and code• Upgrade your theme(s)• Upgrade your custom code• Upgrade all your contributed modules• Reset your blocks & configuration settings• Report bugs and contribute patches! 38
  39. 39. DesignHammer A Case Study 39
  40. 40. DH Migration Path• We tried the standard update.php process, and failed• Tried Migrate module• Then went with the update.php process again 40
  41. 41. Pain points• Converting the theme• Fixing broken Views• Resetting configuration (blocks, tokens, menu items)• Learning D7 from a migration process instead of starting fresh 41
  42. 42. Conclusions• Plan carefully• Have a good reason to upgrade• Think about your migration path• Study D7 before attempting to upgrade to D7! 42
  43. 43. Kosta Harlan Jay RobertsDevelopers @DesignHammer @dh_kosta @dh_jay www.designhammer.com 43

×