Links for Saturday – Drupal updates and more

I needed to update my Drupal installation for The Nonprofit News Network site so I decided to tackle that this morning. I was in a bit of a hurry (first mistake) and so I backed up my sites/ directory first then ran the Fantastico update script (I did the original install with this tool so figured I should use it for the upgrade as well). It backs up your installation then runs the update. I copied the text message that gave me instructions on how to use the backup if things did not go so well. Well, they did not go so well. I hit my home page and pretty much nothing. I was able to get to the admin page so I started trying to figure out what went wrong. I took a peek in the sites directory and noticed that my modules and theme was missing. I untarred that directory to restore those files but I was still getting errors. A quick Google of the error (warning: array_map() [function.array-map]: Argument #2 should be an array) led me to the solution.

I needed to enable my theme and all of the modules I used for the site. After I did that the error went away and most of the site functioned. The next step was to reset the permissioning for certain content views. I just logged out and went through the site to see what was missing and then changed those permissions. The last step involved a few theme tweaks. So far it looks pretty good.

Lessons learned:

  1. Don’t do this if you are in a hurry; also best done early on a Sunday morning or other low traffic time for your site. Put you site in maintenance mode first then get to work.
  2. If I had it to do over I don’t think I would have installed with Fantastico or other automated script. Probably would have been a bit easier or at least I would have had more control over the upgrade.
  3. Read the upgrade instructions and make sure you back up directories and files that you have customized. If you install your modules and themes in the sites/all directory it makes this process much easier.
  4. Check to make sure your modules and theme is enable after the upgrade. You might want to document what modules you have enabled, especially if you have a complex installation.