Question
How to perform a general Plesk to Plesk server migration via Plesk Migrator commands?
Answer
To migrate subscriptions from another Plesk server by using the commands of the Plesk migrator, you should use the steps below:
-
Log in to Plesk
-
Install the Plesk Migrator extension by going to Extensions and using the search bar to find and install the extension
-
Connect to the server as root via SSH
-
Create the
/usr/local/psa/var/modules/panel-migrator/conf
directory by running this command:# mkdir /usr/local/psa/var/modules/panel-migrator/conf
-
Enter the newly created directory:
# cd /usr/local/psa/var/modules/panel-migrator/conf/
-
Create a migration configuration file
config.ini
in the current directory by running this command:# touch config.ini
-
Open the newly created
config.ini
file with your favorite command-line text editor and enter the following:[GLOBAL]
source-type: plesk
sources: pfu
[plesk]
ip: TARGET_SERVER_IP_PLACEHOLDER
os: unix
[pfu]
ip: SOURCE_SERVER_IP_PLACEHOLDER
os: unix
ssh-password: SOURCE_SERVER_ROOT_PASSWORD_PLACEHOLDER
# Uncomment ssh-port string below if the SSH port is not 22
# ssh-port: SSH_PORT_PLACEHOLDERNote: If any PostgreSQL databases from the source Plesk server should be migrated, make sure to specify the PostgreSQL administrator password in the
config.ini
file:[optional]
postgres-password: POSTGRESQL_ADMIN_PASSWORD_PLACEHOLDER -
Save the changes.
-
Generate the migration list file:
# /usr/local/psa/admin/sbin/modules/panel-migrator/plesk-migrator generate-migration-list
Note: To remove domains that should not be migrated or assign domains to service plans, edit the newly generated
/usr/local/psa/var/modules/panel-migrator/sessions/migration-session/migration-list
with a text editor -
Start the migration:
# /usr/local/psa/admin/sbin/modules/panel-migrator/plesk-migrator transfer-accounts
-
Once the transfer is done, run the command below to resynchronize the content:
# /usr/local/psa/admin/sbin/modules/panel-migrator/plesk-migrator copy-content
This will perform an rsync, which will ignore files which have already been copied and not modified.
Note: See How to sync content between source and destination servers after migration? for more details.
-
After the migration is finished, run the following command to check the status of the migrated objects on the target server:
# /usr/local/psa/admin/sbin/modules/panel-migrator/plesk-migrator test-all
For additional information, see Migrating via the Command Line section of the Plesk Obsidian documentation.
Additional information
Migrating via the Command Line | Plesk Obsidian documentation
Configuration Files for Plesk Migration | Plesk Obsidian documentation
Editing the Plesk Migrator Configuration File | Plesk Obsidian documentation
Comments
0 comments
Please sign in to leave a comment.