The Journal

Five Sites, One Weekend: A Hosting Migration Postmortem

Every migration I have ever done has taught me the same lesson in a new costume: the moving is easy, the moving correctly is the whole project. When I decided to consolidate five websites onto a single Ubuntu server running ISPConfig, I set one rule for myself before touching anything: every destructive step gets a reversible counterpart, created first, verified second, and only then am I allowed to proceed.

The inventory came first. Five domains, four WordPress installations of varying ages and plugin diets, one mail system with real messages people care about, DNS records split across two providers, and TLS certificates that had renewed happily on the old server for years. I wrote the inventory down. Sounds obvious. It saved me three times over the weekend.

Restores went in order of blast radius. The static and low-traffic properties went first, on the theory that if my process was broken I would rather find out on the site nobody reads than on the one with a decade of posts. Each restore followed the same ceremony: download the backup, verify its checksum before trusting it, import the database into the new ISPConfig-created schema, fix the serialized WordPress URLs with a search tool that understands serialize() byte counts, correct file ownership to the site’s Linux user, and generate a rollback bundle at /var/backups before the first overwrite. The rollback bundle is not optional. It contains the original files, an original database dump, and the vhost configuration that was working ten seconds earlier.

WordPress is fine, but WordPress migrations are byte archaeology. Old attachment paths embedded in post content, staging hostnames hiding inside theme option caches, plugin uninstall callbacks holding stale arrays: all of these live in the database and all of them break content subtly if you do a plain find and replace. The tooling matters less than the discipline: dry-run every replacement, exclude GUIDs, and re-render each homepage server-side to compare against the original before you call it done.

Mail was the part I feared most, and it turned out to be the most mechanical. A mail restore is not scary because the tools are exotic; it is scary because the stakes are asymmetric. Text on a blog page being wrong for an hour is invisible. A mailbox missing three messages is visible to one person for the rest of their life. So mail got doveadm-based import with per-message hash verification, message flags preserved, indexes rebuilt, quotas recalculated, and Sieve rules recompiled. The verification step is what let me stop worrying: if every restored message’s hash matched the backup and the one pre-existing message was untouched, the mailbox was provably correct.

DNS cutover is the emotional part. Everything else on the new server can be tested privately, over and over, until it is boring. DNS is the moment the world starts walking through your new front door, and unlike everything else you cannot un-ring it. Lower the TTL days in advance, keep the old server answering until the new one proves itself on the real hostname with real certificates, and cut over at an hour when you are awake and unhurried.

What I would tell the version of me who started this: checksum everything, back up before every write, dry-run every mutation, verify restores by rendering rather than by believing, and treat mail message hashes like money. The whole thing went from a five-site mystery to a well-rehearsed checklist, which is what good weekend projects turn into.

#migration#ispconfig#wordpress#servers#backup