Steps to create MySQL backup in Windows VPS via command line

kumkumsharma

Administrator
Staff member
You can follow below steps to create MySQL backup with command line. Here we will learn to create Mysqldump of your database.
  • Login to your Windows VPS server.
  • Click on Start and then choose “Run” to open Windows command prompt.
  • In command prompt you have to enter “cmd” and click on OK.
  • You have to change the directory with below command from which you can access mysqldump utility.
Code:
cd C:\Program Files\MySQL\MySQL Server 5.5\bin
  • Run the below command to create dump of your MySQL database.
Code:
mysqldump.exe –e –u[username] -p[password] -h[hostname] [database name] > C:\[filename].sql
If you’re all the arguments are correctly passed in command then you are not able to make connection with MySQL database and also dump of your database wil be created.

Here is the example:

Command syntax: mysqldump -u accutestuser accutest > c:\accutest.sql
 
Top