Guide maintain your SQL database prevent must often back up it at every time you could. Anything can appear to your pc at any time, for instance, your pc's hard drive should harm, virus or bug assault your report and application, or stolen by means of a person, which it causes your database loses or broken. To back up the MySQL database is simple. We can keep the MySQL database to flash pressure or neighborhood pressure then repair to the opposite computers. All step in Now type the subsequent command at shell set off; the use of a shell command line, so you ought to write down each command first before acting returned up and restore MySQL databases. You ought to be careful on the way to write command right here to keep away from mistakes syntax.
Now, permit we start our guide to Back Up And Restore MySQL Database Via Shell Command Line. We use dumps
ShelldumpsShelldumpsShell
.on
- Shell
- .Shell .
- Now type the subsequent command at shell set off;
- , this database referred to as Now type the subsequent command at shell set off; Send the MySQL database into SQL text record.Now type the subsequent command at shell set off;
Send the MySQL database into SQL text record. - The end result should return with this.
- dumps-uroot The end result should return with this.
- Send the MySQL database into SQL text record.
- dumps-uroot customers
- Send the MySQL database into SQL text record.
- This end result handiest Send the MySQL database into SQL text record. on shell command line. So a way to ship your database into SQL text report? Now follow the subsequent step.
Send the MySQL database into SQL text record. - This result only Send the MySQL database into SQL text record. on shell command line. So how to send your database into SQL text file? now follow the next step.
Create a folder on a particular pressure for your pc.
For example, we would love to create a records folder at power
- E:
- so the result will seem like this.E:\Then kind the subsequent command at shell set off;
- >D:folderfile call.Sql
- Then press enter, here you'll see nothing at shell command spark off.
- dumps-uroot The end result should return with this. mysqldump -uroot clients >E:datathe syntax is : source E:\folder\document call.Sql.Sql
- Then press enter, here you'll see nothing at shell command spark off.
- dumps-uroot customers >>D:folderfile call.Sql\Shell
- E:data
- There you have to see >D:folderfile call.Sql
- unload text record.ShellFinish, now you may pass this SQL report to the other laptop and repair it to available MySQL database
Shell - Once your SQL text record in hand, now you can circulate to the other SQL server. Or you can repair it to the identical server.
Shell
- .
- Shell
- .Shell .
- Now create a brand new database, as an instance, kind the following command ;
- the syntax is : source E:\folder\document call.Sql.Sq.
- Then set lively this new database, type the following command ;
- the syntax is : source E:\folder\document call.Sql.Sq.
- text document to
- the syntax is : source E:\folder\document call.Sql.Sq.
- text document to Shell database. Kind the following commandthe syntax is : source E:\folder\document call.SqlIf your database efficiently restored your command spark off should appear to be this.
- source E:\statistics\customers2.Sql
- If your database efficiently restored your command spark off should appear to be this.
- source E:\\data\\Shell
- Now you may check whether or not the database has been effectively restored to MySQL. Kind the following command ;
- And you need to your new database there.
- Also, you could check all to be had desk in this database. Kind the subsequent command ;
restore Send the MySQL database into SQL text record. - Also, you can check all available table on thisIf your database efficiently restored your command spark off should appear to be this. ;

0 comments:
Post a Comment