- Plesk for Linux
How to add existing database from a remote MySQL server to a subscription?
2. Create a dump of the required database on remote MySQL server:
# mysqldump -u<username> -p<password> db_name > /root/db_name_backup.sql
db_name - database name
<username> - user name for remote MySQL server.
<password> - password for remote MySQL server.
3. Download database dump file from remote MySQL server to your local computer.
To download file to computer with Windows use WinSCP.
To download file to computer with Linux use command line
scp email@example.com:/root/db /home/johndoe/
203.0.113.2 - IP address of remote MySQL
4. Log into Plesk UI and create an empty database with a name that does not exist on the external server:
Navigate to Subscriptions > example.com > Databases > Add Database (choose external database server) .
5. Import backup file
created on step 2 to the database created on step 4:
Navigate to Subscriptions > example.com > Databases > db_name2 > Import Dump > select file with database dump and press OK .
db_name2 - name of the database created on step 4.