kb: how-to
Plesk for Linux
Applicable to:
- Plesk for Linux
Question
How to import PostgreSQL database dump on Plesk for Linux server?
Answer
Using command-line utilities
-
Connect to the server using SSH.
-
Execute the following command:
# psql example_db < dump_file
# pg_restore -U johndoe -d example_db dump_file
Note:
example_db
is the name of the database to which the dump is imported;johndoe
- the database user;dump_file
- the name of the dump file.
Using phpPgAdmin (only in Plesk Onyx 17.5 and earlier)
Warning: phpPgAdmin is deprecated in Plesk 17.8 and later due to security reasons.
-
Go to Domains > example.com > Databases and click phpPgAdmin under the name of the required database.
-
In the phpPgAdmin interface, click on database name > SQL > Browse, select file to upload and click Execute.
Note: Imported backup should contain valid SQL commands.
Comments
0 comments
Please sign in to leave a comment.