Technical Debtor’s Prison

So, my friend Keith (funny story about my friends Keith…another time perhaps) heard the tale of my Drupal non-upgrade, and encouraged me to write it up.

Long ago, I set up Wired Cola as a blogger.com site, and it was fine. I even pointed wiredcola.com at it. Time passed, it seemed good to move it to my own Drupal site, hosted on a provider. And it was good. I configured the setup myself, back when Drupal 4 or 5 was current, and all was well.

Drupal has a principle, a reasonable one, that “the drop keeps moving,” which is their way of politely saying “stay current or die.”

Good advice.

I didn’t stay current.

Drupal is now on version 8, and version 6 is supported in “security fixes only” mode. I looked into migrating the site.

Drupal supports doing upgrades from the latest version of a major release to the next release. So there’s generally an upgrade path from 5.latest to 6.anything. I think in the current versions you can fairly easily go from 6.latest to 8.anything.

Also along the lines, the way that upgrades worked has changed. The old model was to upgrade-in-place, more or less. You’d put your site in maintenance mode, dump all the new files on top of the old file structure, run the upgrade script, and turn the back on. Voilà, you are upgraded.

New-school Drupal now has much better, somewhat automated upgrading. But to get from old to new, you have to migrate. The procedure is all laid out for you, but the core is that you set up the new site in a new directory tree, run a module that automatically imports your old content into the new system, and then when it’s definitely working, archive the old site, delete it, and copy the new site with the migrated content into the place of the old one.

Easy!

That’s a pretty good system if you’ve been prudently updating things all along. One new, hard upgrade, and then you’re good, right?

Well.

Drupal is built on a technology called PHP. You either know what that is (and may be recoiling in horror, or not), or there’s not much point in explaining it. Suffice to say that PHP has also been evolving, and each version of Drupal has its own version requirements for PHP.

In case it ever helps anyone in a similar situation, here’s my research on the PHP version path.

Drupal 5 will only run on PHP versions up to 5.2.x; 5.3 or later won’t work. Drupal 6 will work with the same versions of PHP, and probably up to 5.5, maybe. Depends on your modules. Drupal 7 will work on PHP 5.3 to 7.2, maybe 7.3, and Drupal 8 will work on PHP 5.5 to 7.3, but you really want to be on 7.x.

Reader, do you see the dilemma? You need to upgrade between versions of Drupal that have a common version of PHP available, until you get to a version of PHP that Drupal 8 can run on, at which point you can finally move your site into its final form.

Looking over that list of dependencies, I believe I need to upgrade my installation to PHP 5.2, then upgrade Drupal to 6.x, then upgrade to PHP 5.3, then migrate to Drupal 7, upgrade to PHP 7.2, then up to Drupal 8, followed by the latest version of PHP 7.2.

(Astute readers will notice a living-dangerously path of PHP 5.2-Drupal 6.x-PHP 5.5-Drupal 8-PHP 7.x, and indeed that Drupal 6-to-8 migration appears to be possible, so point taken, this isn’t a 7-step upgrade process, only 5 steps, consider me refuted!)

Looking at that made me tired, because this is a site I write for my own entertainment, and from past experience a 5-step Drupal migration is going to mean several quiet evenings staring at terminal windows, punctuated by irregular moments of loud cursing.

In conclusion, I put the Drupal site into maintenance mode and used my hosting service’s one-click installer to create this here host-maintained WordPress instance, and I’ll revive the old site, complete with intact URLs or 301 redirects, Real Soon Now.

2 replies on “Technical Debtor’s Prison”

Comments are closed.