Extracting a Drupal site from Aegir

You may occasionally want to take a Drupal site hosted on a server managed with Aegir and put it somewhere else. This is pretty easy, but not quite as simple as moving a normal Drupal site not managed by Aegir from one machine to another. In brief, you have to copy the site, delete the drushrc.php file, and replace settings.php with a copy of the default configuration file. More specifically:

  • download the same copy of drupal core to the new server (and re-apply core patches, if any)
  • copy sites/all/ to the new server
  • copy the Aegir backup of your site to the new server and unzip in sites/yoursite.com/
  • create a database on the new server & import the database backup
  • copy sites/community.aegirproject.org/default.settings.php to sites/yoursite.com/settings.php
  • D7: copy custom site aliases in sites/sites.php (if any) to the new server
  • D6: replicate site alias symlinks in sites/ (if any) on the new server
  • copy custom configuration in local.settings.php (if any) to settings.php
  • edit settings.php to add the database authentication details for the new server

That's it!