How to Import/Export MySQL Databases with SSH

 export a MySQL database, access your VPS via SSH and run:
 
# mysqldump -u username -p database_name > dumpfile.sql
 
To import a MySQL Database, run:
 
# mysql -u username -p database_name < dumpfile.sql
  • payment
  • 0 Users Found This Useful
Was this answer helpful?

Related Articles

How to Setup LAMP on Debian/Ubuntu VPS

LAMP  is a webserver software stack common on Linux servers (LAMP stands for Linux – Apache –...

How to Install and Setup LAMP on CentOS VPS

LAMP (Linux - Apache - MySQL - PHP) is a common webserver software stack for Linux. Installing...

How to Change MySQL Root/User Password

If you have installed MySQL yourself and have never set a root password, you can do so by running...

Powered by WHMCompleteSolution