I am moving away from Linode because I don't have the Linux sysadmin skills necessary; before I complete the transition to a more noob-friendly service, I need to download the contents of a MySQL database. Is there a way I can do this from the command line?
相关问题
- sqlyog export query result as csv
- NOT DISTINCT query in mySQL
- MySQL: conduct a basic search
- Why sometimes there is one of more gap(s) in the v
- mySQL alter table on update, current timestamp
Go to MySQL installation directory and open cmd from there. Then execute the below command to get a backup of your database.
For Windows users you can go to your mysql folder to run the command
e.g.
Open Command prompt, and directly type this command. Don't go inside mysql and then type this command.
If downloading from remote server, here is a simple example:
The -p indicates you will enter a password, it does not relate to the db_name. After entering the command you will be prompted for the password. Type it in and press enter.
If you are running the MySQL other than default port:
Use this If you have the database with the name archiedb, use this mysql -p --databases archiedb > /home/database_backup.sql
Assuming this is linux, choose where the backup file will be saved.