Migrating Plesk Accounts from One Server to Another

By Paulus, 12 July, 2010

Procedure

  1. Create a backup of the account that you want to migrate for testing purposes:
    1.  Login to the server via ssh
    2. Get the user account that you want to backup, for example paulusworldadmin. 
    3. To backup a user account with all data:
    4. Login via ssh on the server you want to import the backup to.
    5. Create a map file:
      You may need to modify the domain's IP address in the backup.map
    6. To restore the account:
      Once you have successfully tested and performed and needed changes, change the A records TTL to 300s. If the TTL was set to 86400, then you will need to wait a day before you can change the A record.
    7. If possible put the site into offline mode. If the site does not have an offline mode, then create a .htaccess file and redirect all traffic, except yours to a page that tells users the site is down for maintenance.
    8. Perform Step 1 again.
    9. Change the DNS record.
    10. Wait 24 hours before shutting off the domain on first server.
    11. Shut off the domain.
    12. Copy the emails that still got delivered to the first server to the second server. Emails will be stored in /var/qmail/mailnames/domainname/
    13. Remove the client account from the server.

     Issues

    • After updating the A record for the mail, providing the server handles emails, some smart phones will cache the old IP.
    • If the client exists on both servers, then you will need to backup the domain and restore it on the other server:
      1. Login to Plesk and find the domain you want to backup
      2. Perform the backup and download the file.
      3. Create the domain
      4. Upload the backed up file under the same client on the second server.
      5. Restore the domain.