To back up the database:
Server 1:192.168.26.210
Mysqldump-uroot-p-h127.0.0.1--all-databases--flush-logs--master-data=2--lock-all-tables >all.sql
650) this.width=650; "Src=" Http://s1.51cto.com/wyfs02/M00/8C/2C/wKiom1hkYDPgTknWAADJWbh9uT8153.png-wh_500x0-wm_3 -wmp_4-s_483847755.png "title=" 1.png "alt=" Wkiom1hkydpgtknwaadjwbh9ut8153.png-wh_50 "/>
Copy the data to a different server (192.168.26.212):
Execute command on server 1 (192.168.26.210): SCP all.sql node3:/data/
650) this.width=650; "Src=" Http://s5.51cto.com/wyfs02/M00/8C/29/wKioL1hkYFixfjdeAAD0Y0--AaA719.png-wh_500x0-wm_3 -wmp_4-s_1953992294.png "title=" 2.png "alt=" Wkiol1hkyfixfjdeaad0y0--aaa719.png-wh_50 "/>
View the backup data and import data on server 2 (192.168.26.212):
Execute command: LS
Mysql-uroot-p-h127.1<all.sql
650) this.width=650; "Src=" Http://s5.51cto.com/wyfs02/M02/8C/29/wKioL1hkYHrR2Q-fAAB1pSJ8iJI952.png-wh_500x0-wm_3 -wmp_4-s_1504676549.png "title=" 3.png "alt=" Wkiol1hkyhrr2q-faab1psj8iji952.png-wh_50 "/>
To see if the import data was successful:
Execution command: show databases;
650) this.width=650; "Src=" Http://s3.51cto.com/wyfs02/M00/8C/2C/wKiom1hkYLqRJML_AAC6jzkKsIo929.png-wh_500x0-wm_3 -wmp_4-s_3433646293.png "title=" 4.png "alt=" Wkiom1hkylqrjml_aac6jzkksio929.png-wh_50 "/>
This article comes from "on the road ... Find the Lost Memory "blog, be sure to keep this source http://jdonghong.blog.51cto.com/3473478/1887144
MySQL backup database and restore database operations